Read-only archive of the Armageddon Games Forums Archive (2000–2026) · About this archive

Spawning Enemies

5 replies · 1,852 views · Started 26 November 2006

Yes. Use CreateNPC() to make a new enemy, then set the attributes of the resulting npcs like you would an item or FFC. Look in the ZScript documentation for details.

Also, I believe there's a topic in beta discussion where DN laid out the entire enemy definitions and constants, which should help in determining how you want to construct the enemy.

CreateNPC isn't working now. At least, the syntax isn't obvious.

This doesn't compile:


npc spawned_enemy = CreateNPC(enemy_id);
spawned_enemy->X = this->X
spawned_enemy->Y = this->Y

Compiler doesn't like the first line, says I need an identifier.