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 / Boulder Trap Problem

Author
Message
darkPrince010
15
Years of Service
User Offline
Joined: 10th Nov 2009
Location:
Posted: 11th Nov 2009 20:44
I've been trying to create a rolling stone trap (A-la Indiana Jones style), with a stone that falls into a lava pit then respawns at the top of a ramp. I want it to be ongoing, but the trap only works and damages the player until it lands in the pit the first time (where I have the triggers to destroy the rock and force it to respawn).
Here's the code for the boulder:

;Artificial Intelligence Script
;Header
desc = Plr In Zone
;Triggers
:state=0,plrdistwithin=80:plraddhealth=-50,activated=0,state=0
:state=0,activated=1:activated=0,destroy,sound=$0

And here's the script for the lava pit zone that destroys the rock:

;Artificial Intelligence Script
;Header
desc = Plr In Zone
;Triggers
:state=0,anywithinzone=1:activateallinzone=1,state=0

In addition, when the boulder touches the player after it respawns at least once, it automatically respawns without calling the damage player action. I wasn't sure if the player entity automatically activated nearby objects, or what the cause of the forced destroy when it hits the player, because I thought all objects spawn deactivated and at state=0 unless otherwise stated...

When you boil a lobster, they call you a chef...
But when you boil a kitten, they make a big deal out of it...
Plystire
21
Years of Service
User Offline
Joined: 18th Feb 2003
Location: Staring into the digital ether
Posted: 11th Nov 2009 22:04
Quite the issue indeed.

Only thing wrong with your script that I can spot (and it doesn't appear to have detrimental effects on your script) is that you're using "activated" as an action. You should be using "activate" (Without the "d" at the end) to make an entity activate itself.


The one and only,


Login to post a reply

Server time is: 2024-11-25 05:41:12
Your offset time is: 2024-11-25 05:41:12