Skip to content

[cpp] Adds missing ranged attack animations for Fomor, Quadav and Kindred#9930

Merged
Xaver-DaRed merged 1 commit into
LandSandBoat:basefrom
Frankie-hz:rangedatt
May 4, 2026
Merged

[cpp] Adds missing ranged attack animations for Fomor, Quadav and Kindred#9930
Xaver-DaRed merged 1 commit into
LandSandBoat:basefrom
Frankie-hz:rangedatt

Conversation

@Frankie-hz
Copy link
Copy Markdown
Contributor

@Frankie-hz Frankie-hz commented May 4, 2026

I affirm:

  • I understand that if I do not agree to the following points by completing the checkboxes my PR will be ignored.
  • I understand I should leave resolving conversations to the LandSandBoat team so that reviewers won't miss what was said.
  • I have read and understood the Contributing Guide and the Code of Conduct.
  • I have tested my code and the things my code has changed since the last commit in the PR and will test after any later commits.

What does this pull request do?

This fix turned into more than I bargained for. What was supposed to be a simple "animation" fix turned out to be allowing mobs to use player ranged attacks.

This PR adds support for MOBs to use player-style ranged auto-attacks.

Previously, ranged attacks were effectively limited to player controller flow / mob special skill workarounds. This adds ranged attack support to the generic controller path so MOBs can enter CRangeState, perform a ranged attack action, and use ranged attack timing/range logic.

What Changed

  • Added controller support for MOB ranged attacks through CController::RangedAttack.
  • Updated CAIContainer::RangedAttack so it no longer only routes through CPlayerController.
  • Added setRangedAttackEnabled() and isRangedAttackEnabled() Lua bindings for enabling ranged auto-attacks on MOBs.
  • Added MOBMOD_RANGED_ATTACK_RANGE / xi.mobMod.RANGED_ATTACK_RANGE so MOB ranged attack distance can be configured.
  • Added MOB-specific ranged attack range handling, defaulting MOB ranged attacks to 14 yalms.
  • Updated CRangeState to use the entity’s ranged attack range instead of a hard-coded 25-yalm check.
  • Added MOB ranged attack delay handling so MOBs can properly wait between ranged attacks.
  • Added ranged attack execution logic to CBattleEntity::OnRangedAttack, including hit checks, crits, shadows, ranged damage, and action packet result handling.
  • Updated MOB combat movement so ranged-enabled MOBs close to ranged attack range instead of melee range.
  • Added setup logic for ranged-capable RNG/NIN MOBs, including Fomor/Hume-style ranged attackers.
  • Added/updated ranged attack related mob skill entries for Quadav and Kindred ranged attack animations.
  • Added ore_toss_ranged.lua as a ranged auto-attack style for Quadav (Added TODOs for FTPs)
  • Added hecatomb_wave_ra.lua as ranged auto-attack style for Kindred (Added TODOs for % damage/cap)

https://youtu.be/L7XsPrM4D4Q - LSB Video

Captures:
https://youtu.be/0b0k_CUQUp8

Ore Toss
https://youtu.be/_DgjxpcvDpE?t=1875
https://www.dropbox.com/scl/fi/i2z822zhnaewsw4fsn6wx/Dynamis-Bastok-mobskill-testing.zip?dl=0&e=1&file_subpath=%2FDynamis+Bastok+mobskill+testing%2FSiknawz%2Factionview%2Fsimple%2FDynamis+-+Bastok.log&rlkey=hx9dhxsjxf51q8i17lkgxfomd

Hecatomb Wave
https://www.youtube.com/watch?v=rGBmQPTxQ54
https://www.dropbox.com/scl/fi/3itqsjrihkjctszh99i89/Dynamis-Xarcabard-General-farming.zip?dl=0&e=1&file_subpath=%2FDynamis+Xarcabard+-+General+farming%2FSiknoz%2Factionview%2Fsimple%2FDynamis+-+Xarcabard.log&rlkey=29eg73glfpeovd9792mif3he8

Steps to test these changes

Auto-attack fomor:
!gotoid 16887904
hit it and run around, stand in melee, etc.

!gotoid 16887906
hit it and run around, stand in melee, etc.

Qudav:
!gotoid 17539087
hit it and run around, stand in melee, etc.

Kindred:
!gotoid 16949355
hit it and run around, stand in melee, etc.

@Frankie-hz Frankie-hz force-pushed the rangedatt branch 2 times, most recently from 7f9ae74 to e483a2a Compare May 4, 2026 04:32
Adds player ranged attacked for mobs for all the hume/fomor models.
Adds quadav ranged attacks
Adds Kindred ranged attacks
Adds mobmod for ranged attack range for mobs to be default 14 and moveable
@Xaver-DaRed Xaver-DaRed merged commit 623762c into LandSandBoat:base May 4, 2026
10 checks passed
@Frankie-hz Frankie-hz deleted the rangedatt branch May 4, 2026 23:41
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.

3 participants