Hard Light Productions Forums
Modding, Mission Design, and Coding => The FRED Workshop => Topic started by: Kinman on November 21, 2008, 08:50:13 am
-
Hi. I want to do something after the player has rearmed.
I set a support ship manual and used the is-undocked-delay with the supportship and the player, but it didn't work.
(http://photo-sorko.at/bilder/sexp_rearm.gif)
I tried to swap Support 1 and Alpha and with different delays, but nothing happens. The support ship is docking, rearming and undocking but the event didn't fire...
Is there anything like has-rearmed-delay or do you have any other idea?
Thank you, Kinman
-
What are ya trying to do?
-
Hmm... I really don't want to talk about this yet... It should be a little surprise in my campaign and there's no other way to do this. I must know when the supportship either docks or undocks.
I'm testing it with send-message.
-
What about using a . . . . .
"once secondary count -Alpha 1 - <50%
AND
once secondary count -Alpha 1- >99%
delay - 1
Then - send message / self destruct / supernova start (for example ;))
-
Test it with something that can't fail. Like Self-destruct Alpha 1 :D There are several reasons why a message could fail to be sent.
If you actually put a support ship in the mission rather than allowing the player to call it in themselves that should have worked though.
-
But my theory is sound right? :nervous:
/me awaits the green light from Karajorma.
-
Use when-argument with Support 1 specified manually and has-docked-delay. You can use it like this to do things with ships that aren't in the mission file itself.
-
I've tried everything i could imagine and nothing worked.... I took me three days.
I wanted to change the secondary loadout with a support ship. The loadout-change works perfectly but i don't get an event when the supportship docks/undocks.
It was only a minor "goodie" but I canceled it.
Greetings Kinman
-
hmm.
You could hack it with a distance SEXP.
-
But my theory is sound right? :nervous:
/me awaits the green light from Karajorma.
I don't think so. That event would fire as soon as your secondaries dipped below 50%, since FS would recognizer the >99% as soon as the mission started. You might be able to do it with and-in-sequence, if and-in-sequence wasn't so **** (though this sounds like something it's pretty much designed for). Plus you'd need to make sure the secondaries dipped below fifty percent - the sexp wouldn't fire if you rearmed at fifty one percent, for example.
It might work with
and-in-sequence
- <
- -secondary-ammo-pct
- - - Alpha 1
- - - 4
- -99%
- >
- -secondary-ammo-pct
- - - Alpha 1
- - - 4
- -99%
-
There's nothing wrong with and-in-sequence. It's just that people misuse it and then think it's broken. :)
-
I know that on a conscious level. But I've got a deeply ingrained dislike of it and I'm not going to give that up over something as trivial as "the facts".
-
Can't say I blame you. I'm a little wary of it myself. It's very easy to trap yourself into doing something very stupid with it. :)
-
Or in my case, crashing the game. :nervous:
-
Huh?