#10 Protector is not returned when dug

Closed
opened 4 months ago by MisterE123 · 4 comments

I have isolated the problem to the interaction between the item_drop mod and the protector mod. The problem first popped up here: 36a7f0d869

I have isolated the problem to the interaction between the item_drop mod and the protector mod. The problem first popped up here: https://notabug.org/MeseCraft/mesecraft/commit/36a7f0d86912003f009903255ce47faa23129817
MeseCraft commented 4 months ago
Owner

OK, that explains it. I've seen issues with this mod before. Going to turn it off for now.

OK, that explains it. I've seen issues with this mod before. Going to turn it off for now.
MisterE123 commented 4 months ago
Poster

I have further isolated the problem.

Look at line 528 of https://notabug.org/MeseCraft/mesecraft/src/master/mods/protector/init.lua#L3

the protector node has a callback that deletes any objects in its immediate vicinity when it is dug. This is intended to remove the area indicator entity, but it indiscriminately removes its own dropped item when dug

I have further isolated the problem. Look at line 528 of https://notabug.org/MeseCraft/mesecraft/src/master/mods/protector/init.lua#L3 the protector node has a callback that deletes any objects in its immediate vicinity when it is dug. This is intended to remove the area indicator entity, but it indiscriminately removes its own dropped item when dug
MisterE123 commented 4 months ago
Poster

Should be and easy fix. Before removing it, check that the object being removed is not protector:protect or the logo equivalent for the protection logo definition

Should be and easy fix. Before removing it, check that the object being removed is not protector:protect or the logo equivalent for the protection logo definition
MisterE123 commented 4 months ago
Poster

Ok, fixed with:

https://notabug.org/MisterE123/protector

I added a check before it deleted any nearby objects to only delete the protector:display object, which is the whole purpose of the object deletion anyways. I tested it and it works.

feel free to update protector and then re-enable item drop. Protectors will no longer disappear

Ok, fixed with: https://notabug.org/MisterE123/protector I added a check before it deleted any nearby objects to only delete the protector:display object, which is the whole purpose of the object deletion anyways. I tested it and it works. feel free to update protector and then re-enable item drop. Protectors will no longer disappear
Sign in to join this conversation.
No Label
No Milestone
No assignee
2 Participants
Loading...
Cancel
Save
There is no content yet.