![]() |
#191 |
Prophet
Join Date: Dec 2009
Posts: 9,022
![]() |
Hunh, I wouldn't have expected that to be efficient. Interesting. Thanks for describing your approach, anyway. It's possible the Qt front-end for Pyrel would want to steal it.
![]() |
![]() |
![]() |
![]() |
#192 | |
NPPAngband Maintainer
Join Date: Dec 2008
Location: Stat Gain, Angband
Posts: 926
![]() |
Quote:
I was looking through the QT examples, and I found this: http://harmattan-dev.nokia.com/docs/...ine-rogue.html It appears to be just moving around an "@" with direction keys, in a roguelike settings. This code will probably be pretty useful to me soon. I should post my start to a QT port soon. I am focusing on developing a menubar and toolbars for the game. I haven't actually incorporated any angband code yet. My next step will be to get the port to load the edit files, and close them up on exit.
__________________
NPPAngband current home page: http://nppangband.bitshepherd.net/ Source code repository: https://github.com/nppangband/NPPAngband_QT Downloads: https://app.box.com/s/1x7k65ghsmc31usmj329pb8415n1ux57 Last edited by nppangband; December 28, 2013 at 04:49. |
|
![]() |
![]() |
![]() |
#193 | |
NPPAngband Maintainer
Join Date: Dec 2008
Location: Stat Gain, Angband
Posts: 926
![]() |
Quote:
It is amazing that can be done with just a couple lines of code in QT that takes hundreds or thousands of lines in the Angband "game engine".
__________________
NPPAngband current home page: http://nppangband.bitshepherd.net/ Source code repository: https://github.com/nppangband/NPPAngband_QT Downloads: https://app.box.com/s/1x7k65ghsmc31usmj329pb8415n1ux57 |
|
![]() |
![]() |
![]() |
#194 |
Prophet
Join Date: Dec 2009
Posts: 9,022
![]() |
If you need them, Pyrel has fairly optimized drawing routines that aren't specific to any given front-end library here. This handles issues like:
* Deciding which subset of the map to display (centering on @ but taking map boundaries into account) * Drawing text, including pairs of left/right-aligned items (e.g. for inventory display: item name on one side, weight on the other) * Mapping from pixel space to the map grid The qtPyrel subclass of that class has Qt-specific code for performing drawing operations. Note that window setup is handled by other files. |
![]() |
![]() |
![]() |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
Thread Tools | |
Display Modes | |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Tales of Maj'Eyal 1.0.0RC1 aka "The Mathematics of Tears" | DarkGod | ToME | 17 | December 20, 2012 22:31 |