HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

Placing Destructibles

12-18-2011, 01:49 AM#1
Tastingo
Is it possible to move Destructibles like Doodads? I set the pathing of my destructible to mushroom, but I can't just nudge the Destructible like I can with a Doodad. It always moves ONE TILE over. I know I can use the function CreateDestructible but that would be very tedious. Is there anyway to move Destructibles without them having to move them an entire tile over?
12-18-2011, 03:39 AM#2
cohadar
You can always create a new Destructible and give it the model and pathing from a Doodad. You can also do the reverse.
12-18-2011, 04:47 AM#3
Tastingo
I gave it the pathing of the doodad mushroom and I still cannot place it wherever, like a doodad. I cannot make it a doodad because I am using the destructibles for a missle system.
12-18-2011, 05:26 AM#4
cohadar
systems... making your life harder just for the fun of it.

My new design philosophy proves true every day,
the less systems you use, the happier you will be.

EDIT:
In case you did not figure it out yourself: you are fucked when it comes to dodoAds
12-18-2011, 06:09 AM#5
Tastingo
Fuck you destructibles. Bitch
12-18-2011, 10:35 AM#6
Anitarf
I am at a loss as to why you'd need preplaced off-grid destructables for your missile system. Perhaps you can use units instead?
12-19-2011, 05:11 AM#7
Nuclear Arbitor
does shift not work? do you have some sort of place on grid option on?
12-19-2011, 09:25 PM#8
Tastingo
I have units now, but I wanted to see if I could use destructibles instead. When I first made my map I checked for destructibles, and I was just using the walls as destructibles. And checked within a radius. This sucked because the hitboxes on the walls were weird. So I used units instead. However now it is lagging when like 6-8 people shoot. Since they are locusted I have to look through all the units in the map and compare the distance, so I think that's what was causing the lag. I wanted to try and go back to destructibles, except make invisible walls on the walls.

I have maybe about 120 units in walls, do you think having to search through that many would be the cause of the lag. I think I used GetUnitsOwnedByPlayer() to get the locust units. Or do you think it's my code?

Also I noticed it wasn't moving the destructibles one tile over. If you display the small grid tiles it moves two of the small grid tiles over. It would be perfect if it just moved one small tile over, or if it wasn't locked to having to be placed on the grid. I can stack as many destructables on top of each other as I want, I just can't move them wherever I want...
12-19-2011, 09:38 PM#9
Anitarf
Searching through 120 walls for each projectile is quite terrible - a GroupEnumUnitsInRange would have likely given you less than one wall per projectile, so you are literally using hundreds of times more computing power on wall collision detection than you have to.
12-19-2011, 10:58 PM#10
Tastingo
Does that, pick up locust units?
12-20-2011, 09:57 AM#11
Anitarf
No, units with locust do not get picked by range enums, you need to make your wall units without locust. I think there are alternate tricks for making units unselectable.
12-20-2011, 09:33 PM#12
Tastingo
Ah thank you, found a way!