Igor Q. 519 Posted December 4, 2018 Hi I'm trying to make it so that when a character dies (items are removed from inventory), all items they drop despawn. However if the character contains more than 1 item in the inventory the game code bugs and the character freezes as a ghost and only the first item despawns. Any idea on how to fix this? Share this post Link to post Share on other sites
Oliver Hope 261 Posted December 4, 2018 Are you using an event listener for the death? I would. I would send a picture of the code I would use but I’m not at home if you want I’ll send one later but for now I’ll try explain. Despairing the target object would despawn the player and not there items. Your script should I go like this : on trigger for each time in array (get inventory player(target object)) inside the loop despawn entity(item) hope that helps? if you need an image let me know Share this post Link to post Share on other sites
Igor Q. 519 Posted December 4, 2018 (edited) Gonna need a pic for this. It's not working on my end. Edit: Never mind, need to include character equipment as well. Edited December 4, 2018 by Igor Quintero 1 1 Share this post Link to post Share on other sites
Spyler.X 625 Posted December 4, 2018 Hi I do not know if it will work for you. but if you apply a player role you have the option to eliminate the inventory when you die. Share this post Link to post Share on other sites