Saturday, 17 December 2011

Let there be widgets

Filling the windows with some (inter-active) content was the next step. As you can see in the picture, the toolbar at the left now has two buttons. If you click at the right one, the window at the right is opened (a first version of the path building interface).

The sizes and positions of all widget elements are computed automatically, so if you change the text (eg use a different language than English) or if you use different arrow sprites, everything is moved around to fit the new sizes.

Note that the slightly shorter titlebar of the path build window is not a bug. The system thinks an 'X' close button is located there, but since there are no graphics for it yet, you cannot see it :)

Adding paths to the program would be a nice next step perhaps. I don't really like the 'build single path tile with each click' idea, so I am still pondering a better system, in particular for building in the air.


  1. I've been watching this closely every day. Development is coming along nicely, but I see developments been slowing over the last month; Maybe thats the natural law of coders having time to defragment their brains and building momentum prior to making big hurdles in implementation paradigms :)

    I've been working on IsoMatrix quite a bit, but am resisting showing any work until I have the world renderer working to some degree.

    Its great to watch FreeRCT come together; it brings about a competitiveness for me to further push forward with IsoMatrix design. :)

    Keep up the great work Alberth and team!

  2. The blog may be quiet, but the repo is alive and well with updates to the window/widget code :) Hopefully Alberth will get the chance to write about some more of his progress at some point soon...

  3. I am pushing the path build gui into being.
    However, interactively clicking buttons, and reacting on them is a new area, so I got a lot distracted by having to build new infra structure first.

    Also, the trigonometry of computing the position of the cursor didn't really co-operate, it took me the entire Christmas holiday to get the numbers right.

    I just pushed a first step, nothing fancy, and it has a lot of cases where it does not work always entirely as it should, but I can build a path :P

    Will post a new blog shortly.
    (BTW I hit the 10,000 lines source code today, no idea how I did that ;)

  4. It is really nice to see your project! It is amazing.

    About the windows, do you have implemented Z Order? It will be useful, and needed for GUI games!

  5. Thanks :)

    I did implement Z order, at two levels. At a high level, some windows will always stay under/above other windows (GetWindowZPriority in window.cpp, line 547). This is used to ensure the main world display always stays below all other windows.
    Several windows with the same priority are stacked in order of opening them ('newer' windows are above 'older' windows).

    For the few windows I have currently, this seems to work fine ;D