Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

FPSC Classic Scripts / Help with swarning script

Author
Message
ianio
15
Years of Service
User Offline
Joined: 1st Feb 2009
Location:
Posted: 13th Feb 2009 18:28
I am just attempting my first script so bear with me. The propose of the script is to swarn a bad guy when an entity is destroied. To do this I have added the entity and in it's 'activateifused' property added the name of the bad guy and added the script's name to it's 'AI main'. On the bad guy I have set 'swarn at start' to No and 'swarn after a delay' to Yes.

My script reads

;Artificial Intelligence Script
;Header

desc = swarn on destory

;Triggers

:state=0:animate=1
:state=0,shotdamage=1:state=1
:state=1:activateifused=1,state=2
:state=2,animate=0

;End of Script

From what I have read I understand that the first trigger line sets the animate to idle (value 1). Then line 2 sets the state to 1 if the entity has taken 1 shot damage. The thrid line then sets the entity's 'activtateifused' to 1 (I guess this ids the bad guy as the one to work with) and the final line then spawns the bad guy. Unfortunately absolutely nothing happens when I shot the entity. What newbie error am I making ?
Insert Name Here
17
Years of Service
User Offline
Joined: 20th Mar 2007
Location: Worcester, England
Posted: 13th Feb 2009 21:53
You mean spawn, not swarn.

Lee Bamber - Blame Beer
[Quote]They also call it gameplay because its a game...
Which you play{/quote] -Demonair
ianio
15
Years of Service
User Offline
Joined: 1st Feb 2009
Location:
Posted: 15th Feb 2009 20:35
Yes sorry I mean spawn. any thoughts anyone, please !!!!
X10 User
15
Years of Service
User Offline
Joined: 21st Jan 2009
Location:
Posted: 17th Feb 2009 22:00
try this

:state=0:animate=1
:state=0,healthless=50:activateifused=1

as the main ai for ur entity ur destroying

enter the name u want to spawn in its ifuse field

set the entity u are spawnings spawn at start setting to no

max spaw to 1

max at any time to 1

number to spawn to 1

shoot the entity ur spposed to destroy. when it gets to less than 50 health it spwns ur next one

change the health accordingly for how much damage it takes before activating

works for me

- Why is everyone on here so rude? -

Login to post a reply

Server time is: 2024-11-24 19:46:34
Your offset time is: 2024-11-24 19:46:34