Repository navigation
Add actor attribute service - #2610
Open
Fantaselion wants to merge 4 commits into
Open
Fantaselion wants to merge 4 commits into
Fantaselion wants to merge 4 commits into
Conversation
Contributor
|
I think it would be best if you broke down this PR in multiple, smaller chunks. It's over 60k lines of code so it's practically impossible to review imo |
Author
Ahhh good idea. the though never crossed my mind honestly lol. |
Fantaselion
force-pushed
the
actor-attribute-service-pr
branch
from
September 25, 2026 12:46
f5ca77a to
3c0e86f
Compare
… down at certain movement speeds.
This was referenced Oct 1, 2026
…obbing prevention
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This new service adds an ability for anyone to modify several different attributes of an enemy
• Movement Speed
• Size
• Health
• Attack Damage
• Gravity
• Notice Range
• Player Knockback
• Stun Duration - this makes enemies impossible to hit at times so best to be carefull with this one.
All the user needs is the fopAc_ac_c pointer.
I made this for my enemy attribute randomizer mod - https://github.com/Fantaselion/enemy-attribute-randomizer since I couldn't figure out any good way (that was reasonable) to have this entirely mod-sided. besides this makes it so that other people can use it!
This has been in the works for about 6 weeks and its all I've been doing all day, extensively tested it and verified every change in game, the reason the code changes are so long is I had to go to basically every part where enemy attributes are consumed (since I didn't want to effect other instance of the same type of actor in the room/cause it to scale an attribute every frame) and put it through my helpers. This got very complicated because movement speed is consumed through many different actor-specific code paths.
For testing, I've played through the game multiple times using big combinations such as 25% enemy size with 400% movement speed and the reverse, 400% size with 25% movement speed. I have also individually tested the other attributes and the actor-specific fixes that were required by those values.
In my mod I have gravity match movement speed since that just looks better.
The knockback Attribute was done with me modifying d_a_alink files and its damage, swim, and wolf includes so it works with each enemy. it says what it does on the tin, link gets pushed that much farther back horizontally based on the attribute. I tested it at 100x and it works just fine (actually was surprised it didn't clip me through walls)
AI disclosure: I used ChatGPT only as a tool during this project, mainly when i was working through some repetitive integrations and math-heavy helper code. I always reviewed and tested any code it gave me. If I didn't understand the code it gave me I didn't use it until I did and agreed with it.
I also did additional cleanup and comparison passes before preparing this PR including making sure all my code have TARGET_PC guards and then checking the final diff against upstream.
there are certain enemies and bosses that required unusaly changes such as having links grab animation match the speed of the enemy so it works properly, having the spinner go faster if the 2nd phase of stalord is going faster, making the hookshot fire faster if morpheal is faster etc... I will admit some of these were creative decisions as the alternative at times was just to clamp the max speed of these bosses.
𝐔𝐩𝐝𝐚𝐭𝐞: I've split the original implementation into smaller PRs for review. This PR now contains only the core Actor Attribute Service, public API, registry integration, and shared helpers. I will PR the other Actor/player integrations seperatly.