Ok....maybe if I'm a little more specific you guys will actually
help me. (simply telling me
you/someone can get something to work does absolutely nothing to aid me in my own struggles with the scripting language.)
So far, for the zombie AI, I have this....
;WALKING WAYPOINTS
:waypointstate=0:animate=92,waypointstart
:waypointstate=3:animate=92,waypointnext
:waypointstate=4:animate=92,waypointrandom
:waypointstate=5:animate=92,waypointstop
;At end of waypoint, target barricade and move to it
:state=0:settargetname=barricade1,rotatetotarget,movetotarget
:state=0,reachtarget:timerstart,state=1
;Attack barricade
:state=1,timergreater=1000:activatetarget=1,sound=audiobank\zombie_apocalypse\malemoan3.wav,timerstart
:state=1,activated=1:state=3
;Follow Player
:state=3:followplr,animate=92
:state=3,plrdistwithin=100:state=4
;MELEE ATTACK 1 (DOUBLE ARM SLASH)
:state=4,plrdistfurther=60:rotatetoplr,runfore=10,animate=92
:state=4,plrdistwithin=60:rotatetoplr,setframe=98,state=7
:state=7,framebeyond=98 40,plrdistwithin=60:plraddhealth=-5,sound=audiobank\zombie_apocalypse\malemoan3.wav,state=8
:state=7:incframe=98,rotatetoplr
:state=7,frameatend=98:state=3
:state=8,framebeyond=98 60,plrdistwithin=60:plraddhealth=-2,sound=audiobank\misc\melee.wav,state=9
:state=8:incframe=98
:state=8,frameatend=98:state=3
:state=9:incframe=98
:state=9,frameatend=98:state=3
When coupled with my barricade script, this does cause the zombies to approach and break down the (currently unanimated)barricades, but once that is done some weird things start happening, like zombies running in place or into a wall while I'm two feet away in the same room.
Also, I cannot replace them once the barricade is gone.
Also, I've been trying to get 'player built' barricades (built in any doorway in the house) to work. Instead of losing health, like the normal barricades (only on entrances), they simply exist for a set ammount of time before being destroyed (I can't figure out how to tell every zombie to look for and target something that may or maynot be there). This work around should still give the player some breathing room, but not save them completely.
I have the barricade spawning when the player stands in a specific zone and presses the F key. The barrier appears, but the player and zombies can simply pass right through it, and dispite the fact I am turning the spawning ability off again within the script, it keeps respawning, even when the player isn't in the zone or pressing the F key.
Here's the code for player barricades
:state=0,activated=1:spawnon,colon,state=1
:state=1,activated=0:spawnoff,state=0
As you'll notice, I've even tried manually turning the collision on with the colon action, and still I can run right through the object. I can think of absolutely no reason why this is occuring, as the object is set to use physics, and I manually instruct it to turn on collision detection.