mirror of
https://github.com/PHIDIAS0303/ExpCluster.git
synced 2025-12-30 04:21:41 +09:00
Refactor some of the Guis from the legacy plugin (#399)
* Fix bugs in core and add default args to Gui defs * Refactor production Gui * Refactor landfill blueprint button * Fix more bugs in core * Consistent naming of new guis * Refactor module inserter gui * Refactor surveillance gui * Add shorthand for data from arguments * Make element names consistent * Add types * Change how table rows work * Refactor player stats gui * Refactor quick actions gui * Refactor research milestones gui * Refactor player bonus gui * Refactor science production gui * Refactor autofill gui * Cleanup use of aligned flow * Rename "Gui.element" to "Gui.define" * Rename Gui types * Rename property_from_arg * Add guide for making guis * Add full reference document * Add condensed reference * Apply style guide to refactored guis * Bug fixes
This commit is contained in:
@@ -18,7 +18,7 @@ local command_objects = {} --- @type table<string, Commands.Command>
|
||||
local required_translations = {} --- @type LocalisedString[]
|
||||
|
||||
--- Gets the descriptions of all commands, not including their aliases
|
||||
--- @param custom_commands table<string, Commands.ExpCommand> The complete list of registered custom commands
|
||||
--- @param custom_commands table<string, ExpCommand> The complete list of registered custom commands
|
||||
function Search.prepare(custom_commands)
|
||||
local known_aliases = {} --- @type table<string, string>
|
||||
for name, command in pairs(custom_commands) do
|
||||
@@ -85,7 +85,7 @@ end
|
||||
|
||||
--- Searches all game commands and the provided custom commands for the given keyword
|
||||
--- @param keyword string The keyword to search for
|
||||
--- @param custom_commands table<string, Commands.ExpCommand> A dictionary of commands to search
|
||||
--- @param custom_commands table<string, ExpCommand> A dictionary of commands to search
|
||||
--- @param locale string? The local to search, default is english ("en")
|
||||
--- @return table<string, Commands.Command> # A dictionary of commands
|
||||
function Search.search_commands(keyword, custom_commands, locale)
|
||||
|
||||
Reference in New Issue
Block a user