Skip to content

Releases: itb-community/ITB-ModLoader

v2.1.1

10 Apr 23:17
Compare
Choose a tag to compare
  • Settings lua object is now also loaded when loading into a game in progress, not just when a new game is started
  • GameData, RegionData, and SquadData are now reloaded every time the game is saved
  • Dropdowns are no longer sticky, and can now be dismissed by clicking somewhere outside of them
  • Mod content button animation is now also played when exiting a game in progress
  • Added a setting to disable the error popup shown when mods fail to mount, init, or load
  • Version string now gets moved to stay visible when game window is resized

v2.1.0

09 Apr 19:24
Compare
Choose a tag to compare

Changes since 2.0.1:

  • UI

    • Fixed a bug with mouseExited not being called correctly for child UI elements
    • Fixed mouse up events being intercepted way too aggressively, causing multiple simultaneous UiRoot elements to not work. This also fixes the issue with sticky sliders in options menu.
    • Fixed a bug with tooltips showing up for UI elements below dropdowns
    • Scroll areas can now be scrolled by holding and moving the scroll thumb
    • Added a warning frame shown when a mod fails to mount, init, or load (since the error report printed in console often times has other text layered on top of it, making debugging difficult)
    • Tweaked tooltips to get mirrored only when they would otherwise move off-screen, instead of when moving cursor between halves of the screen.
    • Added UiBoxLayout -- automatically lays out children one after another
    • Added UiWrappedText -- wraps long text and correctly handles newlines (still WIP, doesn't handle font sizes correctly -- need a way to inspect individual glyph widths)
    • Added DecoCAlignedText -- centered text deco (has the same problem as UiWrappedText)
    • Added DecoCAlign -- pads until center of its widget, with settable offset
    • Added UiAnim -- a simple class abstracting UI animations
    • "Mod Content" button now matches the other main menu buttons more closely for some additional flair
    • Dropdowns are now prettier and scrollbar is less buggy
    • Scrollbars are now styled after the game's sliders (black background, white border and thumb)
  • API

    • Added modApi:deltaTime() -- returns the amount of milliseconds that passed since last frame
    • Added modApi:elapsedTime() -- returns the amount of milliseconds that passed since the game has been launched
    • Added preLoadGameHook and postLoadGameHook -- fired before/after game state is loaded (this includes turn reset)
    • Added saveGameHook -- fired whenever game state is saved
    • Added preStartGameHook and postStartGameHook -- fired right after exiting the hangar, before/after the GAME object is created.
    • Starting a new game now correctly creates GameData, RegionData and SquadData tables (they are present in save file, but for some reason are not set by the game)
    • Renamed old preMissionStartHook and missionStartHook to preMissionAvailableHook and missionAvailableHook respectively, since that's what they actually do (these hooks are fired when a mission becomes accessible on the island)
    • Added new missionStartHook, which fires when the mission actually starts (ie. when the player confirms mission selection, and loads into the board)
    • Added scheduleHook, which allows to schedule an argumentless function to be executed the specified number of milliseconds later (roughly, checked every frame). Sorted by the time offset, so hooks that logically are scheduled to happen "sooner" are executed first
    • [redseiko] Added a slightly more sophisticated way of logging messages, with timestamp and information about the caller, and 3 logging levels (none, console, console + file). Configurable via Mod Content.
  • Misc

    • Fixed missionEndHook being the only hook beginning with a capital letter (triggered)
    • Partially reorganized structure of the mod loader to be more sane and maintainable
    • Version of the mod loader is now displayed in the lower right corner in main menu, right above the game's version