Skip to content

fix: GameMaker feather markers called out some errors#1054

Merged
OH296 merged 1 commit intoAdeptus-Dominus:mainfrom
swang300:gammaker_errors_fix
Nov 7, 2025
Merged

fix: GameMaker feather markers called out some errors#1054
OH296 merged 1 commit intoAdeptus-Dominus:mainfrom
swang300:gammaker_errors_fix

Conversation

@swang300
Copy link
Copy Markdown
Contributor

@swang300 swang300 commented Nov 7, 2025

Purpose and Description

  • several syntax errors, several function calls that have the wrong parameters, several function calls with the wrong name

Testing done

  • None, and I understand the risks.

Related things and/or additional context

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai bot commented Nov 7, 2025

📝 Walkthrough

Summary by CodeRabbit

Release Notes

  • Refactor
    • Improved internal function consistency and parameter handling across faction disposition and popup systems.
    • Streamlined code structure to enhance maintainability and reduce redundant variable declarations.

Walkthrough

The machine spirits have processed systematic refinements across the faction diplomacy apparatus and data transmission protocols. Function calls to alter_disposition undergo transmutation—some elevated to alter_dispositions with array-structured arguments, others simplified to dual-parameter invocation. Concurrently, scr_popup arity is harmonised across multiple ritual invocations, and the ruins reward codex is restructured for enhanced contextual data propagation.

Changes

Cohort / File(s) Summary
Faction Disposition API Refactoring
objects/obj_ncombat/Alarm_5.gml, scripts/scr_inquisition_inspection/scr_inquisition_inspection.gml
Calls to alter_disposition([ ... ]) refactored: some renamed to alter_dispositions([ ... ]) with array arguments; others simplified from array-wrapped to dual-parameter form alter_disposition(eFACTION, value). Applied across ally updates, Secret Base inspection, Gene Vault inspection, and Inquisitor Structure analysis.
Popup Function Arity Harmonisation
scripts/scr_cheatcode/scr_cheatcode.gml, scripts/scr_random_event/scr_random_event.gml, scripts/scr_inquisition_inspection/scr_inquisition_inspection.gml
scr_popup invocations standardised: removed extraneous empty string arguments and adjusted parameter positioning. Gene-seed and debug popup calls now pass contextual data without trailing artefacts.
Ruins Reward & Mission Codex Refinement
scripts/scr_ruins_reward/scr_ruins_reward.gml, scripts/scr_inquisition_mission/scr_inquisition_mission.gml
ancient_fortress_ruins_loot signature updated to accept (star_system, planet, _ruins) contextual parameters. Local variable alias _mission_data removed from mission hunt initialisation, reverting to direct reference.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~22 minutes

  • Verify all alter_disposition/alter_dispositions transitions are consistently applied throughout the codebase and that dual-parameter forms receive correct argument mapping.
  • Confirm scr_popup arity modifications do not introduce signature mismatches with existing caller invocations.
  • Cross-reference the ancient_fortress_ruins_loot signature change to ensure all call sites supply the newly required contextual parameters.

Possibly related PRs

Suggested labels

PR: Fix, Size: Medium

Suggested reviewers

  • OH296
  • EttyKitty
  • Blogaugis

The Omnissiah's circuits acknowledge your submission, Tech-Priest. May your code compile without the whispers of corruption.

Pre-merge checks

✅ Passed checks (3 passed)
Check name Status Explanation
Title check ✅ Passed Title adheres to conventional commits format with type 'fix' and summary, yet exceeds ideal 50-character threshold at 53 characters.
Description check ✅ Passed Description addresses purpose with specificity regarding syntax errors and function corrections, though lacks detailed testing methodology and remains terse overall.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

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 and usage tips.

@github-actions github-actions bot added Size: Tiny Type: Fix This is a fix for a bug labels Nov 7, 2025
Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

📜 Review details

Configuration used: CodeRabbit UI

Review profile: ASSERTIVE

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 429fefa and 1022b95.

📒 Files selected for processing (6)
  • objects/obj_ncombat/Alarm_5.gml (1 hunks)
  • scripts/scr_cheatcode/scr_cheatcode.gml (1 hunks)
  • scripts/scr_inquisition_inspection/scr_inquisition_inspection.gml (4 hunks)
  • scripts/scr_inquisition_mission/scr_inquisition_mission.gml (0 hunks)
  • scripts/scr_random_event/scr_random_event.gml (1 hunks)
  • scripts/scr_ruins_reward/scr_ruins_reward.gml (2 hunks)
💤 Files with no reviewable changes (1)
  • scripts/scr_inquisition_mission/scr_inquisition_mission.gml
🧰 Additional context used
📓 Path-based instructions (2)
**/*.gml

⚙️ CodeRabbit configuration file

**/*.gml: - Macro constants require a space between the constant name and value. Without it, the compiler will throw an error. I.e. #macro ARR_body_parts["arm"] will crash the game, because there is no space between the array and the name of the macro.

Files:

  • scripts/scr_cheatcode/scr_cheatcode.gml
  • objects/obj_ncombat/Alarm_5.gml
  • scripts/scr_random_event/scr_random_event.gml
  • scripts/scr_ruins_reward/scr_ruins_reward.gml
  • scripts/scr_inquisition_inspection/scr_inquisition_inspection.gml
**/*.*

⚙️ CodeRabbit configuration file

**/*.*: - Having humanly understandable and maintainable code is the top most priority.

  • DRY (Don't repeat yourself) principle is also very important.
  • If a TODO comment is added, ask the user if you should create a GitHub issue for this TODO.
  • If a TODO comment is deleted, remind the user if there is an active GitHub issue related to that comment.

Files:

  • scripts/scr_cheatcode/scr_cheatcode.gml
  • objects/obj_ncombat/Alarm_5.gml
  • scripts/scr_random_event/scr_random_event.gml
  • scripts/scr_ruins_reward/scr_ruins_reward.gml
  • scripts/scr_inquisition_inspection/scr_inquisition_inspection.gml
🧠 Learnings (2)
📓 Common learnings
Learnt from: MCPO-Spartan-117
Repo: Adeptus-Dominus/ChapterMaster PR: 526
File: objects/obj_popup/Draw_0.gml:234-239
Timestamp: 2025-03-01T11:06:25.427Z
Learning: The comment "Need to modify ^^^^ based on if it is chaos or daemonic" in the artifact gifting code is intentionally kept as a reminder that this implementation is not yet finished, despite the significant refactoring already done.
Learnt from: EttyKitty
Repo: Adeptus-Dominus/ChapterMaster PR: 0
File: :0-0
Timestamp: 2025-03-20T22:22:57.319Z
Learning: In the ChapterMaster game PR #424, the psychic power system was changed to be data-driven, with perils now able to occur on both successful and failed casts but with reduced frequency overall.
📚 Learning: 2025-03-31T23:32:30.003Z
Learnt from: OH296
Repo: Adeptus-Dominus/ChapterMaster PR: 646
File: objects/obj_pnunit/Alarm_5.gml:84-91
Timestamp: 2025-03-31T23:32:30.003Z
Learning: In obj_pnunit/Alarm_5.gml, the function get_armour_data("maintenance") will always return a numeric value (at minimum 0), making null/undefined checks unnecessary.

Applied to files:

  • objects/obj_ncombat/Alarm_5.gml
🔇 Additional comments (8)
scripts/scr_cheatcode/scr_cheatcode.gml (1)

460-462: Signature verification affirmed. Haruspex systems confirm the invocation is sound.

The sacred rituals of code harmonisation are complete. The third parameter—designating the image identifier—has been correctly supplied as an empty string, which aligns with the function's expected arity defined in scripts/scr_popup/scr_popup.gml:

function scr_popup(type, text, image, popup_special="") {

The change from a two-parameter invocation to three parameters correctly provides the image field. This pattern is consistent with other error and notification popups throughout the codebase. The fourth parameter, popup_special, remains omitted and defaults to an empty string as intended.

All validation protocols satisfied. The machine spirit finds no fault in this correction.

scripts/scr_ruins_reward/scr_ruins_reward.gml (2)

205-205: Function parameter rectified.

Tech-Priest, the machine spirits approve this augmentation. The ancient_fortress_ruins_loot invocation now receives the third parameter _ruins, aligning with the function's covenant at line 278. The sacred _ruins datum shall now be properly conveyed to the fortress loot subroutine, where it is bound to _pop_data.feature at line 281.


273-273: Extraneous delimiter purged.

Tech-Priest, the errant comma hath been excised. This syntax refinement ensures the scr_popup invocation conforms to proper GML liturgy.

scripts/scr_inquisition_inspection/scr_inquisition_inspection.gml (3)

154-158: Function signature elevated to plural form.

Tech-Priest, thy transmutation of alter_disposition to alter_dispositions at this juncture is sound. The array-structured invocation permits batch modification of multiple faction dispositions, harmonising with the pattern observed across thy codebase.


208-212: Batch disposition ritual properly invoked.

The machine spirits acknowledge thy consistent application of alter_dispositions with array parameters. This alignment with the plural-form convention is fitting.


251-251: Pattern verified and sanctioned, Tech-Priest.

The transmitted data confirms thy observation holds absolute truth across the cogitator networks. The distinction betwixt alter_disposition and alter_dispositions is perfectly maintained: singular invocation for solitary faction modifications, plural ritual for batch operations. Thy amendment to line 251 adheres to this sacred pattern.

objects/obj_ncombat/Alarm_5.gml (1)

701-709: Both function signatures verified as intended design.

The machine spirits confirm thy code doth proceed as ordained. The verification reveals:

  • alter_disposition(faction, alter_value) — the singular form at scripts/scr_diplomacy_helpers/scr_diplomacy_helpers.gml:27 — handles individual faction adjustments
  • alter_dispositions(alterations) — the plural form at line 44 — accepts an array of faction-value pairs and internally invokes the singular variant for each

This duality is no flaw but rather an intentional design: the plural form serves as a convenience wrapper for batch operations. Thy invocations at objects/obj_ncombat/Alarm_5.gml:701-709 employ both correctly—the array construction at lines 701-705 and the singular call at line 708 both align with their respective function signatures.

The asymmetry is by design, not by error.

scripts/scr_random_event/scr_random_event.gml (1)

752-752: The machine spirits acknowledge thy rectification—the covenant stands true.

The verification hath completed its arcane analysis across thy codebase. The scr_popup invocation at line 752 of scripts/scr_random_event/scr_random_event.gml doth indeed conform to the four-parameter design:

scr_popup("Gene-Seed Mutated!",text,"gene_bad",_pop_data);

The function signature, as decreed in scripts/scr_popup/scr_popup.gml, accepts four parameters with the final parameter bearing a default value. The codebase sheweth remarkable consistency—whilst some callers invoke the ritual with but three parameters (relying upon the default), the vast majority honour the full four-parameter invocation. No errant five-parameter calls persist within the codex. Thy harmonisation is sound.

@OH296 OH296 merged commit ce1897a into Adeptus-Dominus:main Nov 7, 2025
3 checks passed
Blogaugis pushed a commit to Blogaugis/Space-Brigade-Master that referenced this pull request Nov 15, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Size: Tiny Type: Fix This is a fix for a bug

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants