Closed altruiis closed 3 years ago
Can you add a broadcast at the top of the trigger, to debug
Can you add a broadcast at the top of the trigger, to debug
Lapis still does it once, so it works properly for that block Iron ore only broadcasts once, but it adds to the variable twice? Gold ore does not add to the variable, but it still broadcasts the message. Coal ore broadcasts once and then adds to the variable three times, but none of them broadcast twice, they all broadcast once.
I recommend using else if
's instead of if
's if you chain them like that
Weird, it seems to be working now when I haven't modified the file at all. All ores only add to the variable once. No clue what the issue was but I guess I can close this now. Thank you!
You're welcome :D
Describe the bug I have a BlockBreakEvent that should add to a variable everytime the block is broken and the person is in a town. However, sometimes it adds two to the variable despite only breaking the block once. Some ores don't even work at all.
Code: https://hastebin.com/uracawofut.sql
To reproduce
Expected behavior A clear and concise description of what you expected to happen.
Screenshots Iron ore does it twice, lapis does it once (which is how they should all function) and gold ore does not even function whatsoever.
Server information
Additional context Add any other context about the problem here.