Frictional Games Forum (read-only)
Explode a rock barricade? - Printable Version

+- Frictional Games Forum (read-only) (https://www.frictionalgames.com/forum)
+-- Forum: Amnesia: The Dark Descent (https://www.frictionalgames.com/forum/forum-6.html)
+--- Forum: Custom Stories, TCs & Mods - Development (https://www.frictionalgames.com/forum/forum-38.html)
+---- Forum: Development Support (https://www.frictionalgames.com/forum/forum-39.html)
+---- Thread: Explode a rock barricade? (/thread-17474.html)



Explode a rock barricade? - Froge - 08-04-2012

I haven't found a thread or a video on this yet, so I suppose this might be a bit complicated to script. In fact, I'm posting this topic because I actually have no idea where to even start.

You guys know the rock wall in Storage that needed to be taken out with an explosive? I'm trying to replicate the same explosion and clearing of path, only with the hammer and chipper (the combined item) instead. I'm not very certain on what scripts to use. Could any of you guys help me here?

Edit: I'm guessing on the level editor I'll need to place a bunch of rock entities to block a path, then fill the area where they're placed up with a script that indicates where the explosion will happen. In terms of actual scripting though, I'm clueless; I have no idea how to script the removing of the rock entities.


RE: Explode a rock barricade? - Your Computer - 08-04-2012

If we're talking about entities/special/cave_in, then just reduce the entity's health to 0.


RE: Explode a rock barricade? - Froge - 08-06-2012

No. I've actually just placed a whole bunch of rock entities to fill up an opening in a wall and surrounded it with area scripts. Once the player uses the H & C item on any of these rock entities, particle systems go kaboom at the area scripts and all the rocks disappear.

I specifically need a function that says "All these rocks disappear."

Edit: And I'm a complete moron. One second after making this post I found the "SetEntityActive" function. Move along, folks, nothing to see here.