ToME: the Tales of Maj'Eyal

ToME 2.x running on Qt
Page 1 of 1

Author:  AnonymousHero [ Tue Dec 17, 2013 7:41 pm ]
Post subject:  ToME 2.x running on Qt

OK, so after a weekend of hacking, here's a screenshot of ToME 2.x running on top of Qt 5.x. Many things don't really work yet:
  • keyboard input is sketchy; no arrow keys yet (which means it's not really playable, so I think this is probably highest priority)
  • no colors yet, but that should be pretty trivial to get working
  • the intro animation goes by way too fast, so you don't actually really notice it. I think this is due to the way the game engine just blasts updates at the front-end without really waiting properly for the updates to show. It's not really a big deal for now, but it could mean that the in-game animated projectiles don't work properly (don't know yet as I can't actually play without arrow keys!)
  • almost all of the code is one giant hack

I don't see any of the above as huge obstactles, just things that will take a little time.

What is working very satisfactorily and which wasn't in previous attempts at new GUI ports (SDL 2.x, SFML, Allegro) is speed. A really dumb Qt Scene Graph with 80x24 QSimpleTextGraphicsItem instances seems to be performing really well with basically no optimization effort on my part, so that's a very positive sign.

I'm not sure yet, but I may end up having to remove all(!) other frontends and integrate this slightly closer with the game engine to get it working really well. I don't think it'll be any great loss since the Qt-based frontend should perform vastly better than the X11 front end and support multiple desktop windows (unlike the SDL one). And Qt is cross-platform and so should work perfectly on both Mac OS and Windows. (Compiling on Windows, I don't know about, but presumably people are managing to compile Qt Apps on Windows, so...) The only current frontend which cannot be replaced with a Qt-based one is the Curses one. I'm not sure anyone cares about that.

As usual I can't really put any deadlines on when this will be done, but watch this space...

snapshot1.png [ 35.11 KiB | Viewed 2649 times ]

Author:  AnonymousHero [ Tue Dec 17, 2013 8:02 pm ]
Post subject:  Re: ToME 2.x running on Qt

Oh, and as you can see the font is rendered pretty weirdly -- a symptom of me not really knowing my way around QFont. I just asked it to load "Terminus" and hardcoded some glyph heights/widths because I don't know how to query them from the font itself :).

Author:  AnonymousHero [ Tue Dec 17, 2013 8:21 pm ]
Post subject:  Re: ToME 2.x running on Qt

... and now a little more colourful! :)

snapshot2.png [ 17.02 KiB | Viewed 2636 times ]

Author:  AnonymousHero [ Tue Dec 17, 2013 8:30 pm ]
Post subject:  Re: ToME 2.x running on Qt

... and the intro animation now works properly.

Author:  AnonymousHero [ Mon Dec 23, 2013 9:45 pm ]
Post subject:  Re: ToME 2.x running on Qt

... and now Arrow keys are working properly! Took a while figure out the completely insane pref system, but I think I got it now...

Author:  Lord Estraven [ Tue Dec 24, 2013 6:59 pm ]
Post subject:  Re: ToME 2.x running on Qt

And in time for Christmas too! :mrgreen: Thanks for putting in the effort on this, the T2 code base was a Byzantine horror.

Author:  Yottle [ Wed Dec 25, 2013 4:17 am ]
Post subject:  Re: ToME 2.x running on Qt


Page 1 of 1 All times are UTC
Powered by phpBB® Forum Software © phpBB Group