Loscil2 Posted December 3, 2014 Share Posted December 3, 2014 How can I delete a bunch of entities under my mouse? I tried TheInput:GetAllEntitiesUnderMouse():Remove() but didn't work. I ask this because I really need to delete a lot of objects that spawned in the same spot. TheInput:GetEntityUnderMouse:Remove() is not enough to delete them all, lag issues make said command really tiring because opening the console can take so much time...I thought this would be the best place to ask, thanks in advance. Link to comment Share on other sites More sharing options...
Mobbstar Posted December 3, 2014 Share Posted December 3, 2014 It's TheInput:GetWorldEnitityUnderMouse():Remove() EDIT: Just out of curiousity, may I ask how that happened? Link to comment Share on other sites More sharing options...
Loscil2 Posted December 3, 2014 Author Share Posted December 3, 2014 It's TheInput:GetWorldEnitityUnderMouse():Remove() EDIT: Just out of curiousity, may I ask how that happened? I have More Realistic Beehives and for some unknown reason, a beehive spawned in the ocean. At first I didn't take much importance but as now, in the day 219, the lag is unbearable. Since the mod makes beehives to reproduce like, say, cells, you can imagine the sheer amount of lag that accumulated after so many days. Yes, I tried TheInput:GetWorldEntityUnderMouse():Remove() but it only removes one beehive at the time and I can't see the difference. Link to comment Share on other sites More sharing options...
squeek Posted December 3, 2014 Share Posted December 3, 2014 while TheInput:GetWorldEntityUnderMouse() do TheInput:GetWorldEntityUnderMouse():Remove() endmight work. Link to comment Share on other sites More sharing options...
Loscil2 Posted December 3, 2014 Author Share Posted December 3, 2014 while TheInput:GetWorldEntityUnderMouse() do TheInput:GetWorldEntityUnderMouse():Remove() endmight work. Attempt to call a nil value.I assure that I typed it exactly as posted here Link to comment Share on other sites More sharing options...
Loscil2 Posted December 3, 2014 Author Share Posted December 3, 2014 Attempt to call a nil value.I assure that I typed it exactly as posted here For get it, Im an idiot, forgot to type "end"I did this command and the game seems to not respond. Im waiting till it reponds Link to comment Share on other sites More sharing options...
Mobbstar Posted December 4, 2014 Share Posted December 4, 2014 Alternatively, you could type DebugSpawn("NAME") to put something there to solve the problem for you, say one-eye dan aka deerclops. Before you use monsters and such, I recommend trying DebugSpawn("gunpowder").components.explosive:OnIgnite()The ash will blow away soon after... Link to comment Share on other sites More sharing options...
Loscil2 Posted December 5, 2014 Author Share Posted December 5, 2014 Alternatively, you could type DebugSpawn("NAME") to put something there to solve the problem for you, say one-eye dan aka deerclops. Before you use monsters and such, I recommend trying DebugSpawn("gunpowder").components.explosive:OnIgnite()The ash will blow away soon after... Well, I won't know if this works because the most easy way to get rid of them was to move to another world.Anyways, when I tried to burn them it caused so much lag that the game froze and crashed. So yeah... Thanks for replying, though. Link to comment Share on other sites More sharing options...
squeek Posted December 5, 2014 Share Posted December 5, 2014 Well, I won't know if this works because the most easy way to get rid of them was to move to another world.Anyways, when I tried to burn them it caused so much lag that the game froze and crashed. So yeah... Thanks for replying, though. If removing all of them at once hangs/crashes, you could try deleting them in chunks instead: for i=1,50 do TheInput:GetWorldEntityUnderMouse():Remove() end Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.
Please be aware that the content of this thread may be outdated and no longer applicable.