Author Topic: Campaign-Endmovie  (Read 4327 times)

0 Members and 1 Guest are viewing this topic.

Offline Starman01

  • 213
  • Mechwarrior
    • Wing Commander Saga
Hey there,

I'm posting this here, since my question is related to the campaign file.

How can I make my outro-movie play after the final misson has ended (so no debriefing will be displayed).

We are using 3.6.7, is it hardcoded to "endgame.avi" or something similar and will be played when the campaignfile has the "end-campaign" trigger, or must we even play around with the "start supernova" thing to make it play (I remember it being that way the past).

Thanks in advance.

Starman
MECHCOMMANDER OMNITECH

9 out of 10 voices in my head always tell me that I'm not insane. The 10th is only humming the melody of TETRIS.

 

Offline Shade

  • 211
One way to sorta get what you want is to set the mission to have no debriefing, then add an extra mission to play the movie, set that mission to have neither briefing or debriefing and only a single event that executes immediately to end the mission and the campaign. Or maybe roll credits using training messages for a bit to pimp yourself ;)

As for whether it's hardcoded, I don't know but I'll take a look if noone else answers this one within a reasonable time.
Report FS_Open bugs with Mantis  |  Find the latest FS_Open builds Here  |  Interested in FRED? Check out the Wiki's FRED Portal | Diaspora: Website / Forums
"Oooooooooooooooooooooooooooooooooooooooh ****ing great. 2200 references to entry->index and no idea which is the one that ****ed up" - Karajorma
"We are all agreed that your theory is crazy. The question that divides us is whether it is crazy enough to have a chance of being correct." - Niels Bohr
<Cobra|> You play this mission too intelligently.

 

Offline karajorma

  • King Louie - Jungle VIP
  • Administrator
  • 214
    • Karajorma's Freespace FAQ
It's hardcoded and the campaign has to be called Freespace2.fc2 for it to work.
Karajorma's Freespace FAQ. It's almost like asking me yourself.

[ Diaspora ] - [ Seeds Of Rebellion ] - [ Mind Games ]

 

Offline Shade

  • 211
Yup, just checked. Hardcoded to endpart1.mve plus endprt2a/b.mve (depending on ending). Looks trivial to get rid of the campaign name requirement, but that would have bad results for campaigns not including their own movies. When I get time I think I'll look into some way of letting campaigns play a movie of their own at the end without making existing campaigns play the fs2 movies, as would happen if I just commented out the name check.

It doesn't look hard, it's just that right now I'm trying to fix a bug that is being excruciatingly annoying to pin down, and that has priority over a new feature.
« Last Edit: May 06, 2006, 09:52:38 am by Shade »
Report FS_Open bugs with Mantis  |  Find the latest FS_Open builds Here  |  Interested in FRED? Check out the Wiki's FRED Portal | Diaspora: Website / Forums
"Oooooooooooooooooooooooooooooooooooooooh ****ing great. 2200 references to entry->index and no idea which is the one that ****ed up" - Karajorma
"We are all agreed that your theory is crazy. The question that divides us is whether it is crazy enough to have a chance of being correct." - Niels Bohr
<Cobra|> You play this mission too intelligently.

 

Offline Starman01

  • 213
  • Mechwarrior
    • Wing Commander Saga
So, renaming the campaign file would be a solution (however then we would maybe have to select a campaign called FS-Maincampaign in the selection). What worries me really is the filename. Is it necessary to be a .mve to work ? Our Movie is an avi (I'm not good enough in these things to know if it can be converted though).
MECHCOMMANDER OMNITECH

9 out of 10 voices in my head always tell me that I'm not insane. The 10th is only humming the melody of TETRIS.

 

Offline Shade

  • 211
In fs_open, it can be avi. In fact, using an .mve would not always work as that is only supported on the Linux version for the time being. Retail only has support for .mve though. Anyway, I'll take a look at the movie thing after I get this bug fixed since it could be of use to lots of campaigns, so you may not need to worry if you're still a while from release.
Report FS_Open bugs with Mantis  |  Find the latest FS_Open builds Here  |  Interested in FRED? Check out the Wiki's FRED Portal | Diaspora: Website / Forums
"Oooooooooooooooooooooooooooooooooooooooh ****ing great. 2200 references to entry->index and no idea which is the one that ****ed up" - Karajorma
"We are all agreed that your theory is crazy. The question that divides us is whether it is crazy enough to have a chance of being correct." - Niels Bohr
<Cobra|> You play this mission too intelligently.

 

Offline karajorma

  • King Louie - Jungle VIP
  • Administrator
  • 214
    • Karajorma's Freespace FAQ
Personally I think adding a final credits mission or a "WCP will return in release 2" mission is a much better idea than renaming the campaign file.
Karajorma's Freespace FAQ. It's almost like asking me yourself.

[ Diaspora ] - [ Seeds Of Rebellion ] - [ Mind Games ]

 

Offline Starman01

  • 213
  • Mechwarrior
    • Wing Commander Saga
Could you specify that please ? What exactly do you have in mind ?
MECHCOMMANDER OMNITECH

9 out of 10 voices in my head always tell me that I'm not insane. The 10th is only humming the melody of TETRIS.

 

Offline Shade

  • 211
I'm thinking a good way to do it would be to get rid of the campaign filename check in freespace.cpp allowing it to post GS_EVENT_END_CAMPAIGN for any campaign, and then instead have the only filename check in mission_campaign_end_do to make sure the fs2 movies are played only for the fs2 campaign, and for any other campaign look for a movie called <campaign filename>_end.avi and play that. Then if the movie does not exist, post GS_STATE_DEBRIEF to allow a debriefing to commence (actually might be better to have that check in freespace.cpp for less work in case of no movie).

Sorry if that sounds a bit technical :) In english, it would mean that for a campaign called wcsmain.fc2, it would look for and if it exists play a movie called wcsmain_end.avi. Assuming I can make it work of course, but as I said earlier it does not look too hard.
« Last Edit: May 07, 2006, 06:00:20 am by Shade »
Report FS_Open bugs with Mantis  |  Find the latest FS_Open builds Here  |  Interested in FRED? Check out the Wiki's FRED Portal | Diaspora: Website / Forums
"Oooooooooooooooooooooooooooooooooooooooh ****ing great. 2200 references to entry->index and no idea which is the one that ****ed up" - Karajorma
"We are all agreed that your theory is crazy. The question that divides us is whether it is crazy enough to have a chance of being correct." - Niels Bohr
<Cobra|> You play this mission too intelligently.

 

Offline Starman01

  • 213
  • Mechwarrior
    • Wing Commander Saga
Thanks. That would be non-plus-ultra (as we say in german :D) though I didn't want to ask for another codechange (or goober will mostly rip my skin off :D )

However, we will need another solution for the upcoming release 1, so what do you have in mind kara with that credit-mission ?
MECHCOMMANDER OMNITECH

9 out of 10 voices in my head always tell me that I'm not insane. The 10th is only humming the melody of TETRIS.

 

Offline Shade

  • 211
The credit mission is simple enough in concept. In the campaign editor, you have the option to add a cinematic before a mission briefing. So you add an extra mission and have that mission play your end movie as the pre-briefing movie, then just terminate the mission at once (or, as suggested, use it to roll credits using training messages).

That would also allow different movies for different endings (which I assume is why you'd need a different solution to the codechange one), as you can simply link to different missions based on the events that occurred in the campaign.
Report FS_Open bugs with Mantis  |  Find the latest FS_Open builds Here  |  Interested in FRED? Check out the Wiki's FRED Portal | Diaspora: Website / Forums
"Oooooooooooooooooooooooooooooooooooooooh ****ing great. 2200 references to entry->index and no idea which is the one that ****ed up" - Karajorma
"We are all agreed that your theory is crazy. The question that divides us is whether it is crazy enough to have a chance of being correct." - Niels Bohr
<Cobra|> You play this mission too intelligently.

 

Offline karajorma

  • King Louie - Jungle VIP
  • Administrator
  • 214
    • Karajorma's Freespace FAQ
Yep. Raider Wars for TBP is a good example of how to do one. They simply had a shot of B5 with a shuttle flying towards it and a standard message saying what would be the name of their next campaign.

Then you simply add some credits to appear as messages in the mission (models by x, FREDding by y etc).

The cutscene you want to play is then basically treated in exactly the same way as any other cutscene in the campaign.


@Shade : While you're poking around in the cutscene code how hard would it be to make the standard ending cutscenes play regardless of whether the name is endpart2a or endprt2a? Cause there are a lot of people out there with the wrong filename since the downloaded cutscenes were incorrectly named when uploaded (not certain if I named them incorrectly of if I got them from TurboNed that way).
Karajorma's Freespace FAQ. It's almost like asking me yourself.

[ Diaspora ] - [ Seeds Of Rebellion ] - [ Mind Games ]

 

Offline Shade

  • 211
30 second fix, if that.
« Last Edit: May 07, 2006, 07:45:09 am by Shade »
Report FS_Open bugs with Mantis  |  Find the latest FS_Open builds Here  |  Interested in FRED? Check out the Wiki's FRED Portal | Diaspora: Website / Forums
"Oooooooooooooooooooooooooooooooooooooooh ****ing great. 2200 references to entry->index and no idea which is the one that ****ed up" - Karajorma
"We are all agreed that your theory is crazy. The question that divides us is whether it is crazy enough to have a chance of being correct." - Niels Bohr
<Cobra|> You play this mission too intelligently.

 

Offline karajorma

  • King Louie - Jungle VIP
  • Administrator
  • 214
    • Karajorma's Freespace FAQ
Figured as much :)
Karajorma's Freespace FAQ. It's almost like asking me yourself.

[ Diaspora ] - [ Seeds Of Rebellion ] - [ Mind Games ]

 

Offline Shade

  • 211
More like 27 seconds, not counting the time spent getting the syntax right because I was being dumb :p And no testing done yet (as I'm watching an F1 grand prix at the moment), so as yet it only works in theory. In mission_campaign_end_do, change the movie playing code to this:

if(Supernova_status == SUPERNOVA_HIT)
{
   // no soup for you!
   if (!movie_play_two("endpart1.mve", "endprt2b.mve"))
      movie_play("endpart2b.mve");         // good ending
   
} else {
   // no soup for you!
   if (!movie_play_two("endpart1.mve", "endprt2a.mve"))
      movie_play("endpart2a.mve");         // good ending
}

Result should be that if the first attempt at playing the movies returns false (ie. if one of the files wasn't found), it tries the alternative for the second movie. Oh, and it saying good ending twice in the original comments might warrant a change too...
« Last Edit: May 07, 2006, 08:00:44 am by Shade »
Report FS_Open bugs with Mantis  |  Find the latest FS_Open builds Here  |  Interested in FRED? Check out the Wiki's FRED Portal | Diaspora: Website / Forums
"Oooooooooooooooooooooooooooooooooooooooh ****ing great. 2200 references to entry->index and no idea which is the one that ****ed up" - Karajorma
"We are all agreed that your theory is crazy. The question that divides us is whether it is crazy enough to have a chance of being correct." - Niels Bohr
<Cobra|> You play this mission too intelligently.

 

Offline Starman01

  • 213
  • Mechwarrior
    • Wing Commander Saga
What about the supernova-thing ? Is it still necessary (in the current version) to activate that in the mission so the endmovie will be played ?
MECHCOMMANDER OMNITECH

9 out of 10 voices in my head always tell me that I'm not insane. The 10th is only humming the melody of TETRIS.

 

Offline Shade

  • 211
Supernova is required at the moment, but soon that won't matter :D Regarding my idea for letting campaigns play a set end movie, I scrapped it. Instead, I'm working on something Rather Bettertm. Basically, I'm making it so you can use mission events to set a movie or movies to be played between mission end and the debriefing. So you will be able to play specific movies based on specific events that occur during a mission if you so desire, or even just play some generic "carrier landing" movie for missions that end that way.

I have about half of the code done at the moment, well, in fact all of the actual movie playing code is pretty much done, I "just" need to add the proper SEXPs (something like add_movie and clear_movies would do I think) and then make sure it doesn't break anything or do something stupid like play even in the event of death or forfeit.

Anyways, no ETA on it, mainly since I'm unsure about what it might break and I want to be damn sure it's safe before it gets anywhere near CVS, but it'll get done eventually. Just wanted to let you know :)
Report FS_Open bugs with Mantis  |  Find the latest FS_Open builds Here  |  Interested in FRED? Check out the Wiki's FRED Portal | Diaspora: Website / Forums
"Oooooooooooooooooooooooooooooooooooooooh ****ing great. 2200 references to entry->index and no idea which is the one that ****ed up" - Karajorma
"We are all agreed that your theory is crazy. The question that divides us is whether it is crazy enough to have a chance of being correct." - Niels Bohr
<Cobra|> You play this mission too intelligently.

 

Offline Starman01

  • 213
  • Mechwarrior
    • Wing Commander Saga
I'm really glad you are working on that (certainly all will benefit from that). However, there is no need to hurry, since our prologue isn't compatible with the new exe's (yet) and I wont change it if it isn't absolutly necessary (like when the fiction viewer will be done, this would currently be the only vital change which would make me do all the work for making it compatible again :) ) Until then, we stay with the original 3.6.7 which works good.
MECHCOMMANDER OMNITECH

9 out of 10 voices in my head always tell me that I'm not insane. The 10th is only humming the melody of TETRIS.

 

Offline Shade

  • 211
No problem, never did understand why you had to be limited to playing movies between missions. Besides, it's not that much new code, it's just calling the existing movie code in new and interesting ways and finding the right place to do it in :p

[edit] If there's something else you'd like to be able to do with movies (though I think this should cover all the bases, got pre-debrief with my additions and post-debrief already available from the campaign editor), this would probably be the time to say so while I'm still finishing this up.
« Last Edit: May 13, 2006, 01:08:31 pm by Shade »
Report FS_Open bugs with Mantis  |  Find the latest FS_Open builds Here  |  Interested in FRED? Check out the Wiki's FRED Portal | Diaspora: Website / Forums
"Oooooooooooooooooooooooooooooooooooooooh ****ing great. 2200 references to entry->index and no idea which is the one that ****ed up" - Karajorma
"We are all agreed that your theory is crazy. The question that divides us is whether it is crazy enough to have a chance of being correct." - Niels Bohr
<Cobra|> You play this mission too intelligently.

 

Offline Starman01

  • 213
  • Mechwarrior
    • Wing Commander Saga
Well, to get back to my earlier question, how can I get the outro to run then in the old build ? I tried making a mini-campaign with just the last mission. In the campaign-file it has a "end campaign" flag/sexp.

At the end in the mission, in the same SEXP that has the "end mission" operator I start the supernova with a timer of 100 (though the player will not even notice that, since the mission ends in the same second (maybe that's a problem ? )

The outro file is called "endpart1.avi", and the campaign file is called "freespace2.fc2".

What am I missing ?
MECHCOMMANDER OMNITECH

9 out of 10 voices in my head always tell me that I'm not insane. The 10th is only humming the melody of TETRIS.