Carpenter's Blocks

Carpenter's Blocks

24M Downloads

request: change how the hammer is damaged (while avoiding GUIs)

Tarig0 opened this issue ยท 6 comments

commented

Since there is SOOOOO many different slopes you can use, kudos to you mineshopper, the carpenter hammer doesn't last very long especially if you need one of the later type of slopes.

Would you be against making it so the hammer is only damaged when right clicking and when the current block has not been hit by that hammer within a few seconds or that hammer hit another block.

to do this you would need to store nbt data on the hammer of where it last hit, and when.

on right click

getnbttag().location
if(curLocation != location){
damage hammer
setNBTtag().location = curlocation
}

setNBTtag().lasttimehit() = NOW();

then have a tick handler check the time nbt data and if it's older than 3 seconds remove the location data.

if(getNBTtag().lasttimehit - NOW > 3)
{
remove location
remove lasttimehit
}

commented

Seriously, a hammer is VERY cheap to make, making a few of them should not be a problem...

commented

May as well consider this taken care of.. lots of ways to reduce hammer usage exist.

commented

Perhaps, though I would normally just increase the durability or even add a chance to damage, like the collapsible. It's not as if hammers always break on the same stroke, so I can just make it less likely to damage.

commented

hmm, yea but then you still have it to where if the player wants peaks everywhere they will have had to go through more of the hammer than someone who wanted int-corners

commented

I'm going to explore ways to make slope selection possible before ever placing one. That should cut down on the amount of hammer clicking significantly. Perhaps an NBT tag that changes when sneak clicking air, or something.

The collapsible chance of damaging hammer can then just be increased if necessary, or even a config option can be added.

commented

Sounds like a plan, will also cut down on time spent.

with that I have one little possible overlook, if the user clicks on a block with the hammer and it doesn't change then the hammer should not take damage.