Source Code Project Mantis - FSSCP
View Issue Details
0002478FSSCPcutscenespublic2011-08-01 14:402012-07-01 21:06
Reporterjon118 
Assigned ToGoober5000 
PrioritynormalSeverityminorReproducibilityalways
StatusresolvedResolutionfixed 
PlatformMacbook Pro (7,1)OSMac OS X "Snow Leopard"OS Version10.6.8
Product Version3.6.13 
Target Version3.6.14Fixed in Version3.6.14 
Summary0002478: "No Debriefing for mission: SM3-10.fs2" screen and ending cutscenes will not play if player reaches jump node successfully
DescriptionThis has been reported before by other users on Mantis, but was closed due to lack of a complete bug report and log file.

So here is a complete thorough report of the problem as I reported on the support thread here:
http://www.hard-light.net/forums/index.php?topic=76521.0



Here is a thorough and exhaustive description of the problem:

See attachments for the saves (pilot files, before AND after the end mission), and "fs2_open.log", and screenshot.

Here are the details of what I'm running:

- Build 3.6.13 - nightly build FS2_Open-Inferno (debug)-20110728_r7384
- System: Macbook Pro (7,1) - Intel Core 2 Duo - 2.4 GHz - 4 GB RAM
- Graphics System: NVIDIA GeForce 320M - 256MB VRAM
- OS: Mac OS X "Snow Leopard" 10.6.8


---



Effects of bug:

0000001 - Causes a "No Debriefing for mission: SM3-10.fs2" screen to be displayed.

0000002 - Causes the ending movies "End Game" and "End Game Part 2a" not to play or be added to the Cutscenes list in the Tech Room--making the end of the game very unsatisfying to the player.

---

Please let me know if there is anything else I can do to be of help.

The only part of the log file that seems to be relevant is the very end. So to just make things even more convenient, here is that part:


Logfile after "winning" the last mission and successfully making it to the node and the movies not playing:

... ... ...

Frame 29128: Could not create debris, no more slots left
Frame 29128: Could not create debris, no more slots left
Frame 29128: Could not create debris, no more slots left
ANI Head-TP3b.ani with size 160x120 (6.2% wasted)
ANI Head-CM5c.ani with size 160x120 (6.2% wasted)
Frame 31786 too long!!: frametime = 0.372 (0.372)
ANI Head-TP1b.ani with size 160x120 (6.2% wasted)
Frame 32570 too long!!: frametime = 0.372 (0.372)
Frame 33066 too long!!: frametime = 0.406 (0.406)
Got event GS_EVENT_PLAYER_WARPOUT_START (41) in state GS_STATE_GAME_PLAY (2)
Got event GS_EVENT_PLAYER_WARPOUT_DONE_STAGE1 (44) in state GS_STATE_GAME_PLAY (2)
Hit target speed. Starting warp effect and moving to stage 2!
Got event GS_EVENT_PLAYER_WARPOUT_DONE_STAGE2 (45) in state GS_STATE_GAME_PLAY (2)
Hit warp effect. Moving to stage 3!
Got event GS_EVENT_PLAYER_WARPOUT_DONE (46) in state GS_STATE_GAME_PLAY (2)
Player warped out. Going to debriefing!
Got event GS_EVENT_DEBRIEF (33) in state GS_STATE_GAME_PLAY (2)
Unloading in mission messages
Storing stats now
Frame 33628 too long!!: frametime = 0.332 (0.332)
Frame 33628 too long!!: frametime = 0.269 (0.269)
Got event GS_EVENT_MAIN_MENU (0) in state GS_STATE_DEBRIEF (27)
Got event GS_EVENT_QUIT_GAME (5) in state GS_STATE_MAIN_MENU (1)
Freeing all existing models...
... Log closed, Mon Aug 01 08:30:45 2011





Also, here is the important part of the logfile after "losing" the last mission and NOT making it to the jump node, and the ending movie playing (and no "No Debriefing for mission: SM3-10.fs2" screen being displayed):

... ... ...

Frame 27556: Could not create debris, no more slots left
Frame 27556: Could not create debris, no more slots left
Frame 27556: Could not create debris, no more slots left
Beam couldn't find a good object model/type!! (0)
Beam couldn't find a good object model/type!! (0)
Beam couldn't find a good object model/type!! (0)
Beam couldn't find a good object model/type!! (0)
Killing beam at initial fire because of illegal targeting!!!
ANI Head-TP3a.ani with size 160x120 (6.2% wasted)
ANI Head-CM2a.ani with size 160x120 (6.2% wasted)
ANI Head-CM5b.ani with size 160x120 (6.2% wasted)
Frame 30225 too long!!: frametime = 0.373 (0.373)
ANI Head-CM2c.ani with size 160x120 (6.2% wasted)
Frame 30904 too long!!: frametime = 0.387 (0.387)
ANI Head-VP1a.ani with size 160x120 (6.2% wasted)
Got event GS_EVENT_END_CAMPAIGN (59) in state GS_STATE_GAME_PLAY (2)
Unloading in mission messages
Storing stats now
MVE: Buffer underun (First is normal)
MVE: Buffer underun (First is normal)
Got event GS_EVENT_MAIN_MENU (0) in state GS_STATE_END_OF_CAMPAIGN (45)
SOUND: /Users/cliffgordon/fs2open_0/projects/Xcode/../../code/sound/ds.cpp:698 - OpenAL error = 'Invalid Name'
Frame 32510 too long!!: frametime = 225.258 (225.258)
Got event GS_EVENT_QUIT_GAME (5) in state GS_STATE_MAIN_MENU (1)
Freeing all existing models...
... Log closed, Mon Aug 01 09:59:02 2011

Steps To ReproduceProcedure to reproduce problem:

As far as I can tell, just play through the game to the end (or load my "before" pilot) and successfully get to the node, using the 3.6.13 build on a Mac. (I don't think you need my specific OS version, graphics chip, or nightly build to reproduce).

If you make it to the jump node, then a debriefing screen will display showing "No Debriefing for mission: SM3-10.fs2" and right above that in the debug build: "[name: SM3-10.fs2, mod: 08/18/09 at 13:30:00]" and the ending movies ("end game", "end game part 2a") will NOT play, and the movies will NOT be added to the list of cutscenes playable in the Tech Room.

However,

If you DON'T successfully make it to the jump node, then the end movie, and pilot death movie ("end game", "end game part 2b"), WILL both play and be added to the playable cutscenes (though the "end game part2a" cutscene will still NOT be played or added, or course).
Tagscutscene, Mac, SM3-10.fs2
related to 0002482closed Goober5000 After you complete sm3-10.fs2 the campaign does not "end" 
Attached Fileszip Saves.zip (96,209) 2011-08-01 14:40
http://scp.indiegames.us/mantis/file_download.php?file_id=1670&type=bug
png No-Ending-Debriefing.png (201,630) 2011-08-01 14:42
http://scp.indiegames.us/mantis/file_download.php?file_id=1671&type=bug
png

log Antipodes_8_fs2_open.log (67,779) 2011-08-04 11:25
http://scp.indiegames.us/mantis/file_download.php?file_id=1672&type=bug

Notes
(0012751)
jon118   
2011-08-01 14:46   
Please ignore the "0000001" and "0000002" links under the section "Effects of bug" above. They were automatically added by mantis erroneously because I numbered the bug effects with a number symbol.
(0012752)
jon118   
2011-08-01 14:48   
Also, look inside the "Saves.zip" for the complete logfiles.
(0012753)
jon118   
2011-08-01 15:05   
Also, I just noticed Mantis didn't include the steps to reproduce the bug that I gave it. So here it is again:


Procedure to reproduce problem:

As far as I can tell, just play through the game to the end (or load my "before" pilot) and successfully get to the node, using the 3.6.13 build on a Mac. (I don't think you need my specific OS version, graphics chip, or nightly build to reproduce).

If you make it to the jump node, then a debriefing screen will display showing "No Debriefing for mission: SM3-10.fs2" and right above that in the debug build: "[name: SM3-10.fs2, mod: 08/18/09 at 13:30:00]" and the ending movies ("end game", "end game part 2a") will NOT play, and the movies will NOT be added to the list of cutscenes playable in the Tech Room.

However,

If you DON'T successfully make it to the jump node, then the end movie, and pilot death movie ("end game", "end game part 2b"), WILL both play and be added to the playable cutscenes (though the "end game part2a" cutscene will still NOT be played or added of course).
(0012754)
The_E   
2011-08-02 08:29   
Does the same thing happen with an Antipodes 8 build?
(0012755)
jon118   
2011-08-03 16:41   
I'm working on testing that right now. I'll let you know in a few days.
(0012756)
jon118   
2011-08-04 12:06   
The same thing happens with Antipodes 8 if I use my saved pilot (from 3.6.13 at the final mission). But that also happens with 3.6.12 also (if I use my saved pilot from 3.6.13). So I don't think that test is very helpful until I can play from the beginning using a new pilot.

With Antipodes 8 I wasn't able to start from a new game and play to the end, due to it making my Sidewinder Joystick go nuts (ship continuously rotates to the right uncontrollably in Antipodes 8, but not in regular 3.6.13 builds--but that's another issue). So I used my saved pilot from the regular build and played the last mission with the keyboard.

But because the saved pilot from 3.6.13 seems to ALWAYS trigger the bug, regardless of the build used, it appears something may be corrupting the pilot file at some other point in the game.

Once I can actually play Antipodes 8, I'll try playing through to the end. But for now, it's simply unplayable for me due to the aforementioned joystick calibration problem.

I'll have to play through 3.6.12 again to be sure, but I believe the bug did NOT happen when using a clean install of 3.6.12 and starting from a new pilot.

In case it's helpful, I uploaded a logfile from Antipodes 8 above (using my saved pilot from 3.6.13). Though it doesn't appear to show anything different than the 3.6.13 logfile.


It seems to me that it should be at least a little easier to figure out what's causing this, considering that my saved pilot always causes the bug in a 100% repeatable and predictable manner, regardless of build (hopefully?).
(0012757)
jon118   
2011-08-04 12:10   
And just to be clear:

Playing through to the end on the 3.6.13 builds ALWAYS causes this bug for me (at least in the Mac version).

I've played through twice, using a clean install of everything, and a new pilot each time.

100% repeatable on my end.
(0012759)
The_E   
2011-08-04 12:42   
Well, this sounds more and more like pilot file corruption. Which is something Antipodes 8 fixes; however if you import an old pilot file (a process that _isn't guaranteed to work_), corruption may import over as well.

My question was more "Can you recreate this bug using a completely new pilot file with AP8?". Sorry for not being clear.

In the end, this is pretty much pointless. Noone will really look at pilot file issues with the old pilot files, because there's a replacement already on the horizon. the best option, if you encounter it, is to create a new pilot, as onerous as that may sound.
(0013201)
jon118   
2012-01-30 15:52   
Just for completeness sake, here is the solution to this bug (though I'm sure everyone is aware of this by now):


Re-Adding the following code to the "case GS_EVENT_DEBRIEF" section of "freespace.cpp" fixes the bug completely:

   if (Campaign_ended_in_mission && (Game_mode & GM_CAMPAIGN_MODE) /*&& !stricmp(Campaign.filename, "freespace2")*/)
      {
         gameseq_post_event(GS_EVENT_END_CAMPAIGN);
      }
   else
      {
         gameseq_set_state(GS_STATE_DEBRIEF);
      }


Problem is unrelated to pilot file corruption, and is caused by the lack of logic leading to a "GS_EVENT_END_CAMPAIGN" state when the player warps-out while in the jump node in the last mission.

Re-adding the above code fixes the bug. Though a more elegant code solution may be preferable.
(0013202)
jon118   
2012-01-30 18:26   
Also, I have confirmed that this bug is still present in 3.6.14 RC4 and Antipodes.
(0013206)
Goober5000   
2012-01-31 00:42   
How did I miss this ticket? Thanks for the thorough testing. Can you compare it with retail as detailed in the other ticket?
(0013209)
jon118   
2012-01-31 11:20   
(Last edited: 2012-02-04 15:53)
No problem.

This bug did *not* happen in retail (or in any FSO branch before 3.6.12), as the below code was still present up until, and including, FSO branch 3.6.10--in 3.6.12 it was mistakenly commented out (in 3.6.13, the comments themselves were completely removed; so please see the "freespace.cpp" of the 3.6.12 branch for the code I'm referring to).

So, just to be crystal clear:

If you go to the "case GS_EVENT_DEBRIEF" section of "freespace.cpp" in the 3.6.12 branch and copy the commented-out code (see below), and then paste it into the same place in the "freespace.cpp" of the 3.6.14 RC4 branch (and un-comment it), then it will fix the bug and return the behavior of the final cutscene to the *original retail* behavior (in other words, the cutscene will work again. Right now it *never* plays under any circumstance, since the logic doesn't exist to make it play).


In the "freespace.cpp" of branch 3.6.12 it says this:





        case GS_EVENT_DEBRIEF:
            // This IF block isn't needed because it's not part of the end-campaign logic.
            // The supernova code and end-campaign sexp handle it all. - G5K
            //
            // // did we end the campaign in the middle of a mission?
            // if (Campaign_ended_in_mission && (Game_mode & GM_CAMPAIGN_MODE) /*&& !stricmp(Campaign.filename, "freespace2")*/) {
            // gameseq_post_event(GS_EVENT_END_CAMPAIGN);
            // } else {
            // gameseq_set_state(GS_STATE_DEBRIEF);
            // }
            //
            gameseq_set_state(GS_STATE_DEBRIEF);

            //Player_multi_died_check = -1;
            break;





So, in the 3.6.14 branch, it needs to be changed from this:





        case GS_EVENT_DEBRIEF:

             gameseq_set_state(GS_STATE_DEBRIEF);
             break;






To this: (or to something similar/better/less-hacky, if you want):





        case GS_EVENT_DEBRIEF:

            // This IF block isn't needed because it's not part of the end-campaign logic.
            // The supernova code and end-campaign sexp handle it all. - G5K

            // Edit: Woops! Actually this IF block *IS* needed in order for the final cutscene
            // to play properly, and is a vital part of the final campaign logic--though a
            // bit of a hack that has been present from the original Volition code,
            // and that could probably use some improving.


                // Did we end the campaign in the middle of a mission? Play final "victory" cutscene.
                if (Campaign_ended_in_mission && (Game_mode & GM_CAMPAIGN_MODE) /*&& !stricmp(Campaign.filename, "freespace2")*/) {
                    gameseq_post_event(GS_EVENT_END_CAMPAIGN);
                } else {
                    gameseq_set_state(GS_STATE_DEBRIEF);
                }

            break;







Thanks for looking into this Goober!

(0013223)
jon118   
2012-02-01 10:42   
(Last edited: 2012-02-01 11:17)
One additional note regarding this bug's (2478) relationship to Mantis issue 2482:

Once this bug (2478) is fixed and the cutscenes once again work like retail and *do* play for both the "good" and "bad" ending, it then causes the campaign to not be ended (just like in retail), as there is no "GS_STATE_DEBRIEF" after the cutscene finishes playing. Which then leads to the minor "bug" mentioned in 0002482

However, if the player did *not* get to the node before the supernova, and dies, and gets the "bad" ending, they may not *want* to have the campaign end and have to start over! As they probably would want to be able to play the end again and actually get to the node in time! This may be why the Volition developers left the campaign un-ended. Though that's something to be addressed in the 2482 Mantis issue.

(0013575)
Goober5000   
2012-05-20 15:23   
Okay, finally got back to looking at this. As it turns out, the code follows two different paths depending on how you leave the mission, which is what was confusing me. If you die, it goes through the normal supernova screen which worked as you would expect. But if you jump out successfully, it goes to the debriefing screen, which is where I erroneously removed code. I'm now putting the code back in.
(0013576)
Goober5000   
2012-05-20 15:25   
Marking as fixed. Thanks to jon118 and Yarn for their detective work.

Issue History
2011-08-01 14:40jon118New Issue
2011-08-01 14:40jon118File Added: Saves.zip
2011-08-01 14:42jon118Tag Attached: cutscene
2011-08-01 14:42jon118Tag Attached: Mac
2011-08-01 14:42jon118Tag Attached: SM3-10.fs2
2011-08-01 14:42jon118File Added: No-Ending-Debriefing.png
2011-08-01 14:46jon118Note Added: 0012751
2011-08-01 14:48jon118Note Added: 0012752
2011-08-01 15:05jon118Note Added: 0012753
2011-08-02 08:29The_ENote Added: 0012754
2011-08-03 16:41jon118Note Added: 0012755
2011-08-04 11:25jon118File Added: Antipodes_8_fs2_open.log
2011-08-04 12:06jon118Note Added: 0012756
2011-08-04 12:10jon118Note Added: 0012757
2011-08-04 12:42The_ENote Added: 0012759
2011-08-04 12:43The_EStatusnew => closed
2011-08-04 12:43The_EResolutionopen => won't fix
2011-10-30 03:58Goober5000Relationship addedrelated to 0002482
2012-01-30 15:52jon118Note Added: 0013201
2012-01-30 15:52jon118Statusclosed => feedback
2012-01-30 15:52jon118Resolutionwon't fix => reopened
2012-01-30 18:26jon118Note Added: 0013202
2012-01-30 18:26jon118Statusfeedback => new
2012-01-31 00:42Goober5000Note Added: 0013206
2012-01-31 00:42Goober5000Assigned To => Goober5000
2012-01-31 00:42Goober5000Statusnew => acknowledged
2012-01-31 00:42Goober5000Description Updatedbug_revision_view_page.php?rev_id=23#r23
2012-01-31 11:20jon118Note Added: 0013209
2012-01-31 11:34jon118Note Edited: 0013209bug_revision_view_page.php?bugnote_id=13209#r25
2012-01-31 11:36jon118Note Edited: 0013209bug_revision_view_page.php?bugnote_id=13209#r26
2012-02-01 10:42jon118Note Added: 0013223
2012-02-01 10:47jon118Note Edited: 0013223bug_revision_view_page.php?bugnote_id=13223#r36
2012-02-01 11:17jon118Note Edited: 0013223bug_revision_view_page.php?bugnote_id=13223#r47
2012-02-04 15:53jon118Note Edited: 0013209bug_revision_view_page.php?bugnote_id=13209#r54
2012-05-20 15:23Goober5000Note Added: 0013575
2012-05-20 15:23Goober5000Changeset attached => fs2open trunk r8806
2012-05-20 15:25Goober5000Note Added: 0013576
2012-05-20 15:25Goober5000Statusacknowledged => resolved
2012-05-20 15:25Goober5000Resolutionreopened => fixed
2012-05-20 15:25Goober5000Fixed in Version => 3.6.14
2012-05-20 15:55Goober5000Target Version => 3.6.14
2012-07-01 21:06ZacamChangeset attached => fs2open fs2_open_3_6_14 r8942