Author Topic: Event_BindAction  (Read 9059 times)

Was fun fiddling around with this at Trog's. Everything seems to be working just fine.
Just remember that when you break a brick, it exists for a few extra seconds and that's why the events will still work a few seconds after. This affects some default things too. Like if you break a spawn and then respawn, you can still spawn at it for a few seconds.

This is amazing... Everyone that plays Blockland should have this.

Was fun fiddling around with this at Trog's. Everything seems to be working just fine.
Just remember that when you break a brick, it exists for a few extra seconds and that's why the events will still work a few seconds after. This affects some default things too. Like if you break a spawn and then respawn, you can still spawn at it for a few seconds.
it also affects the /brickcount right

Oh man I can't wait to test this out!

If you bind an action on a brick, then break the brick, is that action still there and you have to unbind the action with the events in order for the action to go away, or does it disappear with the brick?

Wow, that's impressive.

If you bind an action on a brick, then break the brick, is that action still there and you have to unbind the action with the events in order for the action to go away, or does it disappear with the brick?
actions are linked with the brick so I assume they are

If you bind an action on a brick, then break the brick, is that action still there and you have to unbind the action with the events in order for the action to go away, or does it disappear with the brick?
I could update it to unbind when the brick is destroyed, though this isn't entirely necessary. In normal play, bricks aren't really going to be destroyed. And in the cases that bricks are destroyed, there's isObject checks so that no errors come up. The only benefit of this is cleaning up the potential 2 or 3 leftover variables stored on the player, which will reset when the player dies regardless.

it also affects the /brickcount right
Yup. /brickcount will still include 'dying' bricks.

Alright, gonna add next/prev seat, and automatic unbind when the brick is killed.

Not adding the automatic unbind. This will cause a loop of 21 x number of clients each time a brick is deleted or a ghost brick is cancelled, double for bricks killed (by hammer/wand/etc).
There's also certain bricks with their own onRemove/onDeath that don't call the parent so it wouldn't work on every type of brick anyway.
« Last Edit: March 21, 2016, 10:32:12 AM by Shift Kitty »

Can you add sheathe/unsheathe weapon to the list of keys? I feel like with light and jump being there it only makes sense to have the weapon button be there too

Can you add sheathe/unsheathe weapon to the list of keys? I feel like with light and jump being there it only makes sense to have the weapon button be there too
This would be a little more complicated to do. The only way I could do this is by using usetool and unusetool, and there's many many cases where these commands don't actually mount/unmount a tool. usetool will also be called simply by scrolling.

Not a bad idea though.


Also updated for prev/next seat.

Can you add sheathe/unsheathe weapon to the list of keys? I feel like with light and jump being there it only makes sense to have the weapon button be there too
Please add this. I would like to have this for something I want to work on.

Oh, I think I found a way I can do it. The issue still stands with scrolling though. It will call both as you scroll through your tools.
« Last Edit: March 21, 2016, 11:01:16 AM by Shift Kitty »

how about one for when the player sits?

how about one for when the player sits?
The problem is there is not a default function for when the player stops sitting.
The only way to detect this would be to run a schedule on the sitting player to see if he is moving.
Not quite a perfect way i can tell you.