You are viewing a potentially older version of this package. View all versions.
CaptainOfCoit-HookUI-0.3.2 icon

HookUI

Allows mod authors to inject their own UI into the existing CS2 game UI

Date uploaded a year ago
Version 0.3.2
Download link CaptainOfCoit-HookUI-0.3.2.zip
Downloads 4957
Dependency string CaptainOfCoit-HookUI-0.3.2

This mod requires the following mods to function

BepInEx-BepInExPack-5.4.2100 icon
BepInEx-BepInExPack

BepInEx pack for Mono Unity games. Preconfigured and ready to use.

Preferred version: 5.4.2100

README

HookUI

Library and framework for mod authors to easily add their own mod UI, well integrated into the existing Game UI.

Screenshot

HookUI is some sort of UI framework/loader for Cities: Skylines 2 (C:S2). It replaces the default UI with a UI that provides hooks for mod-authors to inject their own UI components, makes it fit in with the existing game UI easily.

[!WARNING]
This is a early version of the loader/framework, expect dragons

The framework/loadah gives you the ability to write small little pieces of UI that you can use just as UI mods, or integrate with your own mod so you don't have to focus too much on UI code.

It consists of a few parts:

  • C# / Game Engine
    • HookUI Mod (mod/)
      • Loads files from other mods and puts them in place
      • Binds currently available extensions to a value the Game UI can read
      • Harmony patches to load the UI system and rewrite which directory the game UI uses
    • HookUI Lib (lib/)
      • Serves as the API for mods to register themselves, so HookUI Mod can find all the extensions required to load
  • JavaScript / Game UI (ui_lib/)
    • API - Sets window properties for mods to register themselves in the UI
    • Loader - Loads the mod extensions into the correct place
    • Menu - A button in the top-left to enable/disable current panels

Put another way:

  • HookUIMod - C# mod that gets loaded in Cities: Skylines 2
  • HookUILib - C# Library that gets used by mod authors
  • HookUI Game UI - Elements for loading and enabling/disabling extensions inside the game
  • HookUIFramework - JavaScript library with some utilties functions for writing Game UIs for Cities: Skylines 2

Requirements

Manual Installation (For players)

Documentation for Mod Authors

Full Examples: