Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
57 commits
Select commit Hold shift + click to select a range
70da56f
add .lovelyignore to .gitignore
nnmrts Apr 14, 2025
a0488dd
Merge branch 'main' of https://github.com/Steamodded/smods
nnmrts Apr 16, 2025
35bd21b
Merge branch 'main' of https://github.com/Steamodded/smods
nnmrts Apr 20, 2025
4e46b72
Merge branch 'main' of https://github.com/Steamodded/smods
nnmrts Apr 21, 2025
e7c8cbe
Merge branch 'main' of https://github.com/Steamodded/smods
nnmrts Apr 22, 2025
59f2637
Merge branch 'main' of https://github.com/Steamodded/smods
nnmrts Apr 23, 2025
61fa819
Merge branch 'main' of https://github.com/Steamodded/smods
nnmrts Apr 23, 2025
43df1b1
Merge branch 'main' of https://github.com/Steamodded/smods
nnmrts Apr 23, 2025
7bfc77a
Merge branch 'main' of https://github.com/Steamodded/smods
nnmrts Apr 25, 2025
2c0903c
Merge branch 'main' of https://github.com/Steamodded/smods
nnmrts Apr 25, 2025
50cd19c
Merge branch 'main' of https://github.com/Steamodded/smods
nnmrts Apr 27, 2025
de99d74
Merge branch 'main' of https://github.com/Steamodded/smods
nnmrts Apr 29, 2025
fa333ba
Merge branch 'main' of https://github.com/Steamodded/smods
nnmrts May 3, 2025
2a904ea
Merge branch 'main' of https://github.com/Steamodded/smods
nnmrts May 4, 2025
917644d
Merge branch 'main' of https://github.com/Steamodded/smods
nnmrts May 4, 2025
028bde5
Merge branch 'main' of https://github.com/Steamodded/smods
nnmrts May 5, 2025
f666260
Add more text formatting options
Aikoyori May 6, 2025
4c7a1d6
Additional changes to the SMODS.Font PR
Aikoyori May 6, 2025
37550ce
Merge branch 'main' of https://github.com/Steamodded/smods
nnmrts May 6, 2025
b4426f2
Merge pull request #2 from Aikoyori/main
nnmrts May 6, 2025
2690c5f
Add LSP for SMODS.Font
Aikoyori May 6, 2025
2139607
fix for multibox
Aikoyori May 6, 2025
05672f8
Merge branch 'Steamodded:main' into main
Aikoyori May 6, 2025
bad34d8
Merge branch 'Steamodded:main' into main
Aikoyori May 6, 2025
fc68bbe
Merge branch 'main' of https://github.com/Steamodded/smods
nnmrts May 6, 2025
ae3d450
Merge pull request #3 from Aikoyori/main
nnmrts May 6, 2025
72ab846
Merge branch 'main' of https://github.com/pumpncode/smods
nnmrts May 6, 2025
c6c12d7
Merge branch 'Steamodded:main' into main
Aikoyori May 7, 2025
bff52dc
fix a crash when center is missing undiscovered_ loc entry
Aikoyori May 7, 2025
ba37935
hide them instead of showing error
Aikoyori May 7, 2025
1e2db17
Merge branch 'main' of https://github.com/Steamodded/smods
nnmrts May 7, 2025
81008e4
fix path in restart_game for MacOS
nnmrts May 7, 2025
b45ed48
unleak myself
nnmrts May 8, 2025
b04ede8
Merge pull request #4 from Aikoyori/main
nnmrts May 8, 2025
9a7393b
fix crash when `floating_sprite` is `nil`
nnmrts May 8, 2025
1d2735c
Merge branch 'main' of https://github.com/Steamodded/smods
nnmrts May 8, 2025
2d5eafd
Merge branch 'main' of https://github.com/Steamodded/smods
nnmrts May 9, 2025
e2d8789
Merge branch 'main' of https://github.com/Steamodded/smods
nnmrts May 10, 2025
cd20c3f
Merge branch 'main' of https://github.com/Steamodded/smods
nnmrts May 10, 2025
0f7eeb0
Merge branch 'main' of https://github.com/Steamodded/smods
nnmrts May 11, 2025
13a8fc2
Merge branch 'main' of https://github.com/Steamodded/smods
nnmrts May 12, 2025
1026841
Merge branch 'main' of https://github.com/Steamodded/smods
nnmrts May 19, 2025
50aaed4
add context.other_card.can_calculate check to eval_card patch
nnmrts May 19, 2025
6d4e74e
Merge branch 'main' of https://github.com/Steamodded/smods
nnmrts May 20, 2025
5ac25be
Merge branch 'main' of https://github.com/Steamodded/smods
nnmrts May 21, 2025
1f42294
merge upstream
nnmrts May 29, 2025
e53f324
Merge branch 'main' of https://github.com/Steamodded/smods
nnmrts May 30, 2025
bc06d4b
Merge branch 'main' of https://github.com/Steamodded/smods
nnmrts May 30, 2025
1b20a1f
Merge branch 'main' of https://github.com/Steamodded/smods
nnmrts May 30, 2025
0eb42fa
Merge branch 'main' of https://github.com/Steamodded/smods
nnmrts May 31, 2025
73980d4
Merge branch 'main' of https://github.com/Steamodded/smods
nnmrts Jun 3, 2025
e445494
merge upstream
nnmrts Jun 8, 2025
0d6ae84
Merge branch 'main' of https://github.com/Steamodded/smods
nnmrts Jun 17, 2025
cc10a20
Merge branch 'main' of https://github.com/Steamodded/smods
nnmrts Sep 10, 2025
7e937be
Merge branch 'main' of https://github.com/Steamodded/smods
nnmrts Sep 14, 2025
68662e1
Merge branch 'main' of https://github.com/Steamodded/smods
nnmrts Feb 14, 2026
6aa06ca
[ImgBot] Optimize images
ImgBotApp Feb 15, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -200,3 +200,5 @@ core/EditionAPI.lua
# LSP/Editor settings
.vscode
.luarc.json

.lovelyignore
Binary file modified assets/1x/default_achievements.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified assets/1x/mod_tags.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified assets/2x/default_achievements.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified assets/2x/mod_tags.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified icon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified libs/nativefs/icon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
38 changes: 19 additions & 19 deletions lsp_def/classes/font.lua
Original file line number Diff line number Diff line change
@@ -1,35 +1,35 @@
---@meta

---@class SMODS.Font: SMODS.GameObject
---@field obj_table? table<string, SMODS.Font|table> Table of objects registered to this class.
---@field super? SMODS.GameObject|table Parent class.
---@field path? string Name of the font file, including the extension.
---@field obj_table? table<string, SMODS.Font|table> Table of objects registered to this class.
---@field super? SMODS.GameObject|table Parent class.
---@field path? string Name of the font file, including the extension.
---@field render_scale? number Set the size of the font. This is generally better as a higher value so it can be scaled down. The default value is `200`.
---@field TEXT_HEIGHT_SCALE? number Determines line spacing. The default value is `0.83`.
---@field TEXT_OFFSET? table|{x: number, y: number} Determines the offset that the font is rendered. You might need to adjust this if the font renders in unexpected places. The default value is `{x=0, y=0}`.
---@field FONTSCALE? number Multiplier to scale down the font to the intended display size. Multiplies `render_scale` so that it renders at a proper size. The default value is `0.1`.
---@field squish? number Determines horizontal width of each character. The default value is `1`.
---@field DESCSCALE? number Determines how big the description text should be in relation to normal text. Keep in mind that mobile UI makes this 1.5x bigger. The default font's value is `1`.
---@field __call? fun(self: SMODS.Font|table, o: SMODS.Font|table): nil|table|SMODS.Font
---@field extend? fun(self: SMODS.Font|table, o: SMODS.Font|table): table Primary method of creating a class.
---@field check_duplicate_register? fun(self: SMODS.Font|table): boolean? Ensures objects already registered will not register.
---@field check_duplicate_key? fun(self: SMODS.Font|table): boolean? Ensures objects with duplicate keys will not register. Checked on `__call` but not `take_ownership`. For take_ownership, the key must exist.
---@field register? fun(self: SMODS.Font|table) Registers the object.
---@field check_dependencies? fun(self: SMODS.Font|table): boolean? Returns `true` if there's no failed dependencies.
---@field process_loc_text? fun(self: SMODS.Font|table) Called during `inject_class`. Handles injecting loc_text.
---@field send_to_subclasses? fun(self: SMODS.Font|table, func: string, ...: any) Starting from this class, recusively searches for functions with the given key on all subordinate classes and run all found functions with the given arguments.
---@field pre_inject_class? fun(self: SMODS.Font|table) Called before `inject_class`. Injects and manages class information before object injection.
---@field post_inject_class? fun(self: SMODS.Font|table) Called after `inject_class`. Injects and manages class information after object injection.
---@field inject_class? fun(self: SMODS.Font|table) Injects all direct instances of class objects by calling `obj:inject` and `obj:process_loc_text`. Also injects anything necessary for the class itself. Only called if class has defined both `obj_table` and `obj_buffer`.
---@field inject? fun(self: SMODS.Font|table, i?: number) Called during `inject_class`. Injects the object into the game.
---@field extend? fun(self: SMODS.Font|table, o: SMODS.Font|table): table Primary method of creating a class.
---@field check_duplicate_register? fun(self: SMODS.Font|table): boolean? Ensures objects already registered will not register.
---@field check_duplicate_key? fun(self: SMODS.Font|table): boolean? Ensures objects with duplicate keys will not register. Checked on `__call` but not `take_ownership`. For take_ownership, the key must exist.
---@field register? fun(self: SMODS.Font|table) Registers the object.
---@field check_dependencies? fun(self: SMODS.Font|table): boolean? Returns `true` if there's no failed dependencies.
---@field process_loc_text? fun(self: SMODS.Font|table) Called during `inject_class`. Handles injecting loc_text.
---@field send_to_subclasses? fun(self: SMODS.Font|table, func: string, ...: any) Starting from this class, recusively searches for functions with the given key on all subordinate classes and run all found functions with the given arguments.
---@field pre_inject_class? fun(self: SMODS.Font|table) Called before `inject_class`. Injects and manages class information before object injection.
---@field post_inject_class? fun(self: SMODS.Font|table) Called after `inject_class`. Injects and manages class information after object injection.
---@field inject_class? fun(self: SMODS.Font|table) Injects all direct instances of class objects by calling `obj:inject` and `obj:process_loc_text`. Also injects anything necessary for the class itself. Only called if class has defined both `obj_table` and `obj_buffer`.
---@field inject? fun(self: SMODS.Font|table, i?: number) Called during `inject_class`. Injects the object into the game.
---@field take_ownership? fun(self: SMODS.Font|table, key: string, obj: SMODS.Font|table, silent?: boolean): nil|table|SMODS.Font Takes control of vanilla objects. Child class must have get_obj for this to function
---@field get_obj? fun(self: SMODS.Font|table, key: string): SMODS.Font|table? Returns an object if one matches the `key`.
---@field get_obj? fun(self: SMODS.Font|table, key: string): SMODS.Font|table? Returns an object if one matches the `key`.
---@overload fun(self: SMODS.Font): SMODS.Font
SMODS.Font = setmetatable({}, {
__call = function(self)
return self
end
__call = function(self)
return self
end
})

---@type table<string, SMODS.Font|table>
SMODS.Fonts = {}
SMODS.Fonts = {}