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 / script question: the rate of the action :plraddhealth=-2

Author
Message
Brian In Korea
15
Years of Service
User Offline
Joined: 1st Mar 2009
Location:
Posted: 7th Mar 2009 02:33
I'm a little confused by a simple piece of code I tested. Thought I'd share it with the board and see if anyone can explain it.



I saved it as test01.fpi. Made a floor out of ground segments and placed a crateD in the top left corner (0,0,0). Assigned the script to the main AI spot for crateD. Placed my start point about 300 units away.

Whenever I test it, my health starts to plummet rather fast. When I move back to around 500 my health starts to slowly increase 1 point every 2 seconds. When I go back to my start point at around 350 my health will slowly decrease at around 2 points per second. If I get within 100 units of the crate my health will quickly plummet.

What is determining the rate of my health increasing and decreasing and why does the distance affect the rate?

Edit: Oh, I just figured it out, its rather interesting. I'll leave this posted to see what others think.

Login to post a reply

Server time is: 2024-11-24 20:24:34
Your offset time is: 2024-11-24 20:24:34