Hard Light Productions Forums

Modding, Mission Design, and Coding => The FRED Workshop => Topic started by: TrashMan on September 26, 2008, 10:06:36 am

Title: Branching.
Post by: TrashMan on September 26, 2008, 10:06:36 am
Well, I started putting together my campšaing in the camapign editor and I realised I forgot how to make branching.

K, one way would be to drag Mission01 into mission2a and 2b, creating two branches and setting up the True even for each to correspond to some previous event. However, that only works if I want the mission to branch depending on something the player did within the mission.

What I'm after is more like a loop (you get asked before a mission), expect if you klick yes you get one set of mission, and if you click no you get another one. I'm sure I can figure it out myself, but it's faster to ask

Title: Re: Branching.
Post by: Shade on September 26, 2008, 10:19:57 am
Select the branch in the branches box to the left of the campaign tree, and click the "Toggle Loop" button.
Title: Re: Branching.
Post by: TrashMan on September 26, 2008, 11:34:26 am
Yeah, I gather that. However, from Mission5, I have a branch to both mission 5a and mission5b.

Loop should lead to 5a, and no loop to 5b. However, I do get some error.
Crapola...whenever I get into the campaign editor it crashes...unhandeled Win32 exception...just great :P
Title: Re: Branching.
Post by: karajorma on September 26, 2008, 11:52:27 am
Run the debug build. There is a crash in the release build I've never been able to track down.
Title: Re: Branching.
Post by: TrashMan on September 26, 2008, 03:42:47 pm
Well, I get a whole bunch of warnings about imact explosion for various weapons not having LO0 anims and ballistic weaponry warning. Pretty standard stuff.
the only thing that stands out is something about a too long weapon name and this (which caused FRED to not start at all)



Assert: count < max_ints
File: parselo.cpp
Line: 2479


Call stack:
------------------------------------------------------------------
    fred2_open_3_6_10d-20080926_r4832.exe 009907fc()
    fred2_open_3_6_10d-20080926_r4832.exe 0098bfc8()
    fred2_open_3_6_10d-20080926_r4832.exe 00993aa6()
    fred2_open_3_6_10d-20080926_r4832.exe 0099406f()
    fred2_open_3_6_10d-20080926_r4832.exe 00874022()
    fred2_open_3_6_10d-20080926_r4832.exe 008698f7()
    fred2_open_3_6_10d-20080926_r4832.exe 00dc7c7c()
    fred2_open_3_6_10d-20080926_r4832.exe 00dc7412()
    fred2_open_3_6_10d-20080926_r4832.exe 00dc3bc0()
    fred2_open_3_6_10d-20080926_r4832.exe 00dc42d6()
    USER32.dll 7e418734()
    USER32.dll 7e41d05b()
    USER32.dll 7e41b4c0()
    USER32.dll 7e41f9fe()
    ntdll.dll 7c90eae3()
------------------------------------------------------------------
Title: Re: Branching.
Post by: karajorma on September 26, 2008, 03:54:07 pm
/me is not touching this topic with a "10 barge pole.
Title: Re: Branching.
Post by: Aardwolf on September 26, 2008, 04:48:35 pm
That is a particularly nondescript assert message.

Also that debug build doesn't seem to have debugging symbols (the functions don't have names, just memory locations)...
Title: Re: Branching.
Post by: TrashMan on September 26, 2008, 05:30:11 pm
Well, I used the latest Nighly Build exe's

The latest build Compaaing editor doesn't crash on start b.t.w.
It does when I make a loop in a campaign and try to save tough (as didithe other 2 builds). Either the loop is bugged or I'm doing something REALLY wrong

Title: Re: Branching.
Post by: Aardwolf on September 30, 2008, 03:07:14 am
Hey, TrashMan! I had an idea that might work, but I haven't tried it or even thought about it too much.

What if you had both missions (5a and 5b) have a cutscene and nothing else? Then use some fancy is-previous-event-true sexps to make it run 6a and 6b (which would basically be what you wanted to put in 5a and 5b)...

Or you could just do like that with actual missions, but then they'd have the opportunity to exit loop when you don't want them to.

Not sure if this would work.

KTHX
Title: Re: Branching.
Post by: TrashMan on September 30, 2008, 05:36:23 am
I'm pretty sure I've done something wrong here, but I don't know exactly what. I've forgot my loops :o

So to explain better.
I got mission 5 that has two branches...to 5a (normal branch) and to 5b (loop). Both branching conditons are set to true.
Title: Re: Branching.
Post by: karajorma on September 30, 2008, 05:46:21 am
*pokes head back into thread*


Once you can run your mod though a debug build I'll help with this problem but it is a complete waste of my time to do that while you can't even run the campaign editor in debug mode.
Title: Re: Branching.
Post by: TrashMan on September 30, 2008, 06:09:07 am
Maybe the debug is bugged? :D

Hell, all missions work fine for me, it's the campaign editor that's wonky. I'll try some other builds.


However, what you missed is that I was asking the PROPER PROCEDURE when making a simple branching.

    5
  /   \
5a  5b
  \   /
    6

See, I want this, but I'm not sure how to go about it...Damn my terrible memory.
Title: Re: Branching.
Post by: karajorma on September 30, 2008, 06:34:09 am
And Shade has already explained how to do that.
Title: Re: Branching.
Post by: TrashMan on September 30, 2008, 06:46:31 am
So basicely, like this: (\\ is loop)

    5
  /   \\
5a  5b
  \   /
    6


So after mission 5 is over, I should get that SOC assigment window (with whatever text I type in).
If I click accept I got to 5b, if I click no I go to 5a?