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 / Enemy stops when reaches to wall

Author
Message
DWF
14
Years of Service
User Offline
Joined: 21st Jun 2010
Location:
Posted: 30th Jun 2012 15:53
How to create a script that enemy shooting while moving backwards or strafe but when he reaches the wall or some entity, then he stops?
DWF
14
Years of Service
User Offline
Joined: 21st Jun 2010
Location:
Posted: 1st Jul 2012 11:38 Edited at: 1st Jul 2012 11:40
ok, so, maybe I explain more precisely what I mean

I've slightly modified default Strafe10 script. I've added a new Moving Backwards animation, but this animation based on strafe command.
Now I would like to stop strafe animation and start idle animation, when character will be very close to the wall or entity.

Here is the script:



Thanks in advance for any help
The Zombie Killer
13
Years of Service
User Offline
Joined: 27th Mar 2011
Location: Gold Coast, Australia
Posted: 1st Jul 2012 11:43
@DWF
You can accomplish this by using the "raycast" commands. Those commands are for checking whether there is something in the way of the object. I don't remember the commands off the top of my head, but I'm sure that they'd be the thing to use.

-TZK

DWF
14
Years of Service
User Offline
Joined: 21st Jun 2010
Location:
Posted: 1st Jul 2012 11:58
Thanks @The Zombie Killer

I already tried to use this command but it doesn't work. Probably I did something wrong

Login to post a reply

Server time is: 2024-11-24 00:28:35
Your offset time is: 2024-11-24 00:28:35