Opened 6 years ago

Closed 6 years ago

Last modified 6 years ago

#10493 closed defect (fixed)

TITANIC: Game crash when choosing floor in elevator

Reported by: Noone78 Owned by: dreammaster
Priority: high Component: Engine: Titanic
Version: Keywords: Game Crash
Cc: Game: Starship Titanic

Description

Typing in any floor number while in the elevator causes the game to crash.
I am sorry I cannot give you any more details.

Change History (17)

comment:1 by Noone78, 6 years ago

Game is from Steam using PC

comment:2 by dreammaster, 6 years ago

Component: --Unset--Engine: Titanic

I've had a similar report previously, but wasn't able to replicate the problem. What I'd request is two things to look into this problem properly:
1) A savegame from inside the lift, just in case something from your game state is at blame
2) Instructions on how you generate the error, down to each individual mouse press and keypress. Since I had trouble previously replicating the problem, even the most minor details of how the error happens may be relevant. Maybe even consider doing a quick screen capture, if you have any software for recording the screen.

Thanks.

comment:3 by dreammaster, 6 years ago

Summary: (scummvm -v - game crash when choosing floor in elevator)TITANIC: Game crash when choosing floor in elevator

comment:4 by dafioram, 6 years ago

Its also possible the datafiles that steam uses are corrupted/missing files. A full list of files and md5s would probably be useful in this case.

comment:5 by dreammaster, 6 years ago

Agreed

comment:6 by Noone78, 6 years ago

Apologises for being a simpleton, but how would one pass on a "save game file"?

comment:7 by dafioram, 6 years ago

When you save in starship titanic using the in-game save menu or the general menu (ctrl+F5) it creates titanic-win.XXX files that contain these saves.

If you attach the one that is right before the bug to this ticket we can load it from our game.

You can set the save path manually if the ScummVM gui application is included with the steam release, if not their might be a scummvm.ini config file with the save location specified (savepath=). Otherwise the saved game location defaults to C:\Users\[user name]\AppData\Roaming\ScummVM\Saved games on windows.

The default config file location is in C:\Users\[user name]\AppData\Roaming\ScummVM\scummvm.ini.

Does your starship titanic assets folder contain 464 files? Also is your newgame.st file 85.1 KB?

comment:9 by dafioram, 6 years ago

You have to upload that save file using the attach file option that is apart of this ticket.

comment:10 by dafioram, 6 years ago

I was able to load your saved game fine and take the elevator to floor 24 (the floor you had typed in), as well as travel to a few different floors by typing in the level number.

I think it may be an issues with the files included in the steam release. Can you first check to see how many files are in the common/Starship Titanic/Assests/ folder?

comment:11 by dreammaster, 6 years ago

Owner: set to dreammaster
Resolution: worksforme
Status: newclosed

I went ahead and bought the Steam release, and was able to replicate the problem using their executable. After some experimentation, I think it may be a random crash due to uninitialized memory in the image/video decoders, which have already been fixed. Doing some memory tracing under Linux, I confirmed that the 2.0.0 release that Steam uses has a lot of them, but they're all gone from the current codebase due to the recent work done to resolve them. Which I'm hopeful will solve the problem on Windows. Though unfortunately I can't tell for sure.. even rolling back to compile 2.0.0, I still couldn't replicate a crash with the executable I compiled myself, so it does raise the likelihood that the error has been resolved.

Anyway, I'm going to mark this as resolved for ScummVM; if anyone can replicate the problem with the latest codebase, we can always reopen it later. As far as the executable compiled for Steam goes, I was able to prevent the crash by saying "floor 24" instead of just "24". Or, of course, you can use the icons in the PET Remote Thingummy tab.

Last edited 6 years ago by dreammaster (previous) (diff)

comment:12 by dreammaster, 6 years ago

Status: closedpending

comment:13 by dafioram, 6 years ago

Resolution: worksforme
Status: pendingnew

The bug that Noone78 is experiencing can be reproduced in the current version (ab3f397e2d3f) by building in release (tested on linux).

It has to do with the text parsing part of the code.

#0  0x000055555577b398 in Titanic::TTconcept::findByWordClass(Titanic::WordClass) ()
#1  0x000055555577fe7c in Titanic::TTparser::considerRequests(Titanic::TTword*) ()
#2  0x000055555578046a in Titanic::TTparser::checkForAction() ()
#3  0x0000555555780ad0 in Titanic::TTparser::findFrames(Titanic::TTsentence*) ()
#4  0x0000555555778611 in Titanic::CScriptHandler::processInput(Titanic::TTroomScript*, Titanic::TTnpcScript*, Titanic::TTstring const&()
#5  0x0000555555736a64 in Titanic::CTrueTalkManager::processInput(Titanic::CTrueTalkNPC*, Titanic::CTextInputMsg*, Titanic::CViewItem*)()
#6  0x00005555556ed2ba in Titanic::CLiftBot::TextInputMsg(Titanic::CTextInputMsg*) ()
#7  0x00005555556dedc9 in Titanic::CMessage::execute(Titanic::CTreeItem*, Titanic::ClassDef const*, int) [clone .part.0] ()
#8  0x00005555556fbbd8 in Titanic::CPetConversations::textLineEntered(Titanic::CString const&) [clone .part.11] ()
#9  0x00005555556fbd5b in Titanic::CPetConversations::handleKey(Common::KeyState const&) [clone .part.12] ()
#10 0x00005555556fbda0 in Titanic::CPetConversations::KeyCharMsg(Titanic::CKeyCharMsg*) ()
#11 0x00005555556f6e83 in Titanic::CPetControl::KeyCharMsg(Titanic::CKeyCharMsg*) ()
#12 0x00005555556dedc9 in Titanic::CMessage::execute(Titanic::CTreeItem*, Titanic::ClassDef const*, int) [clone .part.0] ()
#13 0x00005555557439a2 in Titanic::CInputHandler::dispatchMessage(Titanic::CMessage*) ()
#14 0x0000555555743b63 in Titanic::CInputHandler::processMessage(Titanic::CMessage*) ()
#15 0x0000555555744488 in Titanic::CInputTranslator::keyDown(Common::KeyState const&) ()
#16 0x00005555557448b1 in Titanic::CMainGameWindow::keyDown(Common::KeyState) ()
#17 0x0000555555740d5f in Titanic::Events::pollEvents() ()
#18 0x0000555555740f9d in Titanic::Events::pollEventsAndWait() ()
#19 0x000055555565c8cc in Titanic::TitanicEngine::run() ()
#20 0x000055555564ba68 in scummvm_main ()
#21 0x0000555555645a5b in main ()

comment:14 by dreammaster, 6 years ago

Resolution: fixed
Status: newpending

I haven't been able to replicate the crash in Visual Studio even in Release mode. However, the cause is more than likely, thanks to the handy backtrace you provided, due to the method being called when this is null. I've added in an extra check on the calling line in TTParser to guard against it's _conceptP being null. Could you try compiling with the latest master on Linux again and see if the crash is resolved? Thanks.

comment:15 by dafioram, 6 years ago

Status: pendingclosed

Fixed by dreammaster in commit db1c506ee53e2fe1.

comment:16 by dafioram, 6 years ago

This crash was not just limited to riding the lift, but also when talking to the parrot and the deskbot and saying "24".

Note: See TracTickets for help on using tickets.