Type: Enemy brain
Level: 3 star
Pages: 1
Description: Designed for the Zombie characters. When they kill the dead character is replaced with a zombie female. Warning: You need to add kode to your player to prevent your game just stopping if your player is killed by the zombie. The female zombie that is created is a NPC and you do not have controls any more.
Kode
- WHEN [once] DO [team][equals][team 3]
Attacking kode - WHEN [enemies][nearest object][or][player][neutrals][nearest object] DO [objvar:my enemy][equals][it]
- WHEN [distance to][objvar:my enemy][less than][20][and][distance to][objvar:my enemy][greater than or equal to][2]
- …WHEN DO [move][at speed][0.25][toward][objvar:my enemy]
- WHEN [countdown timer][numvar:pause attack][loop]
- …WHEN [distance to][objvar:my enemy][less than or equal to][2] DO [attack][light][objvar:my enemy][with windup][end combo]
- …WHEN DO [numvar:pause attack][equals][random number][1][to][2]
Zombie creation - WHEN [for each of][killed objects]
- …WHEN DO [it][destroy after death][equals][false]
- WHEN [countdown timer][2]
- …WHEN DO [play fx][fx: Grave burst][at position][it][position]
- …WHEN [countdown timer][0.5] DO [create][Zombie female][at position][it][position]
- …/… DO [destroy][it]
Alterations
No zombie creation
remove lines 8-13