Hard Light Productions Forums

Modding, Mission Design, and Coding => The FRED Workshop => Topic started by: bomb3rman on May 24, 2017, 05:08:12 pm

Title: Red-alert -> Gamma destroyed at start
Post by: bomb3rman on May 24, 2017, 05:08:12 pm
I found a very strange situation while testing:

M 1 -> Alpha (A1 Player) and Beta, both red alert carry status. Red alert mission, leads to

M 2 -> Alpha (A 1 player) and Beta appear correctly with their status like they had when M 1 ended.

Additional wings in M 2: Gamma and Delta (and Epsilon, jumping in later).

Delta is fine, but Gamma is destroyed from the start on. Though they are protected via events... I still can't get my head around it... Why? Delta and Gamma are equal, except for the fact that Gamma is protected. Why is this happening? Any ideas?

When I give them other Wing names, they are fine. They just don't appear in the Wingmen list, as usual... So it's not a big deal, but I'm wondering...
Title: Re: Red-alert -> Gamma destroyed at start
Post by: 0rph3u5 on May 24, 2017, 05:19:03 pm
Red Altert is a strange beast... and you propabily need someone with exact knowledge of the code to tell you what is wrong

Have you tried going into the Mission Specs-Editor and changing the settings under "Custom Wing Names" in Mission 1?
Title: Re: Red-alert -> Gamma destroyed at start
Post by: AdmiralRalwood on May 24, 2017, 05:33:53 pm
Almost certainly has to do with Gamma being one of the wings that show up in the loadout screen, which means the engine automatically gives it red-alert-carry status, and since it (presumably) didn't have a status to carry over, decides it should be dead right off the bat.
Title: Re: Red-alert -> Gamma destroyed at start
Post by: bomb3rman on May 24, 2017, 05:38:50 pm
Red Altert is a strange beast... and you propabily need someone with exact knowledge of the code to tell you what is wrong

Have you tried going into the Mission Specs-Editor and changing the settings under "Custom Wing Names" in Mission 1?

If I give Gamma another custom name in M 1, the ships in M 2 are there called "Gamma", though they don't appear on the Wingmen list...

EDIT: IF I give Gamma in M 1 the name "Test" and do the same in M 2, they are still destroyed at the beginning of the mission...

Almost certainly has to do with Gamma being one of the wings that show up in the loadout screen, which means the engine automatically gives it red-alert-carry status, and since it (presumably) didn't have a status to carry over, decides it should be dead right off the bat.

But in M 1 there is no Gamma... Or do you mean that it IS ALWAYS in the loadout screens, though it's not shown there?
Title: Re: Red-alert -> Gamma destroyed at start
Post by: AdmiralRalwood on May 24, 2017, 05:52:40 pm
But in M 1 there is no Gamma... Or do you mean that it IS ALWAYS in the loadout screens, though it's not shown there?
No, I mean it's in the loadout screen of the second mission, and so is trying to carry over its status from the previous mission (which doesn't exist).
Title: Re: Red-alert -> Gamma destroyed at start
Post by: bomb3rman on May 24, 2017, 06:08:01 pm
Ah ok... Thanks for the information.

I solved the problem by renaming Gamma and Delta, they really don't need to be part of the wingmen-list. Feels better this way, anyway...
Title: Re: Red-alert -> Gamma destroyed at start
Post by: 0rph3u5 on May 24, 2017, 06:12:35 pm
Red Altert is a strange beast... and you propabily need someone with exact knowledge of the code to tell you what is wrong

Have you tried going into the Mission Specs-Editor and changing the settings under "Custom Wing Names" in Mission 1?

If I give Gamma another custom name in M 1, the ships in M 2 are there called "Gamma", though they don't appear on the Wingmen list...

EDIT: IF I give Gamma in M 1 the name "Test" and do the same in M 2, they are still destroyed at the beginning of the mission...

Okay, that rules out one version of the theory about the cause - which is the same as AdmiralRalwood is saying that 3rd Player wing gets RA-carry-status by default and the engine is just saving an array of zeros for all values associated.

As for the solution:

Place a Gamma Wing (with the loadouts for M2) in M1 which arrives just a second before the Red Altert is finished triggering (if I recall correctly Red Altert requires 2-4 seconds from being triggered to actually end the mission)... Set the flags for "No Arrival Music", "No Arrival Message" and "No Warp Effect" and place them far away from the player.

Try if that helps.
Title: Re: Red-alert -> Gamma destroyed at start
Post by: bomb3rman on May 25, 2017, 06:31:11 am
Yes that solved the problem, now Gamma appears correctly in M2.

The only downside is that Gamma appears at the loadout-screen in M 1, this might be a bit confusing but I think I can live with that...
Title: Re: Red-alert -> Gamma destroyed at start
Post by: 0rph3u5 on May 25, 2017, 09:39:34 am
That can easily be solved by dropping a line in the briefing ala "Gamma wing is kept on stand-by" or "Gamma wing is on another mission at the moment".

The second case you can lock their loadouts in the Ship Editor with "Ship Locked"-flag.
Title: Re: Red-alert -> Gamma destroyed at start
Post by: bomb3rman on May 25, 2017, 10:24:21 am
Yeah I already locked them. Thx a lot You two, this helped :-)
Title: Re: Red-alert -> Gamma destroyed at start
Post by: xenocartographer on May 25, 2017, 02:44:48 pm
If you go into the custom wing names editor for the first mission (it's under mission specs), you can replace Gamma with some nonexistent wing to stop them showing up.
Title: Re: Red-alert -> Gamma destroyed at start
Post by: AdmiralRalwood on May 25, 2017, 02:47:24 pm
Although you'll then need to manually enable red alert carry status for Gamma.
Title: Re: Red-alert -> Gamma destroyed at start
Post by: bomb3rman on May 25, 2017, 05:00:15 pm
Excellent, I thought about something like this with the custom wings. Now it's working perfectly, thanks for this!