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 / Need to fix this script..

Author
Message
Mr Love
19
Years of Service
User Offline
Joined: 9th Jun 2005
Playing: MAFIA 2
Posted: 17th Oct 2015 01:17
I want to do some tweaks in this script. First I want the animation to play once, and not once backwards. Second I want the water to raise a bit slower.
How do I do it? Here is the script:



;Artificial Intelligence Script

;Header

desc = switch_waterraise

;Triggers

:state=0:hudreset,hudx=50,hudy=90,hudimagefine=gamecore\text\pressentertouse.tga,hudname=useswitchprompt,hudhide=1,hudmake=display,state=10
:plrdistwithin=30:hudshow=useswitchprompt,hudfadeout=useswitchprompt

:state=10,plrdistwithin=30,plrusingaction=1:state=1,setframe=0,plrsound=$0,activateifused=1
:state=10:water=1,waterfogdist=250,waterred=210,watergreen=230,dimvar=waterlevel,setvar=waterlevel 595,waterheight=%waterlevel,dimvar=waterstate,setvar=waterstate 0,state=1
:state=1:incframe=0
:state=1:state=2
:state=2,plrusingaction=0:state=3
:state=3,plrdistwithin=30,plrusingaction=1:state=4,plrsound=$1,activateifused=0
:state=4:decframe=0
:state=4,frameatstart=0:state=5,setframe=0
:state=5,plrusingaction=0:state=10

;End of Script
ncmako
12
Years of Service
User Offline
Joined: 19th Feb 2012
Location: Hendersonville,NC
Posted: 18th Oct 2015 14:18
Hi Mr Love
This looks like a script for a switch? If it is I would separate the two scripts (switch & water part).
Quote: " I want the animation to play once, and not once backwards"

If you look at "state=1:incframe=0" then remove anything to do with the aimation
afterwards. Then take it to a "state" where nothing happens. Like this....

The have this script activate the water script.


To make it raise slower use a timer to add the variable.
best
My games never have bugs. They just develop random features..
Lots and lots of random features...

Login to post a reply

Server time is: 2024-11-21 13:32:34
Your offset time is: 2024-11-21 13:32:34