Post

It adds the two together, so `xpos position(1.0, -10)` positions the item at 100% of the available space, -10 (e.g. if the available space was 1920, this would put the xpos at 1920-10 = 1910). Extremely useful for offsetting positions or sizes a bit from the edge or center without using `offset`.

Does it bother you that the Window button in the default preferences screen is never highlighted, even when the game is not fullscreen? This is a quirk of how that button action checks if it's selected - technically, it's only highlighted if the window is exactly the game dimensions (e.g. 1920x1080)

Set `config.debug_text_overflow = True` to get a text_overflow.txt file which will report any text that's too large for its container. If you speed through your game using the previous tip, this logs where your dialogue is overflowing the textbox (useful if you support multiple fonts or text sizes)

What this means is you can check for `if config.developer:` and be confident that whatever is in that block will not appear in the release build. I use it all the time for developer menus, to print optional information during the game while testing, to flag errors, and more.

0 reposts7 likes