Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: per method hooks #534

Open
wants to merge 2 commits into
base: 4.x
Choose a base branch
from

Conversation

Qubus0
Copy link
Collaborator

@Qubus0 Qubus0 commented Jan 30, 2025

closes #426

Hooks are now applied by method instead of by script.

This should make hooks safer in general - even if one method may not be processed correctly, it won't break the whole script or prevent it from being modded.

caching of the methods is slightly different now: if there is any difference in which scripts or methods are hooked, everything is processed. This is a bit less efficient, but also more predictable while still reducing the processing required if the game is started with the exact same mods/hooks, and reducing required restarts because of it

@Qubus0 Qubus0 added enhancement New feature or request 4.x labels Jan 30, 2025
@Qubus0 Qubus0 added this to the 4.x - 7.0.0 milestone Jan 30, 2025
@Qubus0 Qubus0 requested a review from KANAjetzt January 30, 2025 15:42
@Qubus0 Qubus0 self-assigned this Jan 30, 2025
@Qubus0 Qubus0 changed the base branch from main to 4.x January 30, 2025 15:42
@KANAjetzt KANAjetzt changed the title Feat/426 per method hooks feat: per method hooks Jan 31, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
4.x enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

dynamic hooking: selectively only hook targeted methods instead of whole file
1 participant