Hard Light Productions Forums
Modding, Mission Design, and Coding => The FRED Workshop => Topic started by: Akalabeth Angel on September 28, 2004, 01:41:51 am
-
Okay, in a mission I'm making I am trying to have it semi-stealth, and as such the player cannot fire his weapons or he gets in trouble (and fails his mission) basically. What I've done, is have a directive for maintaining stealth, which depends upon two events not becoming true (the two stealth types, the other is not using afterburners).
Anyway, so what I have for the events is basically this:
Event One
-when
---key-pressed
----Left Ctrl
---send-message
----quit shooting jerk
Event Two (Chained, delay 10)
-when
---key-pressed
----Left Ctrl
---send-message
----well that does it nimrod
The problem is, when I fire off my weapons it sends the first message, and then the second message. But I want a ten-second grace period so the player can stop firing before he gets the second message and fails the mission.
It works with the afterburner stealth bit:
Afterburner Event
-when
---is-event-true-delay
----yadda yadda
---set-training-context-speed
----X
----Y
Afterburner Event Two
-when
---and
-----speed
------5
-----is-event-true-delay
------event one
---send-message
----slow down you jerk
Then event two is repeated in a chain-event fashion like the weapons fire, but it works for some reason, while the weapons fire thing does not.
Anyone know what the deal is?
-
Key-pressed doesn't reset when it fires so you'll have to use key-reset:
event 1.5 (chained to event 1, 10 sec delay)
-when
--true
--key-reset
---left ctrl
chain event 2 to this one with no delay.
-
Cool thanks
-
you may get probs with people remapping keys or using joysticks though
-
No, you wont. FS2 compensates for that.