Gravestone mod - Graves

Gravestone mod - Graves

4M Downloads

Memorials interaction

NightKosh opened this issue ยท 1 comments

commented

Player can go through obelisk, cross and pedestals upper parts.

commented

Message from DA3DSOUL

Firstly, I am typing this from a phone, so sorry if there are any weird misinput words. Secondly, the grave stone mod is awesome, to the point that I can only think of one complaint vs 20. The collision and placement of statues in the world can be weird to say the least. The logic for determining if you can place a statue needs work (I can't place them on flat ground but I can place them on a single block extruding). The collision can be fixed with placeholder blocks.

https://www.dropbox.com/s/vt51dhxr6zqbew2/BlockNullCollide.java?dl=0

Is a simple colliding block that is invisible. It needs a texture override for breaking (or it will crash), but that is all.

@OverRide

public void onBlockAdded(World world, int i, int j, int k) {

    super.onBlockAdded(world, i, j, k);



    if(world.getBlock(i, j + 1, k) == Blocks.air)

    {

        world.setBlock(i, j + 1, k, ABO.blockNull);

    }

}



@Override

public void onBlockPreDestroy(World world, int i, int j, int k, int oldMeta) {

    if(world.getBlock(i, j + 1, k) == ABO.blockNull) world.setBlock(i, j + 1, k, Blocks.air);

}

Change ABO.blockNull to the block instance.

I don't need credit or anything, it just bugs me.