Dropping items on ground #200
-
Before starting down the path of figuring out how to drop items on the ground as loot from various sources.... Does anyone have any ideas on which direction I should look to accomplish this? I was thinking of using an area2d around the sources, instancing some nodes randomly in the area of the area2d, and then on player in range <= etc... add items to inventory and free the nodes used.... Is there a more elegant solution or is it more a too each their own sorta thing on choosing how to execute |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
Unfortunately, this is another thing that is not fully supported by the plugin. In the future, I might implement some sort of item drop controls that can handle item drops. But for now you can try the dev_v2.4.8 branch (hope to merge it soon), where you should be able to implement And if you really want to use the master branch, you can create a transparent item slot that spans the entire screen and use the |
Beta Was this translation helpful? Give feedback.
Unfortunately, this is another thing that is not fully supported by the plugin. In the future, I might implement some sort of item drop controls that can handle item drops.
But for now you can try the dev_v2.4.8 branch (hope to merge it soon), where you should be able to implement
_drop_data
for any control and detect item drops (or any other kinds of UI control drops). Then it's just a matter of creating a control that is the size of the screen and placing it behind all other UI controls. Using theNOTIFICATION_DRAG_END
notification followed by aViewport.gui_is_drag_successful()
check should also work.And if you really want to use the master branch, you can create a transparent item sl…