Indestructible zombie help

Error message

Deprecated function: implode(): Passing glue string after array is deprecated. Swap the parameters in drupal_get_feeds() (line 394 of /var/www/pied-piper.ermarian.net/includes/common.inc).
AuthorTopic: Indestructible zombie help
Apprentice
Member # 4531
Profile #0
Thanks to everyone who weighed in about my special irem script. Now I need help with a creature/terain script. I want to make a creature that can get back up again after dying (after a few turns delay). The initial idea was to make the creature script place a custom terrain (corpse) when the creature dies. The custom terrain would then run a script that waits for a few turns before erasing itself and using place_monster to bring back the creature. The problem is, my corpse script runs fine, but only on corpses I place in the editor. It won't work for ones created by a creature script. Is there any way to place a new terrain script while the game is running? I guess I could make the town or scenario script handle this, but it would be rather clumsy as I'd need a separate call in START_STATE for each resurrecting creature.
Posts: 32 | Registered: Saturday, June 12 2004 07:00
Agent
Member # 2820
Profile #1
Unfortunately, you can't place terrain scripts dynamically as far as I know. I haven't tried placing a terrain with an inherent, attached terrain script while the game was running, so I encourage you to try that.

How many monsters will have this self-resurrection ability? If the amount of monsters is less than 15, I think it would still be viable to put the script into the START_STATE of the town.

Generally, script efficiency is not a huge, noticeable problem when it runs in combat mode, or after an important event (at least you have a reason for the slowdown). Therefore, if you can just make the code run after a creature dies, then things would work out. This might have been what you were trying to do with your original idea.

If you activate and deactivate a certain terrain script that performs this resurrection function at the appropriate times, then everything should run pretty efficiently. By deactivate I mean change its script mode to 0 (only run every 8 turns when party is nearby). There could be multiple counters, variables, and SDFs for when, what, and where to resurrect the creatures. Since this might become complex if you have too many creatures, then you could have counterpart creatures with scripts that can keep running after the initial creature has died. Of course, you are using extra creature slots, but there are always limits.

Placing the corpses will be difficult graphically unless you make sure that the creatures won't wander off to other types of floors and terrain.

--------------------
Thuryl: I mean, most of us don't go around consuming our own bodily fluids, no matter how delicious they are.
====
Alorael: War and violence would end if we all had each other's babies!
====
Drakefyre: Those are hideous mangos.
Posts: 1415 | Registered: Thursday, March 27 2003 08:00
Apprentice
Member # 4531
Profile #2
Thank you. There should be less than 15 creatures, so I'll go ahead and take your advice. The dungeon they're in will be a cave with a pretty simple floor, so the corpses shouldn't be a problem. I'll just have to make sure they can't knock down walls by dying on them.
Posts: 32 | Registered: Saturday, June 12 2004 07:00
Warrior
Member # 4202
Profile Homepage #3
quote:
Originally written by Eric-Ihrno:

Is there any way to place a new terrain script while the game is running?
No. I wish it was possible.

--------------------
Creator of the 3D Blades of Avernum Editor for Mac. Get it at Ingenious Isaac's Illusion, my web page. Better yet, get Battle for Wesnoth, a wonderful free TBS game.
Posts: 192 | Registered: Sunday, April 4 2004 08:00
Agent
Member # 2820
Profile #4
Make sure the room that the zombies are in only have exterior type walls. You might be able to make an easter egg out of it, though. You kill a creature in the right place and a wall explodes!

--------------------
Thuryl: I mean, most of us don't go around consuming our own bodily fluids, no matter how delicious they are.
====
Alorael: War and violence would end if we all had each other's babies!
====
Drakefyre: Those are hideous mangos.
Posts: 1415 | Registered: Thursday, March 27 2003 08:00