the-butterfly-effect / tbe

The Butterfly Effect, a realistic physics simulation game
http://the-butterfly-effect.org
GNU General Public License v2.0
96 stars 13 forks source link

TBE crashes immediately after launching #316

Closed Wuzzy2 closed 4 years ago

Wuzzy2 commented 7 years ago

When I try to start a freshly cloned TBE (dcab20e67aacb28172173dfc098fcbb4552bc4bf), it just manages to pop up the main window (no level renders), but quickly crashes afterwards.

[wuzzy@W5 tbe]$ LANG=en ./tbe 

(process:8412): Gtk-WARNING **: Locale not supported by C library.
    Using the fallback 'C' locale.
**** t=986: entry bool Singleton::Translator::init() (0x7f3780)
 **** t=986: going to set locale 'en_US'
***  t=986: Singleton::Translator::setLanguage for locale 'en_US'
**** t=986: setting en_US means removing all existing translators, done.
**   t=986: SUMMARY:
**   t=986:   Verbosity is: 4 / Fullscreen is 1
**   t=986:   Start file name is: ''
**   t=986:   using settings from: '/home/wuzzy/.config/the-butterfly-effect.org/The Butterfly Effect.conf'
**** t=986: entry UndoSingleton::UndoSingleton() (0x20c5820)
*    t=986: GameControls-GameState StoppedState onEntry!
**** t=986: entry void GameQControls::slot_updateIcon(GameStateMachine::States) (0x1fdcc80)
**** t=987: entry void MainWindow::loadLevelDelayed() (0x7fffca11a860)
**** t=987: entry void MainWindow::loadLevel(const QString&) (0x7fffca11a860)
***  t=987: Level::load("/home/wuzzy/src/tbe/tbe/usr/games/../share/games/tbe/levels/finished/sorting-1.xml")
*    t=987: createTBGFromDom for 'Floor' successful
*    t=987: createObjectFromDom for background successful
tbe: /home/wuzzy/src/tbe/tbe/src/view/ViewWorldItem.cpp:163:         ViewWorldItem::ViewWorldItem(QQuickItem*): Assertion `nullptr == theVWIPtr' failed.
Abgebrochen (Speicherabzug geschrieben)
[wuzzy@W5 tbe]$ 
kaa-ching commented 7 years ago

Yes, you're not the only one suffering from this. I've seen something similar on my desktop when I compile against Qt 5.8. It doesn't happen on my laptop with Qt 5.5 or 5.6.

In the end, this all boils down to initialization order. I've been restructuring the flow inside MainWindow and GameFlow a little, but I'll have to complete the work to make this issue go away.

Unfortunately, I don't have a lot of spare time lately...

kaa-ching commented 7 years ago

Just trying a little: Would this help? delay-loading-a-little.zip

Wuzzy2 commented 4 years ago

No longer reproducible, both in old UI and new UI. And this is a very old bug. I close this now.