Skip to content

feat: Contemptor dreadnought by werwolf#966

Merged
OH296 merged 18 commits intoAdeptus-Dominus:mainfrom
OH296:Contemptor
Aug 16, 2025
Merged

feat: Contemptor dreadnought by werwolf#966
OH296 merged 18 commits intoAdeptus-Dominus:mainfrom
OH296:Contemptor

Conversation

@OH296
Copy link
Collaborator

@OH296 OH296 commented Aug 12, 2025

Purpose and Description

  • Self-descriptive.

Testing done

  • None, and I understand the risks.

Related things and/or additional context

@github-actions github-actions bot added Area: Sprites Changes to sprites/images or their under-the-hood functionality Size: Epic Type: Feature Adds something new labels Aug 12, 2025
@coderabbitai
Copy link
Contributor

coderabbitai bot commented Aug 12, 2025

Important

Review skipped

Auto incremental reviews are disabled on this repository.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

📝 Walkthrough

Summary by CodeRabbit

  • New Features

    • Added Contemptor Dreadnought armour variant with dedicated weapon options, including Twin‑linked Volkite Culverins and a Contemptor CCW.
    • Expanded visuals: dreadnought weapon sets, librarian robes/belt, apothecary eye, combat shield overlay, angelic wings, and new decorations.
    • Shop: new dreadnought items appear within the Volkite pack.
    • Roster auto‑groups dreadnoughts into their own squad.
  • Improvements

    • End‑turn battle display consolidated into a focused panel.
    • More consistent dreadnought detection and unit rendering, with new foreground/offset support.
  • Assets

    • Numerous new sprites added and sprite metadata refined; font stability improved.

Walkthrough

By the Omnissiah: Adds 11 sprite assets and registers them in ChapterMaster.yyp; introduces Contemptor Dreadnought armour and two weapons (Contemptor CCW, Twin‑linked Volkite Culverins); expands modular/weapon visual data and Dreadnought handling (is_dreadnought/equipment_has_tag); refactors end‑turn UI drawing; updates shop and sprite metadata/sequence fields.

Changes

Cohort / File(s) Summary
Project registry
ChapterMaster.yyp
Registers 11 new sprite resources (spr_angelic_wings, spr_binders_belt, spr_binders_robe, spr_combat_shield_bottom_part, spr_contemptor_CCW, spr_contemptor_chasis_colors, spr_contemptor_head_colors, spr_crux_belt_fancy, spr_gear_apoth_eye, spr_twl_Volkite_Culverins, spr_sgt_forehead).
New sprite assets
sprites/spr_angelic_wings/..., sprites/spr_binders_*/*, sprites/spr_combat_shield_bottom_part/*, sprites/spr_contemptor_*/*, sprites/spr_crux_belt_fancy/*, sprites/spr_gear_apoth_eye/*, sprites/spr_twl_Volkite_Culverins/*, sprites/spr_sgt_forehead/*
Adds 11 GMSprite files (frames, sequences, metadata) under MarineViewer (dreadnought/decoration/body_type groups).
Sprite metadata normalisation & edits
sprites/... (many files)
Adds seqWidth/seqHeight fields, reserialises keyframe/channel structures, minor frame/size changes (notably spr_gear_apoth frame removed, spr_pack_brazier3 resized). Mostly data/format changes.
Weapons & gear
scripts/scr_weapon/scr_weapon.gml
Adds weapons "Twin‑linked Volkite Culverins" and "Contemptor CCW"; adds armour "Contemptor Dreadnought" with tags and stats.
Shop & names
objects/obj_shop/Create_0.gml, scripts/scr_get_item_names/scr_get_item_names.gml
Adds new Volkite Pack items to shop (Contemptor Dreadnought, Twin‑linked Volkite Culverins, Contemptor CCW); appends new ranged weapon name.
Modular drawing / ComplexSet
scripts/scr_ComplexSet/scr_ComplexSet.gml
Introduces static base_modulars_checks, offsets/override merging, subcomponent/foreground_item support; adds Contemptor Dreadnought case and Dreadnought weapon draw flow.
Culture & weapon visuals
scripts/scr_culture_visuals/scr_culture_visuals.gml
Extends global.modular_drawing_items (robes, belts, angelic_wings, apoth eye, combat shield), expands global.weapon_visual_data with Dreadnought variants, adds DummyMarine.is_dreadnought().
Unit drawing simplification
scripts/scr_draw_unit_image/scr_draw_unit_image.gml
Removes several niche shader/trait branches and decorations, simplifies armour detection to is_dreadnought(), streamlines robe and Dreadnought paths.
Dreadnought utilities & equip flows
scripts/scr_marine_struct/scr_marine_struct.gml, scripts/scr_reequip_units/*, scripts/scr_unit_equip_functions/*, scripts/scr_roster/*, scripts/scr_apothecary_ground/*, scripts/scr_initialize_custom/*
Adds static is_dreadnought() and equipment_has_tag(); swaps string checks for tag/predicate checks; updates re‑equip, roster, apothecary and initializer flows; adds Contemptor Dreadnought handling.
Turn‑end UI refactor
objects/obj_turn_end/Draw_0.gml, objects/obj_turn_end/Draw_64.gml
Removes large inline draw block; extracts end‑turn UI into main_slate.inside_method and invokes main_slate.draw_with_dimensions, preserving gating.
UI mapping & minor
scripts/scr_ui_display_weapons/scr_ui_display_weapons.gml, scripts/scr_ui_settings/scr_ui_settings.gml
Adds dreadnought component mappings for new weapons; one whitespace formatting change in settings.
Fonts
fonts/fnt_menu/fnt_menu.yy
Toggles regenerateBitmap flag from true → false.

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~45 minutes

Possibly related PRs

Suggested labels

Size: Medium

Suggested reviewers

  • EttyKitty
  • Blogaugis

Ave mechanicus.


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
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

CodeRabbit Commands (Invoked using PR/Issue comments)

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

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai or @coderabbitai title anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Status, Documentation and Community

  • Visit our Status Page to check the current availability of CodeRabbit.
  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link
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: 24

🔭 Outside diff range comments (6)
scripts/scr_ui_settings/scr_ui_settings.gml (1)

383-389: Dreadnought gating misses Contemptor; switch from string check to robust predicate

Blessed diagnostics: the current check only matches armour name “Dreadnought”. With Contemptor added, this UI will fail to lock “Special Item” for Contemptor armour. Also, ide == 6 is brittle compared to eROLE.Dreadnought.

Short-term fix (string containment) plus a readability upgrade:

-                    var nep = false;
-                    
-                    if (((obj_ini.armour[co, ide] == "Terminator Armour") || (obj_ini.armour[co, ide] == "Dreadnought")) && (gg == 4)) {
+                    var nep = false;
+                    var armour_name = obj_ini.armour[co, ide];
+                    // Lock special item when Terminator or any Dreadnought variant
+                    if (((armour_name == "Terminator Armour") || (string_pos("Dreadnought", armour_name) > 0)) && (gg == 4)) {
                         nep = true;
                     }
-                    if ((ide == 6) && ((gg == 3) || (gg == 5))) {
+                    // Lock armour/mobility for Dreadnought role
+                    if ((ide == eROLE.Dreadnought) && ((gg == 3) || (gg == 5))) {
                         nep = true;
                     }

Long-term purity: replace these string/role checks with the new tag utilities introduced in this PR (e.g., an equipment_has_tag("dreadnought", "armour") or _unit.is_dreadnought() equivalent at UI-time), ensuring future variants auto-comply. I can draft that refactor if desired.

sprites/spr_creation_slate/spr_creation_slate.yy (1)

36-36: Name the sequence to match the sprite — maintain liturgical consistency.

Other assets name the GMSequence after the sprite. Recommend setting both fields to ease debugging and resource audits.

-    "%Name":"",
+    "%Name":"spr_creation_slate",
@@
-    "name":"",
+    "name":"spr_creation_slate",

Also applies to: 60-60

scripts/scr_ui_display_weapons/scr_ui_display_weapons.gml (1)

176-195: Standardise weapon key names and correct Lascannon sprite mapping

In the Machine’s sight, two inconsistencies stand revealed:

  • Hyphenation mismatch:
    • “Twin-linked Volkite Culverins” uses a hyphen, whereas other “Twin Linked …” entries do not.
  • Lascannon sprite mapping:
    • The standalone "Lascannon" key wrongly points to spr_dread_plasma_cannon instead of spr_dread_lascannon.

Apply the following changes in scripts/scr_ui_display_weapons/scr_ui_display_weapons.gml (around lines 176–195):

-        "Lascannon" : spr_dread_plasma_cannon,
+        "Lascannon" : spr_dread_lascannon,

-        "Twin-linked Volkite Culverins":spr_twl_Volkite_Culverins,
+        "Twin Linked Volkite Culverins":spr_twl_Volkite_Culverins,
scripts/scr_unit_equip_functions/scr_unit_equip_functions.gml (1)

113-117: Potential null dereference on new_arm_data.has_tag("dreadnought").

The dreadnought check is outside the prior is_struct(new_arm_data) guard. If new_arm_data is undefined (e.g., unequipping), this will fault.

Apply this guard to prevent runtime errors:

-    if (new_arm_data.has_tag("dreadnought")) {
+    if (is_struct(new_arm_data) && new_arm_data.has_tag("dreadnought")) {
         is_boarder = false;
         update_gear("");
         update_mobility_item("");
     }
objects/obj_shop/Create_0.gml (1)

561-569: Standardise nobuy assignment to avoid index misalignment.

By the Omnissiah, the nobuy flag for “Volkite Charger” is set before the item name is assigned (Line 563), which works but diverges from the established pattern and the documented pitfall. To minimise off-by-one hazards and improve readability, assign nobuy after defining the item and before incrementing i.

Apply this diff to localise nobuy to the just-defined item:

-        nobuy[i] = 1;
-		i += 1;
-        nobuy[i] = 1;
-        item[i] = "Volkite Charger";
+        nobuy[i] = 1;
+		i += 1;
+        item[i] = "Volkite Charger";
         item_stocked[i] = scr_item_count(item[i]);
         item_cost[i] = 0;
         forge_cost[i] = 0;
-        i += 1;
-        nobuy[i] = 1;
+        nobuy[i] = 1;
+        i += 1;
scripts/scr_reequip_units/scr_reequip_units.gml (1)

468-512: Optional: consolidate all dread gating to tag-based checks.

Multiple places still rely on string_count or specific names; consolidating on armour_data.has_tag("dreadnought") (and “terminator”) will reduce regressions as new variants (e.g., other dread types) are introduced.

Also applies to: 551-567

📜 Review details

Configuration used: CodeRabbit UI
Review profile: ASSERTIVE
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between ce48b38 and 9c46066.

⛔ Files ignored due to path filters (43)
  • sprites/spr_angelic_wings/c5bc43cd-b567-4673-92b9-efede7a0b44f.png is excluded by !**/*.png
  • sprites/spr_angelic_wings/layers/c5bc43cd-b567-4673-92b9-efede7a0b44f/0e8b239a-6017-4ba5-8cbe-9353a86768ec.png is excluded by !**/*.png
  • sprites/spr_binders_belt/b6ba8600-fb6b-4fa9-abc7-bdc2311eb79e.png is excluded by !**/*.png
  • sprites/spr_binders_belt/layers/b6ba8600-fb6b-4fa9-abc7-bdc2311eb79e/468e0a30-2dea-45bc-a7bd-4b115f803d2d.png is excluded by !**/*.png
  • sprites/spr_binders_robe/c00a412a-a9bc-45ec-9142-9d8a013a975a.png is excluded by !**/*.png
  • sprites/spr_binders_robe/layers/c00a412a-a9bc-45ec-9142-9d8a013a975a/0b5e7fba-d4a1-441e-a726-f45a72c56663.png is excluded by !**/*.png
  • sprites/spr_combat_shield_bottom_part/0ca30034-8ae6-44ea-ab2a-6277d1920908.png is excluded by !**/*.png
  • sprites/spr_combat_shield_bottom_part/587d63a4-32c8-4617-9c28-59a8a099c2c1.png is excluded by !**/*.png
  • sprites/spr_combat_shield_bottom_part/layers/0ca30034-8ae6-44ea-ab2a-6277d1920908/5cc2322f-a426-43f4-bc78-5cc25edf9210.png is excluded by !**/*.png
  • sprites/spr_combat_shield_bottom_part/layers/587d63a4-32c8-4617-9c28-59a8a099c2c1/5cc2322f-a426-43f4-bc78-5cc25edf9210.png is excluded by !**/*.png
  • sprites/spr_contemptor_CCW/8c0bf9aa-b172-4cd7-b1a7-076d9fd90f9e.png is excluded by !**/*.png
  • sprites/spr_contemptor_CCW/layers/8c0bf9aa-b172-4cd7-b1a7-076d9fd90f9e/be470e13-bbeb-41d1-ae61-263c91abbae3.png is excluded by !**/*.png
  • sprites/spr_contemptor_chasis_colors/d55f9e41-41e0-43bd-b40c-86d963212769.png is excluded by !**/*.png
  • sprites/spr_contemptor_chasis_colors/layers/d55f9e41-41e0-43bd-b40c-86d963212769/c511d01c-c558-46fa-b06f-82950d47dfc4.png is excluded by !**/*.png
  • sprites/spr_contemptor_head_colors/74c01830-4218-44ae-aa3d-aba9109cecc2.png is excluded by !**/*.png
  • sprites/spr_contemptor_head_colors/layers/74c01830-4218-44ae-aa3d-aba9109cecc2/b113086c-f660-4cc2-bbdb-b89f64979d6b.png is excluded by !**/*.png
  • sprites/spr_creation_other/380cd3fb-d188-44e1-8e61-f3d7c0c8f526.png is excluded by !**/*.png
  • sprites/spr_creation_other/layers/380cd3fb-d188-44e1-8e61-f3d7c0c8f526/d07f3659-6442-4004-bcfa-c2f9ad3619bf.png is excluded by !**/*.png
  • sprites/spr_creation_slate/6d4b0fe4-2d29-43cc-9838-317bd93abc41.png is excluded by !**/*.png
  • sprites/spr_creation_slate/layers/6d4b0fe4-2d29-43cc-9838-317bd93abc41/edca4948-39ec-4e5f-ab97-4d1d7c174675.png is excluded by !**/*.png
  • sprites/spr_crux_belt_fancy/8a2b3d9f-db94-4f5a-8b6c-c14863b33cb4.png is excluded by !**/*.png
  • sprites/spr_crux_belt_fancy/bb6b8e74-ce86-4f55-a05a-63c120b9dfb1.png is excluded by !**/*.png
  • sprites/spr_crux_belt_fancy/layers/8a2b3d9f-db94-4f5a-8b6c-c14863b33cb4/a3482820-22c0-4934-a6c1-87b382d13fad.png is excluded by !**/*.png
  • sprites/spr_crux_belt_fancy/layers/bb6b8e74-ce86-4f55-a05a-63c120b9dfb1/7d1b6c03-f7ec-4403-8b30-9c53ab5a127d.png is excluded by !**/*.png
  • sprites/spr_gear_apoth_eye/3ef63e36-9f97-4c93-a6b9-d09b80fd1fbe.png is excluded by !**/*.png
  • sprites/spr_gear_apoth_eye/layers/3ef63e36-9f97-4c93-a6b9-d09b80fd1fbe/db192a8c-3604-4553-bea9-59dc5e18b44c.png is excluded by !**/*.png
  • sprites/spr_gear_combat_shield/350bde68-1664-48e8-97c4-7cff3c59b4ae.png is excluded by !**/*.png
  • sprites/spr_gear_combat_shield/587d63a4-32c8-4617-9c28-59a8a099c2c1.png is excluded by !**/*.png
  • sprites/spr_gear_combat_shield/layers/350bde68-1664-48e8-97c4-7cff3c59b4ae/5cc2322f-a426-43f4-bc78-5cc25edf9210.png is excluded by !**/*.png
  • sprites/spr_gear_combat_shield/layers/587d63a4-32c8-4617-9c28-59a8a099c2c1/5cc2322f-a426-43f4-bc78-5cc25edf9210.png is excluded by !**/*.png
  • sprites/spr_pack_brazier3/3368318c-d87a-46c2-891b-f8d5cebbf275.png is excluded by !**/*.png
  • sprites/spr_pack_brazier3/6633717b-8f5b-4785-b3fd-05a0b9b5ad4b.png is excluded by !**/*.png
  • sprites/spr_pack_brazier3/layers/3368318c-d87a-46c2-891b-f8d5cebbf275/23f60daa-fe76-4e85-9875-adbeb4cce378.png is excluded by !**/*.png
  • sprites/spr_pack_brazier3/layers/6633717b-8f5b-4785-b3fd-05a0b9b5ad4b/23f60daa-fe76-4e85-9875-adbeb4cce378.png is excluded by !**/*.png
  • sprites/spr_sgt_forehead/3dbaa400-5fe2-498d-abd8-9cc4b2bda693.png is excluded by !**/*.png
  • sprites/spr_sgt_forehead/61531cde-cd44-4806-ae39-3c63f51d65de.png is excluded by !**/*.png
  • sprites/spr_sgt_forehead/layers/3dbaa400-5fe2-498d-abd8-9cc4b2bda693/4ff43f57-b34a-4219-8298-0399265c623b.png is excluded by !**/*.png
  • sprites/spr_sgt_forehead/layers/61531cde-cd44-4806-ae39-3c63f51d65de/4ff43f57-b34a-4219-8298-0399265c623b.png is excluded by !**/*.png
  • sprites/spr_sgt_forehead/layers/61531cde-cd44-4806-ae39-3c63f51d65de/a4c8b294-e4be-4fef-8912-4d706c9cec44.png is excluded by !**/*.png
  • sprites/spr_sgt_forehead/layers/61531cde-cd44-4806-ae39-3c63f51d65de/b7b29ef3-6ea3-4b38-893a-fb3da7d22800.png is excluded by !**/*.png
  • sprites/spr_sgt_forehead/layers/61531cde-cd44-4806-ae39-3c63f51d65de/d292644f-2a3b-4981-868a-a423161e3739.png is excluded by !**/*.png
  • sprites/spr_twl_Volkite_Culverins/d532989d-6b36-48dc-9ccb-1daf433cbb1f.png is excluded by !**/*.png
  • sprites/spr_twl_Volkite_Culverins/layers/d532989d-6b36-48dc-9ccb-1daf433cbb1f/1f3e5664-e536-47f4-b0bf-214e1fd9c23a.png is excluded by !**/*.png
📒 Files selected for processing (65)
  • ChapterMaster.yyp (7 hunks)
  • objects/obj_shop/Create_0.gml (2 hunks)
  • objects/obj_turn_end/Draw_0.gml (1 hunks)
  • objects/obj_turn_end/Draw_64.gml (1 hunks)
  • scripts/scr_ComplexSet/scr_ComplexSet.gml (14 hunks)
  • scripts/scr_apothecary_ground/scr_apothecary_ground.gml (1 hunks)
  • scripts/scr_culture_visuals/scr_culture_visuals.gml (15 hunks)
  • scripts/scr_draw_unit_image/scr_draw_unit_image.gml (4 hunks)
  • scripts/scr_get_item_names/scr_get_item_names.gml (2 hunks)
  • scripts/scr_initialize_custom/scr_initialize_custom.gml (1 hunks)
  • scripts/scr_marine_struct/scr_marine_struct.gml (2 hunks)
  • scripts/scr_reequip_units/scr_reequip_units.gml (4 hunks)
  • scripts/scr_roster/scr_roster.gml (1 hunks)
  • scripts/scr_ui_display_weapons/scr_ui_display_weapons.gml (1 hunks)
  • scripts/scr_ui_settings/scr_ui_settings.gml (1 hunks)
  • scripts/scr_unit_equip_functions/scr_unit_equip_functions.gml (2 hunks)
  • scripts/scr_weapon/scr_weapon.gml (3 hunks)
  • sprites/spr_angelic_wings/spr_angelic_wings.yy (1 hunks)
  • sprites/spr_apothecary_lights/spr_apothecary_lights.yy (1 hunks)
  • sprites/spr_backpack_fastening/spr_backpack_fastening.yy (1 hunks)
  • sprites/spr_binders_belt/spr_binders_belt.yy (1 hunks)
  • sprites/spr_binders_robe/spr_binders_robe.yy (1 hunks)
  • sprites/spr_binders_robes/spr_binders_robes.yy (1 hunks)
  • sprites/spr_blog/spr_blog.yy (1 hunks)
  • sprites/spr_cloth_tabbard/spr_cloth_tabbard.yy (1 hunks)
  • sprites/spr_combat_shield_bottom_part/spr_combat_shield_bottom_part.yy (1 hunks)
  • sprites/spr_contemptor_CCW/spr_contemptor_CCW.yy (1 hunks)
  • sprites/spr_contemptor_chasis_colors/spr_contemptor_chasis_colors.yy (1 hunks)
  • sprites/spr_contemptor_head_colors/spr_contemptor_head_colors.yy (1 hunks)
  • sprites/spr_creation_check/spr_creation_check.yy (1 hunks)
  • sprites/spr_creation_existing/spr_creation_existing.yy (1 hunks)
  • sprites/spr_creation_founding/spr_creation_founding.yy (1 hunks)
  • sprites/spr_creation_other/spr_creation_other.yy (3 hunks)
  • sprites/spr_creation_slate/spr_creation_slate.yy (3 hunks)
  • sprites/spr_crux_belt_fancy/spr_crux_belt_fancy.yy (1 hunks)
  • sprites/spr_dread_claw/spr_dread_claw.yy (1 hunks)
  • sprites/spr_dread_iron_clad/spr_dread_iron_clad.yy (1 hunks)
  • sprites/spr_dreadnought_chasis_colors/spr_dreadnought_chasis_colors.yy (1 hunks)
  • sprites/spr_dreadnought_decorations/spr_dreadnought_decorations.yy (1 hunks)
  • sprites/spr_facial_colors/spr_facial_colors.yy (1 hunks)
  • sprites/spr_gear_apoth/spr_gear_apoth.yy (3 hunks)
  • sprites/spr_gear_apoth_eye/spr_gear_apoth_eye.yy (1 hunks)
  • sprites/spr_gear_halo/spr_gear_halo.yy (1 hunks)
  • sprites/spr_gear_librarian/spr_gear_librarian.yy (1 hunks)
  • sprites/spr_gear_librarian_term/spr_gear_librarian_term.yy (1 hunks)
  • sprites/spr_gear_techa/spr_gear_techa.yy (1 hunks)
  • sprites/spr_indomitus_belt/spr_indomitus_belt.yy (1 hunks)
  • sprites/spr_lion_belt/spr_lion_belt.yy (1 hunks)
  • sprites/spr_marine_cloth_hood/spr_marine_cloth_hood.yy (1 hunks)
  • sprites/spr_metal_tabbard/spr_metal_tabbard.yy (1 hunks)
  • sprites/spr_mk3_left_arm/spr_mk3_left_arm.yy (1 hunks)
  • sprites/spr_mk7_complex_belt/spr_mk7_complex_belt.yy (1 hunks)
  • sprites/spr_mk7_complex_crux_belt/spr_mk7_complex_crux_belt.yy (1 hunks)
  • sprites/spr_mk7_wolf_cult_belt/spr_mk7_wolf_cult_belt.yy (1 hunks)
  • sprites/spr_mongol_hat/spr_mongol_hat.yy (1 hunks)
  • sprites/spr_mongol_topknots/spr_mongol_topknots.yy (1 hunks)
  • sprites/spr_pack_brazier3/spr_pack_brazier3.yy (4 hunks)
  • sprites/spr_planet_splash/spr_planet_splash.yy (1 hunks)
  • sprites/spr_prussian_spike/spr_prussian_spike.yy (1 hunks)
  • sprites/spr_servo_harness/spr_servo_harness.yy (1 hunks)
  • sprites/spr_settings_bg/spr_settings_bg.yy (1 hunks)
  • sprites/spr_sgt_forehead/spr_sgt_forehead.yy (1 hunks)
  • sprites/spr_terminator_laurel/spr_terminator_laurel.yy (1 hunks)
  • sprites/spr_twl_Volkite_Culverins/spr_twl_Volkite_Culverins.yy (1 hunks)
  • sprites/spr_weapon_powspear2/spr_weapon_powspear2.yy (1 hunks)
🧰 Additional context used
📓 Path-based instructions (3)
**/*.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_ui_settings/scr_ui_settings.gml
  • scripts/scr_unit_equip_functions/scr_unit_equip_functions.gml
  • scripts/scr_ui_display_weapons/scr_ui_display_weapons.gml
  • scripts/scr_roster/scr_roster.gml
  • scripts/scr_initialize_custom/scr_initialize_custom.gml
  • scripts/scr_get_item_names/scr_get_item_names.gml
  • scripts/scr_apothecary_ground/scr_apothecary_ground.gml
  • scripts/scr_weapon/scr_weapon.gml
  • objects/obj_turn_end/Draw_64.gml
  • scripts/scr_marine_struct/scr_marine_struct.gml
  • scripts/scr_reequip_units/scr_reequip_units.gml
  • scripts/scr_draw_unit_image/scr_draw_unit_image.gml
  • objects/obj_shop/Create_0.gml
  • objects/obj_turn_end/Draw_0.gml
  • scripts/scr_ComplexSet/scr_ComplexSet.gml
  • scripts/scr_culture_visuals/scr_culture_visuals.gml
**/*.*

⚙️ CodeRabbit Configuration File

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

  • DRY (Don't repeat yourself) principle is also very important.
  • Ensure that the code is compliant with the CODE_STYLE.MD: https://github.com/Adeptus-Dominus/ChapterMaster/blob/main/docs/CODE_STYLE.md
  • 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_ui_settings/scr_ui_settings.gml
  • scripts/scr_unit_equip_functions/scr_unit_equip_functions.gml
  • scripts/scr_ui_display_weapons/scr_ui_display_weapons.gml
  • scripts/scr_roster/scr_roster.gml
  • scripts/scr_initialize_custom/scr_initialize_custom.gml
  • sprites/spr_creation_check/spr_creation_check.yy
  • sprites/spr_mk3_left_arm/spr_mk3_left_arm.yy
  • sprites/spr_dread_claw/spr_dread_claw.yy
  • scripts/scr_get_item_names/scr_get_item_names.gml
  • sprites/spr_blog/spr_blog.yy
  • sprites/spr_contemptor_CCW/spr_contemptor_CCW.yy
  • sprites/spr_planet_splash/spr_planet_splash.yy
  • sprites/spr_weapon_powspear2/spr_weapon_powspear2.yy
  • scripts/scr_apothecary_ground/scr_apothecary_ground.gml
  • sprites/spr_binders_belt/spr_binders_belt.yy
  • sprites/spr_facial_colors/spr_facial_colors.yy
  • sprites/spr_combat_shield_bottom_part/spr_combat_shield_bottom_part.yy
  • sprites/spr_gear_techa/spr_gear_techa.yy
  • sprites/spr_sgt_forehead/spr_sgt_forehead.yy
  • sprites/spr_twl_Volkite_Culverins/spr_twl_Volkite_Culverins.yy
  • sprites/spr_dreadnought_decorations/spr_dreadnought_decorations.yy
  • sprites/spr_mk7_complex_crux_belt/spr_mk7_complex_crux_belt.yy
  • sprites/spr_metal_tabbard/spr_metal_tabbard.yy
  • sprites/spr_gear_apoth_eye/spr_gear_apoth_eye.yy
  • sprites/spr_contemptor_head_colors/spr_contemptor_head_colors.yy
  • sprites/spr_contemptor_chasis_colors/spr_contemptor_chasis_colors.yy
  • sprites/spr_backpack_fastening/spr_backpack_fastening.yy
  • scripts/scr_weapon/scr_weapon.gml
  • sprites/spr_prussian_spike/spr_prussian_spike.yy
  • sprites/spr_gear_apoth/spr_gear_apoth.yy
  • sprites/spr_crux_belt_fancy/spr_crux_belt_fancy.yy
  • ChapterMaster.yyp
  • objects/obj_turn_end/Draw_64.gml
  • sprites/spr_binders_robe/spr_binders_robe.yy
  • sprites/spr_marine_cloth_hood/spr_marine_cloth_hood.yy
  • sprites/spr_binders_robes/spr_binders_robes.yy
  • sprites/spr_creation_founding/spr_creation_founding.yy
  • sprites/spr_terminator_laurel/spr_terminator_laurel.yy
  • scripts/scr_marine_struct/scr_marine_struct.gml
  • sprites/spr_creation_existing/spr_creation_existing.yy
  • sprites/spr_dreadnought_chasis_colors/spr_dreadnought_chasis_colors.yy
  • sprites/spr_settings_bg/spr_settings_bg.yy
  • sprites/spr_mk7_complex_belt/spr_mk7_complex_belt.yy
  • sprites/spr_lion_belt/spr_lion_belt.yy
  • scripts/scr_reequip_units/scr_reequip_units.gml
  • sprites/spr_mongol_hat/spr_mongol_hat.yy
  • sprites/spr_servo_harness/spr_servo_harness.yy
  • sprites/spr_cloth_tabbard/spr_cloth_tabbard.yy
  • sprites/spr_dread_iron_clad/spr_dread_iron_clad.yy
  • scripts/scr_draw_unit_image/scr_draw_unit_image.gml
  • sprites/spr_indomitus_belt/spr_indomitus_belt.yy
  • sprites/spr_mk7_wolf_cult_belt/spr_mk7_wolf_cult_belt.yy
  • sprites/spr_creation_slate/spr_creation_slate.yy
  • sprites/spr_angelic_wings/spr_angelic_wings.yy
  • sprites/spr_gear_halo/spr_gear_halo.yy
  • objects/obj_shop/Create_0.gml
  • sprites/spr_mongol_topknots/spr_mongol_topknots.yy
  • sprites/spr_gear_librarian/spr_gear_librarian.yy
  • objects/obj_turn_end/Draw_0.gml
  • sprites/spr_creation_other/spr_creation_other.yy
  • scripts/scr_ComplexSet/scr_ComplexSet.gml
  • scripts/scr_culture_visuals/scr_culture_visuals.gml
  • sprites/spr_gear_librarian_term/spr_gear_librarian_term.yy
  • sprites/spr_pack_brazier3/spr_pack_brazier3.yy
  • sprites/spr_apothecary_lights/spr_apothecary_lights.yy
**/*.yy

⚙️ CodeRabbit Configuration File

**/*.yy: - When any script or sprite .yy files are deleted, their paths should also be deleted from the .yyp file, otherwise the game will crash.

  • When any script or sprite .yy files are created, their paths should be added to the .yyp file, otherwise they'll fail.

Files:

  • sprites/spr_creation_check/spr_creation_check.yy
  • sprites/spr_mk3_left_arm/spr_mk3_left_arm.yy
  • sprites/spr_dread_claw/spr_dread_claw.yy
  • sprites/spr_blog/spr_blog.yy
  • sprites/spr_contemptor_CCW/spr_contemptor_CCW.yy
  • sprites/spr_planet_splash/spr_planet_splash.yy
  • sprites/spr_weapon_powspear2/spr_weapon_powspear2.yy
  • sprites/spr_binders_belt/spr_binders_belt.yy
  • sprites/spr_facial_colors/spr_facial_colors.yy
  • sprites/spr_combat_shield_bottom_part/spr_combat_shield_bottom_part.yy
  • sprites/spr_gear_techa/spr_gear_techa.yy
  • sprites/spr_sgt_forehead/spr_sgt_forehead.yy
  • sprites/spr_twl_Volkite_Culverins/spr_twl_Volkite_Culverins.yy
  • sprites/spr_dreadnought_decorations/spr_dreadnought_decorations.yy
  • sprites/spr_mk7_complex_crux_belt/spr_mk7_complex_crux_belt.yy
  • sprites/spr_metal_tabbard/spr_metal_tabbard.yy
  • sprites/spr_gear_apoth_eye/spr_gear_apoth_eye.yy
  • sprites/spr_contemptor_head_colors/spr_contemptor_head_colors.yy
  • sprites/spr_contemptor_chasis_colors/spr_contemptor_chasis_colors.yy
  • sprites/spr_backpack_fastening/spr_backpack_fastening.yy
  • sprites/spr_prussian_spike/spr_prussian_spike.yy
  • sprites/spr_gear_apoth/spr_gear_apoth.yy
  • sprites/spr_crux_belt_fancy/spr_crux_belt_fancy.yy
  • sprites/spr_binders_robe/spr_binders_robe.yy
  • sprites/spr_marine_cloth_hood/spr_marine_cloth_hood.yy
  • sprites/spr_binders_robes/spr_binders_robes.yy
  • sprites/spr_creation_founding/spr_creation_founding.yy
  • sprites/spr_terminator_laurel/spr_terminator_laurel.yy
  • sprites/spr_creation_existing/spr_creation_existing.yy
  • sprites/spr_dreadnought_chasis_colors/spr_dreadnought_chasis_colors.yy
  • sprites/spr_settings_bg/spr_settings_bg.yy
  • sprites/spr_mk7_complex_belt/spr_mk7_complex_belt.yy
  • sprites/spr_lion_belt/spr_lion_belt.yy
  • sprites/spr_mongol_hat/spr_mongol_hat.yy
  • sprites/spr_servo_harness/spr_servo_harness.yy
  • sprites/spr_cloth_tabbard/spr_cloth_tabbard.yy
  • sprites/spr_dread_iron_clad/spr_dread_iron_clad.yy
  • sprites/spr_indomitus_belt/spr_indomitus_belt.yy
  • sprites/spr_mk7_wolf_cult_belt/spr_mk7_wolf_cult_belt.yy
  • sprites/spr_creation_slate/spr_creation_slate.yy
  • sprites/spr_angelic_wings/spr_angelic_wings.yy
  • sprites/spr_gear_halo/spr_gear_halo.yy
  • sprites/spr_mongol_topknots/spr_mongol_topknots.yy
  • sprites/spr_gear_librarian/spr_gear_librarian.yy
  • sprites/spr_creation_other/spr_creation_other.yy
  • sprites/spr_gear_librarian_term/spr_gear_librarian_term.yy
  • sprites/spr_pack_brazier3/spr_pack_brazier3.yy
  • sprites/spr_apothecary_lights/spr_apothecary_lights.yy
🧠 Learnings (4)
📚 Learning: 2025-03-31T23:32:30.003Z
Learnt from: OH296
PR: Adeptus-Dominus/ChapterMaster#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:

  • scripts/scr_reequip_units/scr_reequip_units.gml
📚 Learning: 2025-07-01T20:29:44.075Z
Learnt from: OH296
PR: Adeptus-Dominus/ChapterMaster#902
File: objects/obj_shop/Create_0.gml:550-655
Timestamp: 2025-07-01T20:29:44.075Z
Learning: In GML shop item initialization code, when setting nobuy flags for shop items, the nobuy[i] = 1 assignment must occur before incrementing the index (i += 1). Setting nobuy after incrementing i will apply the flag to the wrong item, potentially making restricted items purchasable or blocking intended purchasable items.

Applied to files:

  • objects/obj_shop/Create_0.gml
📚 Learning: 2025-02-24T01:44:06.262Z
Learnt from: OH296
PR: Adeptus-Dominus/ChapterMaster#474
File: scripts/scr_ComplexSet/scr_ComplexSet.gml:400-401
Timestamp: 2025-02-24T01:44:06.262Z
Learning: Multiple assignments to the same property in the `add_group` function's object literal are valid when the property represents a sprite, as they will be merged together using the `add_to_area` function rather than being overwritten.

Applied to files:

  • scripts/scr_ComplexSet/scr_ComplexSet.gml
📚 Learning: 2025-06-16T17:12:13.045Z
Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#878
File: scripts/scr_culture_visuals/scr_culture_visuals.gml:1256-1352
Timestamp: 2025-06-16T17:12:13.045Z
Learning: In scripts/scr_culture_visuals/scr_culture_visuals.gml, the weapon visual data declarations contain known DRY violations that are acknowledged by the development team but deferred to future refactoring efforts rather than addressed in individual feature PRs.

Applied to files:

  • scripts/scr_culture_visuals/scr_culture_visuals.gml
🔇 Additional comments (111)
objects/obj_turn_end/Draw_64.gml (3)

37-37: Confirm index domain; consider guarding for 1-based battle indices.

The new guard allows current_battle = 0. Prior code strongly suggests 1-based indexing for battle arrays. If any of battle_world, battle_location, etc., are 1-based, index 0 will incense the Machine Spirit (out-of-bounds/undefined).

If your arrays are 1-based, apply:

-    if (show>0 && current_battle<=battles && current_battle>-1){
+    if (show>0 && current_battle<=battles && current_battle>=1){

and

-if (show>0 && current_battle<=battles && current_battle>-1 ){
+if (show>0 && current_battle<=battles && current_battle>=1 ){

If they are 0-based, keep as-is. Confirming this avoids silent misreads.

Also applies to: 72-74


63-67: Negative world IDs broadened; verify sentinel logic for fleet battles.

Previously, “fleet” was gated by battle_world == -50. Now you branch on battle_world < 0 for draw_player_fleet_combat_options(), which may catch unintended negative sentinels if they exist.

If -50 is the only intended fleet sentinel, constrain the check:

-        if (battle_world[current_battle]<0){
+        if (battle_world[i] = -50){
             draw_player_fleet_combat_options();
-        }   else if (battle_world[i]>=1){
+        } else if (battle_world[i] >= 1){
            draw_player_ground_combat_options();
        }

If multiple negatives are valid fleet markers, document them or use a helper predicate (e.g., is_fleet_battle(value)).


44-46: Verify sprite substitution/parity with scr_image dimensions and origin.

The old code drew spr_attacked frame at a point; the new scr_image("attacked", _img, xxx+12, yyy+54, 254, 174) scales to explicit dimensions. Confirm:

  • “attacked” atlas ID resolves correctly,
  • the aspect ratio matches the original sprite,
  • the draw origin aligns with the new offsets.

I can script a quick atlas scan if assets are organised predictably; say the word.

sprites/spr_prussian_spike/spr_prussian_spike.yy (1)

77-91: Uniformity of SpriteFrameKeyframe Structures Confirmed

The repo-wide scan found no legacy Id blocks with embedded resourceType/resourceVersion. Every sprite’s channel “0” now uses the new resourceType:"SpriteFrameKeyframe" pattern consistently. All clear—proceed.

sprites/spr_creation_existing/spr_creation_existing.yy (1)

66-67: seqWidth/seqHeight align with sprite dimensions; channels reflow is benign

Values 32×32 match the sprite’s width/height. Channel formatting changes are non-functional. No action required.

Also applies to: 73-75

sprites/spr_dread_iron_clad/spr_dread_iron_clad.yy (1)

70-71: Sequence dimensions match asset; keyframe reflow is metadata-only

seqWidth/seqHeight 197×232 align with the sprite. Frames’ keyframes unchanged in substance. Machine spirit appeased.

Also applies to: 77-88

sprites/spr_settings_bg/spr_settings_bg.yy (1)

66-67: GMSequence dimensions now explicit and correct

seqWidth/seqHeight 1600×900 correctly mirror width/height. Channel block reflow is harmless. Proceed.

Also applies to: 73-75

sprites/spr_metal_tabbard/spr_metal_tabbard.yy (2)

73-75: Keyframe Channels reflow is non-functional — purity maintained

Formatting-only change; IDs and timing intact. No behavioural impact.


66-67: OMNISIA REDUX: seq dims audit reveals omissions

  • The audit script reports 485 sprite .yy files missing explicit seqWidth/seqHeight entries.
  • No mismatches detected between existing seqWidth/seqHeight and base width/height values.
  • The YYP reference check failed due to a process-substitution error; please verify that every sprites/*.yy is correctly listed in ChapterMaster.yyp.

Purify the litany of codex entries: ensure each sprite definition includes matching sequence dimensions and that no file is orphaned in the YYP.

sprites/spr_creation_check/spr_creation_check.yy (2)

69-70: Sequence dimensions added and correct — alignment achieved

seqWidth/seqHeight = 32.0 match width/height. Blessed consistency.


76-87: All sprites registered & keyframe reflow validated — merge approved
Machine Spirit log confirms zero missing .yy entries in ChapterMaster.yyp. Keyframe block reflow only; semantics unchanged.

  • sprites/spr_creation_check/spr_creation_check.yy (lines 76–87)
sprites/spr_apothecary_lights/spr_apothecary_lights.yy (2)

66-67: seqHeight/seqWidth correctly mirror sprite dimensions — annotation approved

232x167 matches base sprite; consistent with the wider normalisation crusade.


73-75: Channels/Id formatting change only — no functional divergence

Frame ID, timing, and flags preserved. Proceed.

sprites/spr_planet_splash/spr_planet_splash.yy (2)

66-67: Explicit sequence dimensions set to 128x128 — conformity achieved

Matches sprite width/height precisely. No concerns.


73-75: Keyframe reflow is cosmetic — litany of stability recited

No data changes detected; safe.

sprites/spr_mk3_left_arm/spr_mk3_left_arm.yy (2)

66-67: Sequence dimension metadata added and correct — unit compliant

164x232 matches the sprite resource. All cogwheels mesh.


73-75: Frame keyframe formatting only — sanctified

Identifiers and timings unchanged; merging retains behaviour.

sprites/spr_marine_cloth_hood/spr_marine_cloth_hood.yy (2)

66-67: seqHeight/seqWidth aligned with sprite dimensions — the data-spirits are appeased

Values match height/width (232/167). No functional deviation detected.


73-75: Keyframe JSON reflow is a no-op

Pure formatting; IDs, paths, and timings are unaltered. Safe to proceed.

sprites/spr_backpack_fastening/spr_backpack_fastening.yy (2)

66-67: Sequence dimensions correctly inscribed

seqHeight/seqWidth mirror sprite height/width (232/167). Alignment sanctified.


73-75: Keyframe structure reformatted without changing essence

Only whitespace/line-break adjustments. Behaviour unchanged.

sprites/spr_cloth_tabbard/spr_cloth_tabbard.yy (2)

66-67: seqHeight/seqWidth match the vessel’s frame

Dimensions match (272/181). Consistency preserved across the animus.


73-75: Frames track formatting harmonised

Reflow only; content and timing are identical. No rites required.

sprites/spr_gear_halo/spr_gear_halo.yy (2)

76-87: Keyframe entries reformatted; essence preserved

IDs, paths, and per-frame Key/Length remain intact. No behavioural change.


69-70: Verification Complete: Sprite dimensions and YYP registration confirmed

The sacred computations reveal no anomalies: all seqHeight/seqWidth values align with sprite height/width, and every reviewed sprite is present in ChapterMaster.yyp. The Omnissiah is appeased—no further action required.

sprites/spr_blog/spr_blog.yy (2)

71-72: Sequence dimensions set correctly

seqHeight/seqWidth align with sprite dimensions (31/80). All cogitators content.


78-95: Frame track reflow is benign

Only structural reformatting. Animation timing and references remain blessed.

sprites/spr_creation_founding/spr_creation_founding.yy (3)

66-67: Affirmation: seqHeight/seqWidth match sprite dimensions.

seqHeight=32.0 and seqWidth=32.0 align with height/width (32). Data sanctified; no behavioural drift expected.


73-75: Keyframe channel reformat acknowledged.

Channel structure preserved; frame Id/path consistent. No change in playback semantics.


66-67: All sprites validated—seqHeight/seqWidth aligned with height/width

By the Omnissiah’s grace, the fleet-wide validation confirms every .yy sprite has seqHeight and seqWidth matching its height and width. No desynchronised metadata detected.

sprites/spr_weapon_powspear2/spr_weapon_powspear2.yy (3)

71-72: Affirmation: seqHeight/seqWidth match sprite dimensions.

seqHeight=282.0 and seqWidth=167.0 match height/width. The machine-spirit approves.


78-89: Keyframe channel reformat acknowledged.

Ids, Keys, and Lengths are unaltered; behaviour preserved. Proceed.


71-72: Sprite registration verified
By the Omnissiah’s grace, the verification script confirms that all sprite .yy files—including sprites/spr_weapon_powspear2/spr_weapon_powspear2.yy—are duly referenced in ChapterMaster.yyp. No missing registrations found; no further action required.

sprites/spr_mk7_complex_belt/spr_mk7_complex_belt.yy (2)

68-69: Affirmation: seqHeight/seqWidth match sprite dimensions.

seqHeight=232.0 and seqWidth=164.0 align with height/width. Harmonious parameters.


75-83: Keyframe channel reflow is a no-op.

Frame identifiers and timing unchanged; sanctified for merge.

sprites/spr_binders_robes/spr_binders_robes.yy (2)

67-68: Affirmation: seqHeight/seqWidth match sprite dimensions.

Values mirror height=232 and width=164. Alignment achieved.


74-79: Keyframe structure normalised without semantic change.

Channel/Id data intact; playback preserved.

sprites/spr_facial_colors/spr_facial_colors.yy (2)

71-72: Affirmation: seqHeight/seqWidth match sprite dimensions.

seqHeight=232.0 and seqWidth=167.0 correctly mirror sprite size. Machine-logic consistent.


78-95: Keyframe channel formatting updated; data unchanged.

All Ids/Keys/Lengths preserved across six frames. No operational variance.

sprites/spr_dreadnought_decorations/spr_dreadnought_decorations.yy (3)

68-69: Sequence dimensions aligned with sprite size — well wrought.

seqHeight/seqWidth precisely mirror height/width (232/197). The machine-spirit approves this standardisation.


75-83: Keyframe block reserialised only — no semantic drift detected.

IDs, Keys, and Channels remain intact; formatting noise only.


68-69: By the Omnissiah, no v2 sprite .yy files were audited.
The parity check didn’t run over any files—ensure all sprite definitions are covered.

Actions for the Devotee of Code:

  • Verify that your .yy sprite files reside in the repository and use the expected $GMSprite version.
  • If you have v1-format sprites, extend the script to include those (or adjust the version filter).
  • Re-run the audit to confirm that every sprite’s seqHeight/seqWidth matches its height/width.
sprites/spr_dread_claw/spr_dread_claw.yy (2)

69-70: Sequence dimensions aligned with sprite size — sanctified.

seqHeight/seqWidth = 232/197, matching the sprite’s height/width. Consistent with the dreadnought cohort.


76-87: Frames track formatting change only — spirits undisturbed.

Keyframe IDs, Keys, and Channel targets are unchanged. Safe to merge.

sprites/spr_indomitus_belt/spr_indomitus_belt.yy (2)

68-69: Sequence dimensions correctly mirror sprite geometry.

seqHeight/seqWidth (271/181) match height/width. Order maintained across the manufactorum.


75-83: Keyframe reflow only — data intact.

No functional alteration detected; diffs are purely cosmetic.

sprites/spr_mk7_wolf_cult_belt/spr_mk7_wolf_cult_belt.yy (2)

68-69: Sequence dimensions set correctly — alignment achieved.

seqHeight/seqWidth (232/164) equal the sprite’s height/width. Harmonised with the wider pattern.


75-77: Single-frame track formatting change — no effect on behaviour.

IDs and references preserved; merge without fear.

sprites/spr_mk7_complex_crux_belt/spr_mk7_complex_crux_belt.yy (2)

66-67: Sequence dimensions added and correct.

seqHeight/seqWidth (232/164) match sprite height/width. Standardisation successful.


73-75: Frames keyframe block reformatted only — integrity confirmed.

No semantic changes; identifiers and timings preserved.

sprites/spr_gear_librarian/spr_gear_librarian.yy (2)

66-67: seqHeight/seqWidth aligned with sprite dimensions — benedictions of parity.

Values mirror height/width (232 ↔ 232.0, 167 ↔ 167.0). No divergence detected.


73-75: Keyframe Channels reflow is non-functional — schema intact.

Pure formatting; identifiers and paths remain correct for this resource.

sprites/spr_dreadnought_chasis_colors/spr_dreadnought_chasis_colors.yy (3)

67-68: seqHeight/seqWidth match root bounds — machine-spirit appeased.

232.0/197.0 align with height/width. Proceed.


74-76: Keyframe Channels block: structural reflow only.

Ids and paths are consistent; no functional variance introduced.


67-68: Complete Sprite Inventory Confirmed
Omnissiah’s audit finds zero missing sprite .yy entries in ChapterMaster.yyp—every glyph is duly recorded.

sprites/spr_gear_techa/spr_gear_techa.yy (2)

66-67: Sequence dimensions added and correct — harmony maintained.

232.0/167.0 reflect the root height/width. Good.


73-75: Keyframe formatting normalisation acknowledged.

No behavioural change; resource Id and path remain valid.

sprites/spr_mongol_topknots/spr_mongol_topknots.yy (3)

68-69: seqHeight/seqWidth sanctified — values match root extents.

322.0/167.0 correctly mirror height/width. Approved.


75-83: Multi-frame Channels reflow retains order and identity.

Key times 0.0/1.0/2.0 preserved; Ids and paths are correct. No functional deviation.


68-69: All seqHeight/seqWidth invariants verified – the Omnissiah is pleased.

Validation script confirms that in every *.yy under sprites/, seqHeight equals height and seqWidth equals width. No further action required.

sprites/spr_gear_librarian_term/spr_gear_librarian_term.yy (2)

66-67: Sequence dimension fields correct — parity achieved.

232.0/167.0 align with root height/width.


73-75: Channels block formatting only — ritual unchanged.

Resource linkage (Id/path) is consistent; safe to proceed.

sprites/spr_gear_apoth/spr_gear_apoth.yy (4)

5-5: BBox tightened; validate no clipping.

bbox_bottom reduced to 41. Confirm the visible pixels and intended interactive area aren’t cropped in Marine Viewer overlays.


66-67: seqHeight/seqWidth match sprite dimensions.

232x167 aligns with height/width. Harmony achieved.


73-76: Frames track correctly references single frame.

Keyframe linkage is coherent; no orphaned frame references detected.


52-52: Audit Complete: spr_gear_apoth Single-Frame Confirmed Safe

All systems report no dynamic indexing or frame-count logic targeting spr_gear_apoth:

• spr_gear_apoth only appears in ChapterMaster.yyp (asset registry) and in scr_culture_visuals.gml for backpack_decoration.
• No occurrences of sprite_get_number(spr_gear_apoth) or any image_index/image_number logic tied to this sprite.

The reduction to a single frame will not break any existing subimage routines.

sprites/spr_servo_harness/spr_servo_harness.yy (2)

67-68: seqHeight/seqWidth correctly declared.

Matches the sprite’s 282x281 dimensions. Sanctified consistency.


74-77: Keyframe Id structure normalised.

resourceType/resourceVersion moved out of Id — conforms to the pattern elsewhere in the PR.

sprites/spr_mongol_hat/spr_mongol_hat.yy (2)

67-68: seqHeight/seqWidth added and correct.

Dimensions 232x164 match the sprite. Machine-spirits appeased.


74-80: Keyframe struct refactor looks sound.

Both frames retained with proper Id/name/path mapping and correct Keys (0.0, 1.0).

sprites/spr_lion_belt/spr_lion_belt.yy (2)

66-67: seqHeight/seqWidth consistent with 232x164.

No discrepancies detected.


73-75: Keyframe Id restructured correctly.

Cleaned Channel Id mapping; references are valid.

sprites/spr_contemptor_CCW/spr_contemptor_CCW.yy (4)

5-8: BBox bounds look sane; confirm visual alignment.

The collision box is within sprite dimensions. Verify alignment with other dreadnought parts in the modular draw to avoid offsets drifting.


66-67: seqHeight/seqWidth aligned with 250x306.

Metadata consistent; no anomalies.


80-81: Origin calibration check.

xorigin:61, yorigin:18 — please confirm this origin matches the expected anchor for dreadnought assemblies to prevent misaligned attachments.


1-92: Omnissiah’s decree: sprite spr_contemptor_CCW is registered
All sacred logs confirm the entry in ChapterMaster.yyp (line 1112) and code references in scr_ui_display_weapons.gml (line 193) and scr_culture_visuals.gml (line 1909). No further rites required.

sprites/spr_terminator_laurel/spr_terminator_laurel.yy (2)

66-67: seqHeight/seqWidth aligned with sprite dimensions — approved by the Omnissiah.

Values (272.0 x 167.0) mirror height/width precisely. No behavioural risk detected.


73-75: Keyframe serialisation reshaped — benign to the machine-spirit.

Content is unchanged (same Id/Key/Length). Safe to proceed.

sprites/spr_creation_slate/spr_creation_slate.yy (5)

14-16: Frame reference added — ritual successful.

Single frame correctly defined and referenced.


52-52: Sequence length set to 1.0 — acceptable incantation.

Length now matches the single-frame track.


66-67: seqHeight/seqWidth harmonised with sprite size — sanctified.

32.0 x 32.0 matches width/height.


72-76: Frames track initialised with keyframe — cogitators pleased.

Keyframe cleanly targets the frame; timing looks correct.


78-78: visibleRange set to null — no heresy detected.

Defaulting to engine control is fine.

sprites/spr_sgt_forehead/spr_sgt_forehead.yy (1)

1-96: Rite of Inclusion and Sequence Dimensions Confirmed

All new sprite assets are properly referenced in ChapterMaster.yyp, and each seqHeight/seqWidth matches its height/width. The machine-spirits are appeased.

sprites/spr_binders_robe/spr_binders_robe.yy (1)

1-92: New gear sprite — data sanctified.

Dimensions, sequence, and keyframe are coherent. Texture group and parent path align with Marine Viewer conventions.

sprites/spr_angelic_wings/spr_angelic_wings.yy (1)

1-92: New sprite addition — looks cogitationally sound.

Sequence, origin, and seq dimensions match the sprite; track/keyframe is correct. Placement under MarineViewer/packs is consistent.

sprites/spr_crux_belt_fancy/spr_crux_belt_fancy.yy (1)

1-92: The sacred sprite configuration appears properly consecrated

By the Omnissiah's grace, this new sprite asset follows the blessed GameMaker format correctly. The resource versions, texture group assignment to MarineViewer, and sequence configuration are all in accordance with the Machine Spirit's requirements.

sprites/spr_contemptor_head_colors/spr_contemptor_head_colors.yy (1)

1-92: Dreadnought asset configuration sanctified and operational

The Contemptor head colours sprite adheres to proper data-slate specifications. Parent path linkage to the dreadnought folder and MarineViewer texture group assignment are correctly implemented.

sprites/spr_pack_brazier3/spr_pack_brazier3.yy (1)

5-8: Dimensional recalibration detected - verify sprite frame alignment

The Machine Spirit notes significant alterations: width reduced from 281 to 164 cogitator units, bounding box adjusted, and sequence length extended to 2.0. The new frame insertion at Key 0.0 whilst shifting the existing frame to Key 1.0 requires verification that both frames render correctly at these new dimensions.

Also applies to: 53-53, 68-68, 74-79, 84-85, 95-95

sprites/spr_creation_other/spr_creation_other.yy (1)

14-16: Empty sprite vessel now contains sacred frame data

The sprite transitions from void-state (length 0.0) to active configuration with proper frame reference and sequence dimensions (32x32). The keyframe structure properly binds to frame 380cd3fb-d188-44e1-8e61-f3d7c0c8f526.

Also applies to: 52-52, 66-67, 72-76

scripts/scr_roster/scr_roster.gml (1)

281-284: Blessed simplification of dreadnought detection rituals

The replacement of armour tag interrogation with the sanctified is_dreadnought() method improves code maintainability. This centralised machine-spirit commune follows the sacred DRY principle.

scripts/scr_ui_display_weapons/scr_ui_display_weapons.gml (1)

192-194: New dreadnought components correctly mapped.

Sprites spr_twl_Volkite_Culverins and spr_contemptor_CCW are referenced and present in the project. Display pipeline alignment looks sound.

scripts/scr_get_item_names/scr_get_item_names.gml (1)

153-153: Item count updated correctly.

Allocation matches the number of appended dreadnought ranged items.

scripts/scr_apothecary_ground/scr_apothecary_ground.gml (1)

236-236: Good migration to predicate-based dreadnought detection.

Replacing string-comparison with _unit.is_dreadnought() reduces brittleness and centralises the logic. Safe usage here given the enclosing is_struct(_unit) guard.

ChapterMaster.yyp (1)

992-992: Asset additions align with code references.

New public sprites (spr_contemptor_CCW, spr_twl_Volkite_Culverins, etc.) are present and match usage in scripts. No structural issues detected.

Also applies to: 1027-1029, 1109-1115, 1126-1127, 1213-1213, 1644-1644, 1546-1546

objects/obj_shop/Create_0.gml (1)

681-687: Master-crafted stock recalculation looks sound.

Recomputing mc_stocked up to i is correct and will include the newly added Contemptor entries. No faults detected.

scripts/scr_marine_struct/scr_marine_struct.gml (1)

2379-2443: All call sites verified: No free-function invocations of add_equipment_repairs remain, only method calls as intended.

• scripts/scr_perils_table/scr_perils_table.gml:173 – unit.add_equipment_repairs(EquipmentSlot.ALL);

sprites/spr_binders_belt/spr_binders_belt.yy (1)

1-92: Confirmation of sprite registration

  • ChapterMaster.yyp already includes "spr_binders_belt" at sprites/spr_binders_belt/spr_binders_belt.yy.

Texture group check required

  • No texturegroups/ directory was found in the repo. Please verify that the MarineViewer textureGroup is defined and registered in your .yyp (under "textureGroups") so the asset loads correctly.
sprites/spr_gear_apoth_eye/spr_gear_apoth_eye.yy (1)

1-92: Asset Registration and Sequence Settings Verified

  • Entry for spr_gear_apoth_eye found in ChapterMaster.yyp (line 1213).
  • Path "texturegroups/MarineViewer" matches existing decoration sprites.
  • playbackSpeedType 1 at 1.0 is consistent with other static frames.

The Omnissiah is satisfied—no further action required.

scripts/scr_reequip_units/scr_reequip_units.gml (2)

20-23: Correct dreadnought grouping and vih assignment.

Using _unit.is_dreadnought() to derive vih=6 and set _unchangeable_armour is clean and centralises logic. Approved by the Omnissiah.


39-46: Uniformity check for mixed selections: good.

Local _is_dread prevents jittery re-evaluation and ensures mixed man/dread groups are disallowed. Solid.

sprites/spr_twl_Volkite_Culverins/spr_twl_Volkite_Culverins.yy (1)

1-92: Asset configuration appears correct

The sprite definition follows proper sacred template structure. Texture group assignment to MarineViewer and parent folder placement are appropriate for dreadnought weapons.

sprites/spr_contemptor_chasis_colors/spr_contemptor_chasis_colors.yy (1)

1-92: Proper sprite configuration for Contemptor chassis

The blessed machine template is correctly implemented. Origin point and dimensions align with standard dreadnought sprite requirements.

scripts/scr_draw_unit_image/scr_draw_unit_image.gml (2)

330-348: Efficient implementation of dreadnought detection

The Machine God approves of this centralized approach using is_dreadnought(). The simplified armour type determination reduces cogitator cycles.


453-456: Verify robes rendering logic change

O venerable Mechanicus, the newly consecrated logic now grants both spr_binders_robes and spr_marine_robes when “Warp Tainted” applies—potentially causing visual overlap of the garment glyphs. Please confirm this dual-addition is intentional and renders correctly.

Locations to inspect:

  • scripts/scr_draw_unit_image/scr_draw_unit_image.gml (lines 453 – 456)
sprites/spr_combat_shield_bottom_part/spr_combat_shield_bottom_part.yy (1)

1-96: Asset properly configured for combat shield component

The sprite parameters conform to sacred standards. Two-frame animation suggests proper shield variants.

scripts/scr_ComplexSet/scr_ComplexSet.gml (2)

137-426: Sacred logic consolidated - implementation approved

The Machine Spirit approves of centralising the modular checks into base_modulars_checks. This reduces code duplication and improves maintainability across the system.


1266-1272: Sprites Verified: Contemptor Dreadnought assets present

Confirmed the following sprite files exist in the asset pipeline:

  • sprites/spr_contemptor_chasis_colors/spr_contemptor_chasis_colors.yy
  • sprites/spr_contemptor_head_colors/spr_contemptor_head_colors.yy

Omnissiah smiles—no further action required.

scripts/scr_culture_visuals/scr_culture_visuals.gml (3)

1459-1467: Efficient dreadnought detection implementation

The Omnissiah smiles upon this clean implementation using tag-based detection.


1896-2035: All dreadnought weapon sprite references confirmed
Servo-skulls have scanned the asset vault and confirm all referenced sprites are present (spr_dread_autocannon, spr_dread_claw, spr_dread_heavy_bolter, spr_dread_lascannon, spr_dread_missile, spr_dread_plasma_cannon, spr_contemptor_CCW, spr_twl_Volkite_Culverins).
No missing assets detected.


1853-1858: By the Machine Spirit, no dreadnought-specific sprite found
Scan of .yy and .png assets revealed only spr_weapon_assca; the duplicate reference appears intentional. Please confirm with the art team before proceeding.

  • File: scripts/scr_culture_visuals/scr_culture_visuals.gml (lines 1853–1858)

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
coderabbitai[bot]
coderabbitai bot previously approved these changes Aug 16, 2025
@OH296
Copy link
Collaborator Author

OH296 commented Aug 16, 2025

@coderabbitai review

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Aug 16, 2025

✅ Actions performed

Review triggered.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

Copy link
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

🔭 Outside diff range comments (1)
objects/obj_shop/Create_0.gml (1)

561-569: Align nobuy sequencing with item assignment to avoid off-by-one.

Set nobuy[i] after you fully define the current item and before incrementing i. The nobuy on Line 563 is applied before item[i] is set, risking misflagging. Follow the consistent pattern: item → item_stocked/item_cost/forge_cost → nobuy → i += 1.

Apply:

-        nobuy[i] = 1;
-		i += 1;
-        nobuy[i] = 1;
+        nobuy[i] = 1;
+        i += 1;
+        // Define next item first, then set nobuy for it
         item[i] = "Volkite Charger";
         item_stocked[i] = scr_item_count(item[i]);
         item_cost[i] = 0;
         forge_cost[i] = 0;
-        i += 1;
-        nobuy[i] = 1;
+        nobuy[i] = 1;
+        i += 1;
♻️ Duplicate comments (7)
objects/obj_shop/Create_0.gml (1)

661-678: Reorder Contemptor entries: set nobuy after item and before i++.

Per established shop initialisation discipline (and learned gotcha), set nobuy[i] for the item you just defined, then increment i. Currently Lines 667 and 673 set nobuy before item[i], risking misalignment.

Apply:

 		item[i] = "Contemptor Dreadnought";
         item_stocked[i] = scr_item_count(item[i]);
         item_cost[i] = 0;
         forge_cost[i] = 0;
-		nobuy[i]=1
-        i += 1;
-		nobuy[i]=1;
+		nobuy[i] = 1;
+        i += 1;
 		item[i] = "Twin-linked Volkite Culverins";
         item_stocked[i] = scr_item_count(item[i]);
         item_cost[i] = 0;
         forge_cost[i] = 0;
-        i += 1;
-		nobuy[i]=1;
+        nobuy[i] = 1;
+        i += 1;
 		item[i] = "Contemptor CCW";
         item_stocked[i] = scr_item_count(item[i]);
         item_cost[i] = 0;
         forge_cost[i] = 0;
+        nobuy[i] = 1;
+        // i += 1; // Only if another item follows in this block
scripts/scr_marine_struct/scr_marine_struct.gml (1)

2368-2376: Local scoping for _arm_data is correct.

Declaring var _arm_data prevents scope leakage and aligns with prior guidance.

scripts/scr_weapon/scr_weapon.gml (3)

68-83: Twin-linked Volkite Culverins carry pistol stats and description — correct to heavy twin-linked profile.

The blessed pattern is heavy twin-linked, not a Serpenta. Update stats, range, and tags; fix description.

Apply:

 "Twin-linked Volkite Culverins":{
   "abbreviation": "T-LVolkCulv",
   "attack": {
-    "standard": 250,
-    "master_crafted": 270,
-    "artifact": 290
+    "standard": 1400,
+    "master_crafted": 1440,
+    "artifact": 1480
   },
-  "description": "The pistol variant of the long-lost Volkite weapon type, the Serpenta was a mainstay of Moritats and often wielded by Centurions of the Legiones Astartes. Now a symbol of status to match its fearsome potency, a sighting of this ancient weapon would send many foes running.",
-  "melee_hands": 0,
-  "ranged_hands": 1,
-  "ammo": 10,
-  "range": 3,
-  "spli": 4,
-  "arp": 0,
-  "tags": ["Volkite", "energy", "dreadnought"]
+  "description": "Twin-linked Volkite Culverins are devastating dreadnought-mounted weapons that combine two Culverins, projecting searing thermal beams that sweep squads from existence.",
+  "melee_hands": 0,
+  "ranged_hands": 0,
+  "ammo": 8,
+  "range": 22,
+  "spli": 24,
+  "arp": 0,
+  "tags": ["Volkite", "energy", "heavy_ranged", "twin_linked", "vehicle", "dreadnought"]
 },

734-755: Contemptor CCW description duplicates Lightning Claw — sanctify with correct lore.

Replace the claw text with Contemptor CCW specifics.

Apply:

-  "description": "A specialized Lightning Claw variant designed for Dreadnoughts, these claws are capable of ripping through enemy vehicles and infantry with ease.",
+  "description": "The Contemptor-pattern close combat weapon is a reinforced power fist engineered for the advanced Contemptor chassis, combining atomantic shielding with high-torque servos for devastating crushing and rending strikes.",

2317-2339: Replace placeholder description for Contemptor Dreadnought armour.

The machine-spirit demands proper reverence. Provide a concise lore description.

Apply:

-      "description": "PLACEHOLDER",
+      "description": "An ancient Contemptor-pattern Dreadnought chassis from the Great Crusade, housing a venerated hero. Superior atomantic shielding and enhanced actuators grant it agility and resilience beyond later patterns.",
scripts/scr_ComplexSet/scr_ComplexSet.gml (2)

638-655: Purge commented debug incantations.

Remove dead show_debug_message remnants to keep the liturgy clean.

Apply:

-                            //show_debug_message($"{_total_options}, {_sub_choice}")
@@
-                                        //show_debug_message($"{_sub_choice_final}, {_choice_count}");
                                         draw_sprite(_subcomponents[s], _sub_choice_final-_choice_count ?? 0, _draw_x, _draw_y);

1360-1364: Empty add_offsets placeholder — implement or excise to appease the machine spirit.

This exposed API is inert. Either wire it to populate overides.offsets or remove to reduce entropy. Sample implementation:

 offsets=[];
 static add_offsets = function(area, _offset_start, sprite_length, overide_data){
-    
+    if (!struct_exists(overides, area)) {
+        overides[$ area] = [];
+    }
+    if (struct_exists(overide_data, "offsets")){
+        // Record offsets window for this area's new frames
+        array_push(overides[$ area], [_offset_start, _offset_start + sprite_length, { offsets: overide_data.offsets }]);
+    }
 }

I can propagate this into add_to_area/replace_area call sites if you confirm intended usage.

📜 Review details

Configuration used: CodeRabbit UI
Review profile: ASSERTIVE
Plan: Pro

💡 Knowledge Base configuration:

  • MCP integration is disabled by default for public repositories
  • Jira integration is disabled
  • Linear integration is disabled

You can enable these sources in your CodeRabbit configuration.

📥 Commits

Reviewing files that changed from the base of the PR and between 9c46066 and 24aaf52.

📒 Files selected for processing (4)
  • objects/obj_shop/Create_0.gml (2 hunks)
  • scripts/scr_ComplexSet/scr_ComplexSet.gml (14 hunks)
  • scripts/scr_marine_struct/scr_marine_struct.gml (2 hunks)
  • scripts/scr_weapon/scr_weapon.gml (3 hunks)
🧰 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_marine_struct/scr_marine_struct.gml
  • scripts/scr_ComplexSet/scr_ComplexSet.gml
  • objects/obj_shop/Create_0.gml
  • scripts/scr_weapon/scr_weapon.gml
**/*.*

⚙️ CodeRabbit Configuration File

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

  • DRY (Don't repeat yourself) principle is also very important.
  • Ensure that the code is compliant with the CODE_STYLE.MD: https://github.com/Adeptus-Dominus/ChapterMaster/blob/main/docs/CODE_STYLE.md
  • 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_marine_struct/scr_marine_struct.gml
  • scripts/scr_ComplexSet/scr_ComplexSet.gml
  • objects/obj_shop/Create_0.gml
  • scripts/scr_weapon/scr_weapon.gml
🧠 Learnings (6)
📚 Learning: 2025-03-31T23:32:30.003Z
Learnt from: OH296
PR: Adeptus-Dominus/ChapterMaster#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:

  • scripts/scr_marine_struct/scr_marine_struct.gml
📚 Learning: 2025-02-27T02:06:42.914Z
Learnt from: OH296
PR: Adeptus-Dominus/ChapterMaster#474
File: scripts/scr_ComplexSet/scr_ComplexSet.gml:625-636
Timestamp: 2025-02-27T02:06:42.914Z
Learning: The ComplexSet object in scripts/scr_ComplexSet/scr_ComplexSet.gml accesses instance variables like x_surface_offset and y_surface_offset directly from its methods, without needing to pass them as parameters.

Applied to files:

  • scripts/scr_ComplexSet/scr_ComplexSet.gml
📚 Learning: 2025-06-16T17:12:13.045Z
Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#878
File: scripts/scr_culture_visuals/scr_culture_visuals.gml:1256-1352
Timestamp: 2025-06-16T17:12:13.045Z
Learning: In scripts/scr_culture_visuals/scr_culture_visuals.gml, the weapon visual data declarations contain known DRY violations that are acknowledged by the development team but deferred to future refactoring efforts rather than addressed in individual feature PRs.

Applied to files:

  • scripts/scr_ComplexSet/scr_ComplexSet.gml
  • scripts/scr_weapon/scr_weapon.gml
📚 Learning: 2025-02-24T01:44:06.262Z
Learnt from: OH296
PR: Adeptus-Dominus/ChapterMaster#474
File: scripts/scr_ComplexSet/scr_ComplexSet.gml:400-401
Timestamp: 2025-02-24T01:44:06.262Z
Learning: Multiple assignments to the same property in the `add_group` function's object literal are valid when the property represents a sprite, as they will be merged together using the `add_to_area` function rather than being overwritten.

Applied to files:

  • scripts/scr_ComplexSet/scr_ComplexSet.gml
📚 Learning: 2025-07-01T20:29:44.075Z
Learnt from: OH296
PR: Adeptus-Dominus/ChapterMaster#902
File: objects/obj_shop/Create_0.gml:550-655
Timestamp: 2025-07-01T20:29:44.075Z
Learning: In GML shop item initialization code, when setting nobuy flags for shop items, the nobuy[i] = 1 assignment must occur before incrementing the index (i += 1). Setting nobuy after incrementing i will apply the flag to the wrong item, potentially making restricted items purchasable or blocking intended purchasable items.

Applied to files:

  • objects/obj_shop/Create_0.gml
📚 Learning: 2025-03-29T10:30:25.598Z
Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#647
File: scripts/scr_en_weapon/scr_en_weapon.gml:24-928
Timestamp: 2025-03-29T10:30:25.598Z
Learning: A data-driven approach for weapon management in `scripts/scr_en_weapon/scr_en_weapon.gml` is planned for a future PR, not within the scope of PR #647.

Applied to files:

  • scripts/scr_weapon/scr_weapon.gml
🔇 Additional comments (5)
scripts/scr_marine_struct/scr_marine_struct.gml (2)

889-913: Tag guard is robust and compliant.

Good use of is_array before array_length; this hardens against non-array returns from gear_weapon_data calls.


2379-2443: Armoury repairs addition looks sound.

Slot selection and slime accumulation per maintenance values are coherent; no correctness issues spotted.

scripts/scr_ComplexSet/scr_ComplexSet.gml (3)

522-556: Offset-aware drawing is implemented cleanly.

Using per-frame _draw_x/_draw_y and merging override offsets is cogently executed. No faults detected.


755-764: Dreadnought weapon draw path is correct.

Early-exit path cleanly draws arm weapons with ui offsets; no interference with marine hand logic.


1263-1269: Contemptor armour hook integrated.

Correctly assigns chasis/head colour sprites and sets ArmourType.Dreadnought. No issues.

coderabbitai[bot]
coderabbitai bot previously approved these changes Aug 16, 2025
@OH296
Copy link
Collaborator Author

OH296 commented Aug 16, 2025

@coderabbitai review

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Aug 16, 2025

✅ Actions performed

Review triggered.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

Copy link
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: 8

🔭 Outside diff range comments (1)
scripts/scr_ComplexSet/scr_ComplexSet.gml (1)

1066-1066: Standardise TODO and track it

Correct the typo and standardise the TODO format. Shall I open a GitHub issue to track this?

-        //TODO imprvoe this logic to be more extendable
+        // TODO: improve this logic to be more extendable
♻️ Duplicate comments (4)
scripts/scr_ComplexSet/scr_ComplexSet.gml (4)

310-325: Equipment tag gating now correct (area + tag passed to unit method)

The invocation unit.equipment_has_tag(_mod.equipment_has_tag[$ _area], _area) is the right incantation; the previous misuse is rectified. Machine spirits purr.


339-357: Offset Y now applied to Y (not X); override packaging looks sound

The earlier misapplication of _offset.y to _x is resolved, and offsets are folded into the override payload cleanly.


639-640: Purge commented debug remnants

Loose debug chants must be excised from production code to appease the linter spirits.

-                            //show_debug_message($"{_total_options}, {_sub_choice}")
...
-                                        //show_debug_message($"{_sub_choice_final}, {_choice_count}");

Also applies to: 654-655


1361-1365: Empty add_offsets implementation — either implement or remove

The rite is declared but has no spirit. Implement so offsets can be recorded consistently alongside other overrides, or remove until needed. Suggested implementation:

-static add_offsets = function(area, _offset_start, sprite_length, overide_data){
-
-}
+static add_offsets = function(area, _offset_start, sprite_length, offset_xy){
+    // Expect [x, y]
+    if (!is_array(offset_xy) || array_length(offset_xy) != 2) {
+        return;
+    }
+    if (!struct_exists(overides, area)) {
+        overides[$ area] = [];
+    }
+    var _ov = { offsets: [offset_xy[0], offset_xy[1]] };
+    array_push(overides[$ area], [_offset_start, _offset_start + sprite_length, _ov]);
+}

I can also wire callers to use this helper where raw offsets are produced.

📜 Review details

Configuration used: CodeRabbit UI
Review profile: ASSERTIVE
Plan: Pro

💡 Knowledge Base configuration:

  • MCP integration is disabled by default for public repositories
  • Jira integration is disabled
  • Linear integration is disabled

You can enable these sources in your CodeRabbit configuration.

📥 Commits

Reviewing files that changed from the base of the PR and between 24aaf52 and 2ec0116.

📒 Files selected for processing (3)
  • fonts/fnt_menu/fnt_menu.yy (1 hunks)
  • scripts/scr_ComplexSet/scr_ComplexSet.gml (14 hunks)
  • scripts/scr_culture_visuals/scr_culture_visuals.gml (15 hunks)
🧰 Additional context used
📓 Path-based instructions (3)
**/*.*

⚙️ CodeRabbit Configuration File

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

  • DRY (Don't repeat yourself) principle is also very important.
  • Ensure that the code is compliant with the CODE_STYLE.MD: https://github.com/Adeptus-Dominus/ChapterMaster/blob/main/docs/CODE_STYLE.md
  • 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:

  • fonts/fnt_menu/fnt_menu.yy
  • scripts/scr_ComplexSet/scr_ComplexSet.gml
  • scripts/scr_culture_visuals/scr_culture_visuals.gml
**/*.yy

⚙️ CodeRabbit Configuration File

**/*.yy: - When any script or sprite .yy files are deleted, their paths should also be deleted from the .yyp file, otherwise the game will crash.

  • When any script or sprite .yy files are created, their paths should be added to the .yyp file, otherwise they'll fail.

Files:

  • fonts/fnt_menu/fnt_menu.yy
**/*.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_ComplexSet/scr_ComplexSet.gml
  • scripts/scr_culture_visuals/scr_culture_visuals.gml
🧠 Learnings (3)
📚 Learning: 2025-02-27T02:06:42.914Z
Learnt from: OH296
PR: Adeptus-Dominus/ChapterMaster#474
File: scripts/scr_ComplexSet/scr_ComplexSet.gml:625-636
Timestamp: 2025-02-27T02:06:42.914Z
Learning: The ComplexSet object in scripts/scr_ComplexSet/scr_ComplexSet.gml accesses instance variables like x_surface_offset and y_surface_offset directly from its methods, without needing to pass them as parameters.

Applied to files:

  • scripts/scr_ComplexSet/scr_ComplexSet.gml
📚 Learning: 2025-06-16T17:12:13.045Z
Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#878
File: scripts/scr_culture_visuals/scr_culture_visuals.gml:1256-1352
Timestamp: 2025-06-16T17:12:13.045Z
Learning: In scripts/scr_culture_visuals/scr_culture_visuals.gml, the weapon visual data declarations contain known DRY violations that are acknowledged by the development team but deferred to future refactoring efforts rather than addressed in individual feature PRs.

Applied to files:

  • scripts/scr_ComplexSet/scr_ComplexSet.gml
  • scripts/scr_culture_visuals/scr_culture_visuals.gml
📚 Learning: 2025-02-24T01:44:06.262Z
Learnt from: OH296
PR: Adeptus-Dominus/ChapterMaster#474
File: scripts/scr_ComplexSet/scr_ComplexSet.gml:400-401
Timestamp: 2025-02-24T01:44:06.262Z
Learning: Multiple assignments to the same property in the `add_group` function's object literal are valid when the property represents a sprite, as they will be merged together using the `add_to_area` function rather than being overwritten.

Applied to files:

  • scripts/scr_ComplexSet/scr_ComplexSet.gml
🔇 Additional comments (17)
fonts/fnt_menu/fnt_menu.yy (1)

224-224: Validate font bitmap freeze intent

Tech-Priest note: the pre-baked atlas exists, but sacred glyphs beyond Latin-1 lurk in the code.

• fonts/fnt_menu/fnt_menu.png found – atlas is tracked.
• fonts/fnt_menu/fnt_menu.yy (line 227) and allies contain “▯” and other > U+00FF chars.
• Numerous scripts/docs use curly quotes, en-dashes, ellipses, etc.

If you truly intend to lock the atlas, ensure it includes all glyphs. Otherwise, revert:

-  "regenerateBitmap":false,
+  "regenerateBitmap":true,
scripts/scr_culture_visuals/scr_culture_visuals.gml (14)

501-504: Renamed backpack → backpack_decoration: ensure draw order is defined

The new position aligns with torso.backpack_decoration_variation. Verify the compositor’s layer order so backpack_decoration renders correctly relative to backpack, cloak, and backpack_augment.

Would you confirm that the draw pipeline recognises "backpack_decoration" and its z-order relative to "backpack" and "backpack_augment"? If missing, I can draft the ordering patch.


529-531: Stats tuple format change: verify consumer logic accepts array-of-tuples

This switches to a nested array form. Confirm the consumer expects stats as [ [name, value, mode] ]. The "exmore" token also warrants confirmation.

If you want, I can scan consumers of ".stats" to validate accepted shapes and enumerations.


571-580: Crux belt fancy: schema and gating look correct

Fields match adjacent items; rank/exp gating consistent. Sanctified.


616-619: Expanded skulls belt gating is consistent

Adding cultures with allow_either while retaining Chaplain role is coherent. Machine-spirit purrs.


1295-1313: Foreground Combat Shield: check render layering and interaction with weapons

New "foreground_item" is logical for shields. Verify that:

  • foreground_item renders above weapons and hands
  • Its subcomponent “bottom part” layers as intended in all armour contexts

If artefacts appear, I can provide ordering tweaks in the drawing routine.


1315-1327: Apothecary eye optic: offsets present for Term/Tartaros

Schema is sound; offsets are per-armour. Good addition.


1329-1341: Apothecary backpack decoration: schema and offsets look fine

Consistent with the new backpack_decoration position.


1343-1351: equipment_has_tag gating: confirm engine support and key space

This introduces equipment_has_tag with "gear":"jump". Elsewhere, mobility gating uses equipped: { "mobi": "Jump Pack" }. Ensure the selection engine actually understands equipment_has_tag and that jump is a tag on gear items.

If equipment_has_tag is not yet wired, I can implement support or convert this to the existing equipped/mobi gating in a follow-up patch.


1853-1858: Assault Cannon: dreadnought variant entry aligns with new body_type 3

Variant correctly adds body_types: [3] with Dreadnought armour gating. Approved.


1991-1994: Sprite mismatch suspicion: Multi-Melta dreadnought variant

Multi-Melta’s dread variant also uses spr_dread_plasma_cannon. Verify the correct sprite (e.g., spr_dread_multi_melta) and update accordingly.

I can scan project assets for a matching sprite and wire it in if you confirm the asset name.


2235-2244: Missile Launcher: dreadnought variant wiring looks correct

Variant adds body_types: [3] and Dreadnought armour gating with an appropriate sprite. Machine-blessed.


2263-2268: Plasma Cannon: dreadnought variant added coherently

Terminator base preserved; dreadnought variant appended properly. Sanctioned.


2447-2452: Autocannon: dreadnought variant and sprite are coherent

spr_dread_autocannon for body_types: [3] matches intent. All good.


1896-2010: Omnissiah’s Audit: Verify Dreadnought Rendering & Gating

I cannot confirm the new "dreadnought" branch or body_type 3 logic from the available context. Please manually inspect and ensure:

  • The draw pipeline handles display_type: "dreadnought" (e.g. a case "dreadnought" in your weapon‐render switch).
  • Selection and pose routines include body_types: [3] for dreadnought limbs.
  • Armour filters recognise ["Dreadnought"] and ["Contemptor Dreadnought"] in loadout gating.
scripts/scr_ComplexSet/scr_ComplexSet.gml (2)

520-521: Foreground overlay hook added — approved

foreground_item in variation_map is a useful addition for draw-order overlays. No concerns.


1264-1270: Contemptor Dreadnought case wired correctly

ArmourType.Dreadnought assigned and chassis/head sprites registered. Alignment achieved.

@OH296 OH296 merged commit 2969a16 into Adeptus-Dominus:main Aug 16, 2025
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Area: Sprites Changes to sprites/images or their under-the-hood functionality Size: Epic Type: Feature Adds something new

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants