Skip to content

Re-add DummyUnit import to defaultunits.lua#7180

Open
lL1l1 wants to merge 2 commits into
developfrom
fix/default-units-dummy-unit-import
Open

Re-add DummyUnit import to defaultunits.lua#7180
lL1l1 wants to merge 2 commits into
developfrom
fix/default-units-dummy-unit-import

Conversation

@lL1l1

@lL1l1 lL1l1 commented Jul 16, 2026

Copy link
Copy Markdown
Contributor

Issue

Reported on Discord.
BrewLAN_Units Research & Daiquiris mod expected class DummyUnit in defaultunits.lua

info: Hooked /lua/defaultunits.lua with /mods/brewlan/hook/lua/defaultunits.lua
info: Hooked /lua/defaultunits.lua with /mods/brewlan_units/brewresearch/hook/lua/defaultunits.lua
...
warning: ...data\faforever\gamedata\lua.nx2\lua\defaultunits.lua(147): access to nonexistent global variable "DummyUnit"

The reference was removed in #3697 due to the PRs #3441 and #3636 moving the class to Unit.lua.

Description of the proposed changes

Add back the reference to the defaultunits.lua file.

Testing done on the proposed changes

Loaded the mod with the changes and the game started successfully with no errors.

Checklist

Summary by CodeRabbit

  • Bug Fixes
    • Restored the missing DummyUnit compatibility import, resolving mod compatibility issues for BrewLAN Research & Daiquiris.
  • Documentation
    • Added a changelog entry documenting the compatibility fix.

@lL1l1
lL1l1 requested review from Basilisk3 and Garanas July 16, 2026 18:16
@lL1l1 lL1l1 added type: bug feature: mod compatibility related to FAF compatibility with mods labels Jul 16, 2026
@coderabbitai

coderabbitai Bot commented Jul 16, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

📝 Walkthrough

Walkthrough

Changes

DummyUnit compatibility

Layer / File(s) Summary
Restore DummyUnit import
lua/defaultunits.lua, changelog/snippets/fix.7180.md
DummyUnit is imported from /lua/sim/unit.lua into defaultunits.lua, with a changelog entry documenting restored mod compatibility.

Estimated code review effort: 1 (Trivial) | ~2 minutes

Suggested reviewers: garanas, basilisk3

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Title check ✅ Passed The title clearly summarizes the main change: re-adding DummyUnit to defaultunits.lua.
Description check ✅ Passed Covers the issue, proposed changes, testing, and checklist; only the optional Additional context section is missing.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/default-units-dummy-unit-import

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@lL1l1
lL1l1 force-pushed the fix/default-units-dummy-unit-import branch from 6c329ab to 78b46cf Compare July 16, 2026 18:19
@lL1l1
lL1l1 marked this pull request as ready for review July 16, 2026 18:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

feature: mod compatibility related to FAF compatibility with mods type: bug

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant