Skip to content

Various game optimizations - #1486

Draft
SleepyG11 wants to merge 10 commits into
Steamodded:mainfrom
SleepyG11:optimize-as-much-as-i-can
Draft

Various game optimizations#1486
SleepyG11 wants to merge 10 commits into
Steamodded:mainfrom
SleepyG11:optimize-as-much-as-i-can

Conversation

@SleepyG11

@SleepyG11 SleepyG11 commented Aug 9, 2026

Copy link
Copy Markdown
Collaborator

This PR optimize various aspects of a game. Where I found this appropriate, I implemented some caching or more memory-efficient solutions.

Currently optimized:

  • SMODS.DrawStep - faster checks for basic conditions (vortex, facing, front_hidden)
    • Some change to API: previously check_condition method was called for every key in conditions list. Now, vortex, facing and front_hidden conditions does not use this method and calculated separately.
  • Node:inside_overflow_boundaries - skip cache checks when element have no parent; removed creating local function every frame
  • Node:collides_with_point - more efficient check if element's container is G.ROOM (almost 100% cases)
  • SMODS.resolve_ui_shaders - returning empty cached result if no shader provided instead of processing entire function (99.9% cases)

Additional Info:

  • I didn't modify api's or I've made a PR to the wiki repo.
  • I didn't modify api's or I've updated lsp definitions.
  • I didn't make new lovely files or all new lovely files have appropriate priority.

@SleepyG11
SleepyG11 marked this pull request as ready for review August 11, 2026 02:24
@SleepyG11
SleepyG11 marked this pull request as draft August 12, 2026 18:19
@SleepyG11

SleepyG11 commented Aug 12, 2026

Copy link
Copy Markdown
Collaborator Author

Working with Lilo on additional optimizations, goes back to draft until all of them will be resolved

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant