Skip to content

feat: Refactor and improve all obj_popup visuals and logics#943

Merged
OH296 merged 15 commits intoAdeptus-Dominus:mainfrom
OH296:improve_raaider_mission
Jul 23, 2025
Merged

feat: Refactor and improve all obj_popup visuals and logics#943
OH296 merged 15 commits intoAdeptus-Dominus:mainfrom
OH296:improve_raaider_mission

Conversation

@OH296
Copy link
Copy Markdown
Collaborator

@OH296 OH296 commented Jul 23, 2025

Purpose and Description

  • Self-descriptive.
  • also improve protect raiders by adding more outcomes based on squad chosen
  • add bonus to natural leaders in train forces mission
  • rewrite equipping artifacts to be less of an aids fest
  • rewrite the drawing of, transfer, promotion, and equipping and a heft amount of the logic as well

Testing done

  • Just a metric shit load of clicking things

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: Warning Type: Feature Adds something new labels Jul 23, 2025
@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai bot commented Jul 23, 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 popups for gifting items, promoting units, re-equipping units, and transferring marines, providing dedicated UI for these actions.
  • Introduced new UI screens for the Armamentarium and Librarium, including artifact management and STC fragment handling.
  • Enabled batch equipment management and improved artifact equipping with dedicated popups and validation.
  • Added support for gifting artifacts and STC fragments to factions, with dynamic effects on diplomacy.

Improvements

  • Refined promotion, equipment, and transfer workflows for smoother unit management.
  • Enhanced drawing and tooltip consistency across UI elements.
  • Improved handling of squad and company assignments, with clearer role and equipment requirements.

Bug Fixes

  • Corrected unit selection and equipment slot indexing for improved accuracy.
  • Fixed conditional checks and logic in battle and equipment management.

Refactor

  • Modularised and streamlined UI logic for popups and management screens.
  • Replaced manual drawing state management with stack-based functions for reliability.

Style

  • Improved formatting and code structure for better maintainability.

Chores

  • Added new script resources for gifting, promotion, re-equipping, and transferring functionalities.

Walkthrough

By the Omnissiah's will, this update enacts a comprehensive refactor and expansion of the unit management, equipment, promotion, transfer, and gifting systems. Old popup logic is excised, replaced by modular scripts for promotion, equipment reallocation, marine transfer, and item gifting, each with dedicated UI and logic. Drawing state is now managed via stack-based functions. Numerous scripts and resources are added or updated to support these new processes, with corresponding UI and logic changes throughout.

Changes

Files / Groups Change Summary
ChapterMaster.yyp, scripts/scr_gift_items/scr_gift_items.yy, scripts/scr_promote/scr_promote.yy,
scripts/scr_reequip_units/scr_reequip_units.yy, scripts/scr_transfer_marines/scr_transfer_marines.yy
Added new script resources for gifting, promotion, reequipping, and transfer popups.
objects/obj_popup/Draw_0.gml, objects/obj_popup/Mouse_50.gml, objects/obj_popup/Step_0.gml,
objects/obj_popup/Create_0.gml
Removed legacy popup logic for promotion, equipment, transfer, and gifting; refactored or replaced with new modular scripts.
objects/obj_popup/Draw_64.gml Added conditional logic to delegate popup drawing to new modular functions based on popup type.
objects/obj_popup/obj_popup.yy Registered new draw event for popup object.
scripts/scr_gift_items/scr_gift_items.gml Implemented gifting system for artifacts and STC fragments, with UI, logic, and faction-specific effects.
scripts/scr_promote/scr_promote.gml Implemented promotion popup system, including UI, logic, and role/equipment validation.
scripts/scr_reequip_units/scr_reequip_units.gml Implemented reequipment popup system for batch unit/vehicle equipment changes, with validation and UI.
scripts/scr_transfer_marines/scr_transfer_marines.gml Implemented marine/vehicle transfer popup system, with squad handling, UI, and validation.
scripts/scr_buttons/scr_buttons.gml, objects/obj_tooltip/Draw_75.gml, objects/obj_controller/Draw_64.gml Refactored drawing state management to stack-based functions; updated UI drawing logic accordingly.
scripts/scr_draw_armentarium/scr_draw_armentarium.gml, scripts/scr_librarium/scr_librarium.gml Refactored Armentarium and Librarium UI logic to use new modular functions and improved button handling.
scripts/scr_add_artifact/scr_add_artifact.gml Added artifact equipping logic, popup setup/draw functions, and improved artifact handling.
scripts/scr_draw_text/scr_draw_text.gml Added text scaling utility for dynamic UI fitting.
scripts/scr_company_struct/scr_company_struct.gml Refactored squad selection mode to a static function; updated button logic.
scripts/scr_manage_task_selector/scr_manage_task_selector.gml Refined task management, added artifact equip handling, improved company logic.
scripts/scr_draw_management_unit/scr_draw_management_unit.gml Added click lock parameter to control unit selection interactivity.
scripts/scr_get_item_names/scr_get_item_names.gml, scripts/scr_marine_struct/scr_marine_struct.gml Standardised equipment slot indexing and enum order.
scripts/scr_unit_quick_find_pane/scr_unit_quick_find_pane.gml Removed legacy equip/transfer selection logic.
scripts/scr_popup_functions/scr_popup_functions.gml Added popup type enum, equipment need calculator, and default image index function.
scripts/is_specialist/is_specialist.gml, scripts/scr_special_view/scr_special_view.gml Refined group/specialist selection logic and management.
scripts/scr_company_order/scr_company_order.gml Improved squadless unit handling with controllable check.
scripts/scr_mission_functions/scr_mission_functions.gml, scripts/scr_pen_And_paper/scr_pen_And_paper.gml,
scripts/scr_squads/scr_squads.gml
Added new mission logic, stat averaging utilities, and trait handling.
scripts/scr_controller_helpers/scr_controller_helpers.gml Added artifact slate UI setup in Librarium toggle.
scripts/scr_ui_diplomacy/scr_ui_diplomacy.gml Adjusted exit logic for artifact and STC thank-you events.
scripts/scr_diplomacy_helpers/scr_diplomacy_helpers.gml Enhanced disposition logic for gifting with faction/advantage checks.
scripts/scr_ui_manage/scr_ui_manage.gml Updated manage UI to use new popup systems and refined selection logic.
sprites/spr_pixel_button_left/spr_pixel_button_left.yy, sprites/spr_pixel_button_right/spr_pixel_button_right.yy Updated sprite resources with new frames, sequence dimensions, and formatting.
scripts/scr_draw_planet_features/scr_draw_planet_features.gml Minor formatting change in struct property assignment.
scripts/scr_DataSlate/scr_DataSlate.gml Improved DataSlate/UIButton drawing with state stack and alignment fixes.
objects/obj_dropdown_sel/Draw_0.gml Switched artifact description retrieval to function-based approach.
objects/obj_ncombat/Alarm_7.gml Corrected conditional logic and improved battle special handling.

Estimated code review effort

🎯 5 (Critical) | ⏱️ ~90+ minutes
Complexity: Extensive refactor and feature addition; high file count; major UI, logic, and resource changes; critical review required for correctness and integration.

Possibly related PRs

Suggested labels

PR: Refactor, PR: Feature, Size: Huge, Area: UI

Suggested reviewers

  • OH296

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.
    • Explain this complex logic.
    • 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. Examples:
    • @coderabbitai explain this code block.
    • @coderabbitai modularize this function.
  • 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 src/utils.ts and explain its main purpose.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Support

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

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

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

Documentation and Community

  • 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.

@OH296 OH296 requested a review from EttyKitty July 23, 2025 19:09
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: 37

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

145-204: Stack corruption imminent - unreachable cleanup detected.

The pop_draw_return_values() call on line 203 is unreachable due to return statements. This will cause drawing state stack imbalance.

Move the cleanup before any return statements:

 	static draw = function(allow_click = true){
 		add_draw_return_values();
+		var _result = false;
 		if (style = "standard"){
 			// ... existing code ...
 		}
 		// ... existing code ...
 		if (allow_click){
 			var clicked = point_and_click(_button_click_area) || keystroke;
 			if (clicked){
 				if (is_callable(bind_method)){
 					// ... existing code ...
 				}
 			}
-			return clicked
+			_result = clicked;
 		} else {
-			return false;
+			_result = false;
 		}
-		pop_draw_return_values();	
+		pop_draw_return_values();
+		return _result;
 	}
scripts/scr_librarium/scr_librarium.gml (1)

144-354: The machine-spirit functions, though its form sprawls excessively.

This rendering subroutine operates within acceptable parameters, though its 210-line length suggests future modularization would honor the Omnissiah.

Consider fragmenting this behemoth into smaller, dedicated sub-functions for improved maintainability.

scripts/scr_add_artifact/scr_add_artifact.gml (1)

589-611: The refactoring pleases the Machine God, but formatting protocols must be observed.

Line 603: Add space after comma per sacred code style protocols.

-                        alter_deep_array(obj_ini.veh_chaos,_unit, _val) 
+                        alter_deep_array(obj_ini.veh_chaos, _unit, _val) 
♻️ Duplicate comments (3)
ChapterMaster.yyp (3)

880-886: Same verification applies to scr_promote

See previous comment; identical risk and remedy.


889-893: Same verification applies to scr_reequip_units

See first comment; identical risk and remedy.


929-933: Same verification applies to scr_transfer_marines

See first comment; identical risk and remedy.

📜 Review details

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

📥 Commits

Reviewing files that changed from the base of the PR and between 0c733e0 and d1a4f95.

⛔ Files ignored due to path filters (4)
  • sprites/spr_pixel_button_right/531933e7-b10e-42c4-96fd-7b6aaf423b29.png is excluded by !**/*.png
  • sprites/spr_pixel_button_right/7dc4c8c2-7af4-42fa-8949-052b7fe7a314.png is excluded by !**/*.png
  • sprites/spr_pixel_button_right/layers/531933e7-b10e-42c4-96fd-7b6aaf423b29/a3934012-92f7-4b26-ba15-b4043a5867b4.png is excluded by !**/*.png
  • sprites/spr_pixel_button_right/layers/7dc4c8c2-7af4-42fa-8949-052b7fe7a314/a3934012-92f7-4b26-ba15-b4043a5867b4.png is excluded by !**/*.png
📒 Files selected for processing (45)
  • ChapterMaster.yyp (4 hunks)
  • objects/obj_controller/Draw_64.gml (4 hunks)
  • objects/obj_dropdown_sel/Draw_0.gml (2 hunks)
  • objects/obj_ncombat/Alarm_7.gml (1 hunks)
  • objects/obj_popup/Create_0.gml (7 hunks)
  • objects/obj_popup/Draw_0.gml (3 hunks)
  • objects/obj_popup/Draw_64.gml (1 hunks)
  • objects/obj_popup/Mouse_50.gml (1 hunks)
  • objects/obj_popup/Step_0.gml (3 hunks)
  • objects/obj_popup/obj_popup.yy (1 hunks)
  • objects/obj_tooltip/Draw_75.gml (3 hunks)
  • scripts/is_specialist/is_specialist.gml (3 hunks)
  • scripts/scr_DataSlate/scr_DataSlate.gml (7 hunks)
  • scripts/scr_add_artifact/scr_add_artifact.gml (4 hunks)
  • scripts/scr_buttons/scr_buttons.gml (17 hunks)
  • scripts/scr_company_order/scr_company_order.gml (1 hunks)
  • scripts/scr_company_struct/scr_company_struct.gml (2 hunks)
  • scripts/scr_controller_helpers/scr_controller_helpers.gml (1 hunks)
  • scripts/scr_diplomacy_helpers/scr_diplomacy_helpers.gml (1 hunks)
  • scripts/scr_draw_armentarium/scr_draw_armentarium.gml (3 hunks)
  • scripts/scr_draw_management_unit/scr_draw_management_unit.gml (2 hunks)
  • scripts/scr_draw_planet_features/scr_draw_planet_features.gml (1 hunks)
  • scripts/scr_draw_text/scr_draw_text.gml (1 hunks)
  • scripts/scr_get_item_names/scr_get_item_names.gml (14 hunks)
  • scripts/scr_gift_items/scr_gift_items.gml (1 hunks)
  • scripts/scr_gift_items/scr_gift_items.yy (1 hunks)
  • scripts/scr_librarium/scr_librarium.gml (1 hunks)
  • scripts/scr_manage_task_selector/scr_manage_task_selector.gml (7 hunks)
  • scripts/scr_marine_struct/scr_marine_struct.gml (1 hunks)
  • scripts/scr_mission_functions/scr_mission_functions.gml (2 hunks)
  • scripts/scr_pen_And_paper/scr_pen_And_paper.gml (2 hunks)
  • scripts/scr_popup_functions/scr_popup_functions.gml (1 hunks)
  • scripts/scr_promote/scr_promote.gml (1 hunks)
  • scripts/scr_promote/scr_promote.yy (1 hunks)
  • scripts/scr_reequip_units/scr_reequip_units.gml (1 hunks)
  • scripts/scr_reequip_units/scr_reequip_units.yy (1 hunks)
  • scripts/scr_special_view/scr_special_view.gml (4 hunks)
  • scripts/scr_squads/scr_squads.gml (1 hunks)
  • scripts/scr_transfer_marines/scr_transfer_marines.gml (1 hunks)
  • scripts/scr_transfer_marines/scr_transfer_marines.yy (1 hunks)
  • scripts/scr_ui_diplomacy/scr_ui_diplomacy.gml (1 hunks)
  • scripts/scr_ui_manage/scr_ui_manage.gml (10 hunks)
  • scripts/scr_unit_quick_find_pane/scr_unit_quick_find_pane.gml (1 hunks)
  • sprites/spr_pixel_button_left/spr_pixel_button_left.yy (1 hunks)
  • sprites/spr_pixel_button_right/spr_pixel_button_right.yy (3 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:

  • objects/obj_dropdown_sel/Draw_0.gml
  • scripts/scr_company_order/scr_company_order.gml
  • scripts/scr_marine_struct/scr_marine_struct.gml
  • scripts/scr_squads/scr_squads.gml
  • scripts/scr_draw_text/scr_draw_text.gml
  • scripts/scr_pen_And_paper/scr_pen_And_paper.gml
  • scripts/scr_diplomacy_helpers/scr_diplomacy_helpers.gml
  • objects/obj_popup/Draw_64.gml
  • objects/obj_controller/Draw_64.gml
  • objects/obj_tooltip/Draw_75.gml
  • objects/obj_popup/Create_0.gml
  • objects/obj_popup/Step_0.gml
  • scripts/is_specialist/is_specialist.gml
  • scripts/scr_draw_armentarium/scr_draw_armentarium.gml
  • scripts/scr_company_struct/scr_company_struct.gml
  • scripts/scr_ui_diplomacy/scr_ui_diplomacy.gml
  • objects/obj_ncombat/Alarm_7.gml
  • scripts/scr_draw_planet_features/scr_draw_planet_features.gml
  • scripts/scr_mission_functions/scr_mission_functions.gml
  • scripts/scr_transfer_marines/scr_transfer_marines.gml
  • scripts/scr_controller_helpers/scr_controller_helpers.gml
  • scripts/scr_unit_quick_find_pane/scr_unit_quick_find_pane.gml
  • scripts/scr_promote/scr_promote.gml
  • objects/obj_popup/Mouse_50.gml
  • scripts/scr_draw_management_unit/scr_draw_management_unit.gml
  • scripts/scr_special_view/scr_special_view.gml
  • scripts/scr_librarium/scr_librarium.gml
  • objects/obj_popup/Draw_0.gml
  • scripts/scr_get_item_names/scr_get_item_names.gml
  • scripts/scr_gift_items/scr_gift_items.gml
  • scripts/scr_popup_functions/scr_popup_functions.gml
  • scripts/scr_DataSlate/scr_DataSlate.gml
  • scripts/scr_ui_manage/scr_ui_manage.gml
  • scripts/scr_buttons/scr_buttons.gml
  • scripts/scr_manage_task_selector/scr_manage_task_selector.gml
  • scripts/scr_reequip_units/scr_reequip_units.gml
  • scripts/scr_add_artifact/scr_add_artifact.gml
**/*.*

⚙️ CodeRabbit Configuration File

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

Files:

  • objects/obj_dropdown_sel/Draw_0.gml
  • objects/obj_popup/obj_popup.yy
  • scripts/scr_transfer_marines/scr_transfer_marines.yy
  • scripts/scr_gift_items/scr_gift_items.yy
  • scripts/scr_reequip_units/scr_reequip_units.yy
  • scripts/scr_promote/scr_promote.yy
  • scripts/scr_company_order/scr_company_order.gml
  • scripts/scr_marine_struct/scr_marine_struct.gml
  • scripts/scr_squads/scr_squads.gml
  • scripts/scr_draw_text/scr_draw_text.gml
  • scripts/scr_pen_And_paper/scr_pen_And_paper.gml
  • scripts/scr_diplomacy_helpers/scr_diplomacy_helpers.gml
  • objects/obj_popup/Draw_64.gml
  • sprites/spr_pixel_button_left/spr_pixel_button_left.yy
  • objects/obj_controller/Draw_64.gml
  • objects/obj_tooltip/Draw_75.gml
  • objects/obj_popup/Create_0.gml
  • sprites/spr_pixel_button_right/spr_pixel_button_right.yy
  • objects/obj_popup/Step_0.gml
  • scripts/is_specialist/is_specialist.gml
  • scripts/scr_draw_armentarium/scr_draw_armentarium.gml
  • scripts/scr_company_struct/scr_company_struct.gml
  • scripts/scr_ui_diplomacy/scr_ui_diplomacy.gml
  • objects/obj_ncombat/Alarm_7.gml
  • scripts/scr_draw_planet_features/scr_draw_planet_features.gml
  • scripts/scr_mission_functions/scr_mission_functions.gml
  • scripts/scr_transfer_marines/scr_transfer_marines.gml
  • scripts/scr_controller_helpers/scr_controller_helpers.gml
  • scripts/scr_unit_quick_find_pane/scr_unit_quick_find_pane.gml
  • scripts/scr_promote/scr_promote.gml
  • objects/obj_popup/Mouse_50.gml
  • ChapterMaster.yyp
  • scripts/scr_draw_management_unit/scr_draw_management_unit.gml
  • scripts/scr_special_view/scr_special_view.gml
  • scripts/scr_librarium/scr_librarium.gml
  • objects/obj_popup/Draw_0.gml
  • scripts/scr_get_item_names/scr_get_item_names.gml
  • scripts/scr_gift_items/scr_gift_items.gml
  • scripts/scr_popup_functions/scr_popup_functions.gml
  • scripts/scr_DataSlate/scr_DataSlate.gml
  • scripts/scr_ui_manage/scr_ui_manage.gml
  • scripts/scr_buttons/scr_buttons.gml
  • scripts/scr_manage_task_selector/scr_manage_task_selector.gml
  • scripts/scr_reequip_units/scr_reequip_units.gml
  • scripts/scr_add_artifact/scr_add_artifact.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:

  • objects/obj_popup/obj_popup.yy
  • scripts/scr_transfer_marines/scr_transfer_marines.yy
  • scripts/scr_gift_items/scr_gift_items.yy
  • scripts/scr_reequip_units/scr_reequip_units.yy
  • scripts/scr_promote/scr_promote.yy
  • sprites/spr_pixel_button_left/spr_pixel_button_left.yy
  • sprites/spr_pixel_button_right/spr_pixel_button_right.yy
🧠 Learnings (42)
📓 Common learnings
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.
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.
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.
Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-03-20T22:22:57.319Z
Learning: In the ChapterMaster game PR #424, the combat log was expanded to display up to 24 messages instead of 8, providing more detailed battle information.
Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-05T20:54:45.813Z
Learning: EttyKitty requested a rework of the vehicle and marine recovery system in ChapterMaster. The current system allows guaranteed recovery with enough recovery points, while the proposed system would use random chance modified by techmarine skill and item bonuses.
Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#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.
Learnt from: MCPO-Spartan-117
PR: Adeptus-Dominus/ChapterMaster#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
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-05T20:58:21.881Z
Learning: In the ChapterMaster game, there's a need to refactor hardcoded item effects and move them to a "specials" property of items, following the pattern established with the `combi_tool` special. This improves code maintainability and makes effects more explicit in item definitions.
Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-05T20:58:21.881Z
Learning: In the ChapterMaster game, there's a need to refactor hardcoded item effects and move them to a "specials" property of items, following the pattern established with the `combi_tool` special. This improves code maintainability and makes effects more explicit in item definitions.
Learnt from: MCPO-Spartan-117
PR: Adeptus-Dominus/ChapterMaster#562
File: scripts/scr_marine_struct/scr_marine_struct.gml:0-0
Timestamp: 2025-03-07T01:56:40.971Z
Learning: Marines' ages should be incremented at the year transition in obj_turn_end/Alarm_1.gml rather than calculated dynamically based on the current year and recruitment date. This ensures proper aging without retroactive application.
Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-03-20T22:22:57.319Z
Learning: In the ChapterMaster game PR #424, the "Psyker Abundance" advantage was renamed to "Warp Touched", "Daemon Binders" advantage was removed, and "Warp Touched" disadvantage was renamed to "Warp Tainted".
objects/obj_dropdown_sel/Draw_0.gml (5)

Learnt from: MCPO-Spartan-117
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
PR: #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.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-05T20:58:21.881Z
Learning: In the ChapterMaster game, there's a need to refactor hardcoded item effects and move them to a "specials" property of items, following the pattern established with the combi_tool special. This improves code maintainability and makes effects more explicit in item definitions.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-05T20:58:21.881Z
Learning: In the ChapterMaster game, there's a need to refactor hardcoded item effects and move them to a "specials" property of items, following the pattern established with the combi_tool special. This improves code maintainability and makes effects more explicit in item definitions.

scripts/scr_transfer_marines/scr_transfer_marines.yy (2)

Learnt from: MCPO-Spartan-117
PR: #562
File: scripts/scr_marine_struct/scr_marine_struct.gml:0-0
Timestamp: 2025-03-07T01:56:40.971Z
Learning: Marines' ages should be incremented at the year transition in obj_turn_end/Alarm_1.gml rather than calculated dynamically based on the current year and recruitment date. This ensures proper aging without retroactive application.

Learnt from: EttyKitty
PR: #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.

scripts/scr_gift_items/scr_gift_items.yy (3)

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: #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.

scripts/scr_reequip_units/scr_reequip_units.yy (3)

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: #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.

scripts/scr_promote/scr_promote.yy (4)

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: #424
File: scripts/scr_powers/scr_powers.gml:683-683
Timestamp: 2025-03-02T16:11:10.155Z
Learning: For GameMaker Language code, use triple-slash comments (///) with @function, @description, @param, and @returns tags to document functions properly. Include parameter types in curly braces, describe return values, and mention any side effects.

scripts/scr_company_order/scr_company_order.gml (6)

Learnt from: VanWeapon
PR: #725
File: scripts/scr_special_view/scr_special_view.gml:49-49
Timestamp: 2025-04-15T10:54:19.720Z
Learning: In the ChapterMaster codebase, obj_ini.role[100][2] and obj_ini.role[100][eROLE.ChapterMaster] reference different roles, and both are needed in conditions checking for specific types of units. Numeric indices should not be assumed to match their corresponding enum values without verification.

Learnt from: OH296
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.

Learnt from: MCPO-Spartan-117
PR: #562
File: scripts/scr_marine_struct/scr_marine_struct.gml:0-0
Timestamp: 2025-03-07T01:56:40.971Z
Learning: Marines' ages should be incremented at the year transition in obj_turn_end/Alarm_1.gml rather than calculated dynamically based on the current year and recruitment date. This ensures proper aging without retroactive application.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: #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.

scripts/scr_marine_struct/scr_marine_struct.gml (5)

Learnt from: EttyKitty
PR: #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.

Learnt from: MCPO-Spartan-117
PR: #562
File: scripts/scr_marine_struct/scr_marine_struct.gml:0-0
Timestamp: 2025-03-07T01:56:40.971Z
Learning: Marines' ages should be incremented at the year transition in obj_turn_end/Alarm_1.gml rather than calculated dynamically based on the current year and recruitment date. This ensures proper aging without retroactive application.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: #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.

Learnt from: OH296
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.

scripts/scr_pen_And_paper/scr_pen_And_paper.gml (1)

Learnt from: EttyKitty
PR: #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.

scripts/scr_diplomacy_helpers/scr_diplomacy_helpers.gml (5)

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-03-20T22:22:57.319Z
Learning: In the ChapterMaster game PR #424, the "Psyker Abundance" advantage was renamed to "Warp Touched", "Daemon Binders" advantage was removed, and "Warp Touched" disadvantage was renamed to "Warp Tainted".

Learnt from: MCPO-Spartan-117
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
PR: #649
File: objects/obj_enunit/Alarm_0.gml:289-291
Timestamp: 2025-03-31T15:41:45.611Z
Learning: GameMaker Studio's function action_if_variable(image_index, -500, 0) is auto-generated code from GameMaker's visual Drag and Drop system. It checks if image_index equals -500. In ChapterMaster, this was being used as a special flag for enemy unit movement, but wasn't triggering consistently, causing enemies to move only every other turn. The refactored code replaced this with direct function calls at specific combat stages.

Learnt from: VanWeapon
PR: #725
File: scripts/scr_initialize_custom/scr_initialize_custom.gml:956-959
Timestamp: 2025-04-15T11:07:33.927Z
Learning: Negative vehicle counts (like rhino -= 2 potentially resulting in negative values) are acceptable in the scr_initialize_custom function, particularly when handling chapter advantages like "Lightning Warriors". This is intentional behavior in the game's design.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#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.

objects/obj_popup/Draw_64.gml (6)

Learnt from: EttyKitty
PR: #649
File: objects/obj_enunit/Alarm_0.gml:289-291
Timestamp: 2025-03-31T15:41:45.611Z
Learning: GameMaker Studio's function action_if_variable(image_index, -500, 0) is auto-generated code from GameMaker's visual Drag and Drop system. It checks if image_index equals -500. In ChapterMaster, this was being used as a special flag for enemy unit movement, but wasn't triggering consistently, causing enemies to move only every other turn. The refactored code replaced this with direct function calls at specific combat stages.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-16T09:51:55.065Z
Learning: In obj_ingame_menu/Step_0.gml, the line "if (effect=14){instance_create(0,0,obj_fade);fading=0.1;}" must not be commented out, as it's critical for menu button transitions. When clicking the Exit button, it sets effect=14, but without this handler creating the fade effect object, no transition occurs.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-05T20:58:21.881Z
Learning: In the ChapterMaster game, there's a need to refactor hardcoded item effects and move them to a "specials" property of items, following the pattern established with the combi_tool special. This improves code maintainability and makes effects more explicit in item definitions.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-05T20:58:21.881Z
Learning: In the ChapterMaster game, there's a need to refactor hardcoded item effects and move them to a "specials" property of items, following the pattern established with the combi_tool special. This improves code maintainability and makes effects more explicit in item definitions.

sprites/spr_pixel_button_left/spr_pixel_button_left.yy (2)

Learnt from: OH296
PR: #474
File: sprites/spr_marksmans_honor/spr_marksmans_honor.yy:47-52
Timestamp: 2025-02-27T02:17:54.527Z
Learning: The sprite "spr_marksmans_honor" is not used for animation despite having multiple frames - these frames represent different static states used in different contexts.

Learnt from: EttyKitty
PR: #474
File: sprites/spr_bionic_right_arm/spr_bionic_right_arm.yy:52-53
Timestamp: 2025-02-24T17:43:59.846Z
Learning: In the ChapterMaster codebase, sprite files with multiple frames are often used as separate sprites rather than animations, making playback speed settings irrelevant.

objects/obj_controller/Draw_64.gml (5)

Learnt from: MCPO-Spartan-117
PR: #504
File: scripts/scr_draw_management_unit/scr_draw_management_unit.gml:168-171
Timestamp: 2025-02-23T07:50:48.327Z
Learning: In the ChapterMaster codebase, when coordinates are modified after a drawing operation but before being stored in tooltips, it may be intentional for proper tooltip alignment. Such modifications should not be flagged unless there's clear evidence of unintended behavior.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-16T09:51:55.065Z
Learning: In obj_ingame_menu/Step_0.gml, the line "if (effect=14){instance_create(0,0,obj_fade);fading=0.1;}" must not be commented out, as it's critical for menu button transitions. When clicking the Exit button, it sets effect=14, but without this handler creating the fade effect object, no transition occurs.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-18T13:33:54.167Z
Learning: In obj_new_button/Step_0.gml, when using scr_click_left() for detecting clicks on menu buttons, it should be called with parameter 0 (scr_click_left(0)) to disable the default cooldown of 60 steps. Using the default cooldown can cause menu buttons to appear unresponsive since it prevents subsequent clicks from being detected.

objects/obj_tooltip/Draw_75.gml (1)

Learnt from: MCPO-Spartan-117
PR: #504
File: scripts/scr_draw_management_unit/scr_draw_management_unit.gml:168-171
Timestamp: 2025-02-23T07:50:48.327Z
Learning: In the ChapterMaster codebase, when coordinates are modified after a drawing operation but before being stored in tooltips, it may be intentional for proper tooltip alignment. Such modifications should not be flagged unless there's clear evidence of unintended behavior.

objects/obj_popup/Create_0.gml (13)

Learnt from: OH296
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.

Learnt from: MCPO-Spartan-117
PR: #562
File: scripts/scr_marine_struct/scr_marine_struct.gml:0-0
Timestamp: 2025-03-07T01:56:40.971Z
Learning: Marines' ages should be incremented at the year transition in obj_turn_end/Alarm_1.gml rather than calculated dynamically based on the current year and recruitment date. This ensures proper aging without retroactive application.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-16T09:51:55.065Z
Learning: In obj_ingame_menu/Step_0.gml, the line "if (effect=14){instance_create(0,0,obj_fade);fading=0.1;}" must not be commented out, as it's critical for menu button transitions. When clicking the Exit button, it sets effect=14, but without this handler creating the fade effect object, no transition occurs.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: #649
File: objects/obj_enunit/Alarm_0.gml:289-291
Timestamp: 2025-03-31T15:41:45.611Z
Learning: GameMaker Studio's function action_if_variable(image_index, -500, 0) is auto-generated code from GameMaker's visual Drag and Drop system. It checks if image_index equals -500. In ChapterMaster, this was being used as a special flag for enemy unit movement, but wasn't triggering consistently, causing enemies to move only every other turn. The refactored code replaced this with direct function calls at specific combat stages.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-05T20:58:21.881Z
Learning: In the ChapterMaster game, there's a need to refactor hardcoded item effects and move them to a "specials" property of items, following the pattern established with the combi_tool special. This improves code maintainability and makes effects more explicit in item definitions.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-05T20:58:21.881Z
Learning: In the ChapterMaster game, there's a need to refactor hardcoded item effects and move them to a "specials" property of items, following the pattern established with the combi_tool special. This improves code maintainability and makes effects more explicit in item definitions.

Learnt from: VanWeapon
PR: #725
File: scripts/scr_special_view/scr_special_view.gml:49-49
Timestamp: 2025-04-15T10:54:19.720Z
Learning: In the ChapterMaster codebase, obj_ini.role[100][2] and obj_ini.role[100][eROLE.ChapterMaster] reference different roles, and both are needed in conditions checking for specific types of units. Numeric indices should not be assumed to match their corresponding enum values without verification.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-05T20:54:45.813Z
Learning: EttyKitty requested a rework of the vehicle and marine recovery system in ChapterMaster. The current system allows guaranteed recovery with enough recovery points, while the proposed system would use random chance modified by techmarine skill and item bonuses.

Learnt from: VanWeapon
PR: #725
File: scripts/scr_initialize_custom/scr_initialize_custom.gml:956-959
Timestamp: 2025-04-15T11:07:33.927Z
Learning: Negative vehicle counts (like rhino -= 2 potentially resulting in negative values) are acceptable in the scr_initialize_custom function, particularly when handling chapter advantages like "Lightning Warriors". This is intentional behavior in the game's design.

Learnt from: EttyKitty
PR: #579
File: objects/obj_enunit/Alarm_0.gml:186-187
Timestamp: 2025-03-11T01:34:29.268Z
Learning: In the ChapterMaster game, the variable _column_size_value represents the physical size/mass of a column of units, calculated as (vehicles * 2.5) + (dreadnoughts * 2) + (men * 0.5), and is used for determining back row protection rules.

sprites/spr_pixel_button_right/spr_pixel_button_right.yy (2)

Learnt from: OH296
PR: #474
File: sprites/spr_marksmans_honor/spr_marksmans_honor.yy:47-52
Timestamp: 2025-02-27T02:17:54.527Z
Learning: The sprite "spr_marksmans_honor" is not used for animation despite having multiple frames - these frames represent different static states used in different contexts.

Learnt from: EttyKitty
PR: #474
File: sprites/spr_bionic_right_arm/spr_bionic_right_arm.yy:52-53
Timestamp: 2025-02-24T17:43:59.846Z
Learning: In the ChapterMaster codebase, sprite files with multiple frames are often used as separate sprites rather than animations, making playback speed settings irrelevant.

objects/obj_popup/Step_0.gml (11)

Learnt from: MCPO-Spartan-117
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
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-16T09:51:55.065Z
Learning: In obj_ingame_menu/Step_0.gml, the line "if (effect=14){instance_create(0,0,obj_fade);fading=0.1;}" must not be commented out, as it's critical for menu button transitions. When clicking the Exit button, it sets effect=14, but without this handler creating the fade effect object, no transition occurs.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-05T20:58:21.881Z
Learning: In the ChapterMaster game, there's a need to refactor hardcoded item effects and move them to a "specials" property of items, following the pattern established with the combi_tool special. This improves code maintainability and makes effects more explicit in item definitions.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-05T20:58:21.881Z
Learning: In the ChapterMaster game, there's a need to refactor hardcoded item effects and move them to a "specials" property of items, following the pattern established with the combi_tool special. This improves code maintainability and makes effects more explicit in item definitions.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#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.

Learnt from: EttyKitty
PR: #649
File: objects/obj_enunit/Alarm_0.gml:289-291
Timestamp: 2025-03-31T15:41:45.611Z
Learning: GameMaker Studio's function action_if_variable(image_index, -500, 0) is auto-generated code from GameMaker's visual Drag and Drop system. It checks if image_index equals -500. In ChapterMaster, this was being used as a special flag for enemy unit movement, but wasn't triggering consistently, causing enemies to move only every other turn. The refactored code replaced this with direct function calls at specific combat stages.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: #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.

Learnt from: MCPO-Spartan-117
PR: #554
File: objects/obj_popup/Step_0.gml:756-767
Timestamp: 2025-03-06T16:02:06.286Z
Learning: The variable 'woopwoopwoop' in ancient ruins exploration code is a poorly named boolean flag that controls the flow between detecting a battle in ruins and initiating the combat sequence.

Learnt from: VanWeapon
PR: #725
File: scripts/scr_special_view/scr_special_view.gml:49-49
Timestamp: 2025-04-15T10:54:19.720Z
Learning: In the ChapterMaster codebase, obj_ini.role[100][2] and obj_ini.role[100][eROLE.ChapterMaster] reference different roles, and both are needed in conditions checking for specific types of units. Numeric indices should not be assumed to match their corresponding enum values without verification.

scripts/is_specialist/is_specialist.gml (3)

Learnt from: OH296
PR: #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.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-16T09:51:55.065Z
Learning: In obj_ingame_menu/Step_0.gml, the line "if (effect=14){instance_create(0,0,obj_fade);fading=0.1;}" must not be commented out, as it's critical for menu button transitions. When clicking the Exit button, it sets effect=14, but without this handler creating the fade effect object, no transition occurs.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-18T13:33:54.167Z
Learning: In obj_new_button/Step_0.gml, when using scr_click_left() for detecting clicks on menu buttons, it should be called with parameter 0 (scr_click_left(0)) to disable the default cooldown of 60 steps. Using the default cooldown can cause menu buttons to appear unresponsive since it prevents subsequent clicks from being detected.

scripts/scr_draw_armentarium/scr_draw_armentarium.gml (7)

Learnt from: MCPO-Spartan-117
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
PR: #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.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-18T13:33:54.167Z
Learning: In obj_new_button/Step_0.gml, when using scr_click_left() for detecting clicks on menu buttons, it should be called with parameter 0 (scr_click_left(0)) to disable the default cooldown of 60 steps. Using the default cooldown can cause menu buttons to appear unresponsive since it prevents subsequent clicks from being detected.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-05T20:58:21.881Z
Learning: In the ChapterMaster game, there's a need to refactor hardcoded item effects and move them to a "specials" property of items, following the pattern established with the combi_tool special. This improves code maintainability and makes effects more explicit in item definitions.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-05T20:58:21.881Z
Learning: In the ChapterMaster game, there's a need to refactor hardcoded item effects and move them to a "specials" property of items, following the pattern established with the combi_tool special. This improves code maintainability and makes effects more explicit in item definitions.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-16T09:51:55.065Z
Learning: In obj_ingame_menu/Step_0.gml, the line "if (effect=14){instance_create(0,0,obj_fade);fading=0.1;}" must not be commented out, as it's critical for menu button transitions. When clicking the Exit button, it sets effect=14, but without this handler creating the fade effect object, no transition occurs.

scripts/scr_company_struct/scr_company_struct.gml (5)

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-18T13:33:54.167Z
Learning: In obj_new_button/Step_0.gml, when using scr_click_left() for detecting clicks on menu buttons, it should be called with parameter 0 (scr_click_left(0)) to disable the default cooldown of 60 steps. Using the default cooldown can cause menu buttons to appear unresponsive since it prevents subsequent clicks from being detected.

Learnt from: EttyKitty
PR: #649
File: objects/obj_enunit/Alarm_0.gml:289-291
Timestamp: 2025-03-31T15:41:45.611Z
Learning: GameMaker Studio's function action_if_variable(image_index, -500, 0) is auto-generated code from GameMaker's visual Drag and Drop system. It checks if image_index equals -500. In ChapterMaster, this was being used as a special flag for enemy unit movement, but wasn't triggering consistently, causing enemies to move only every other turn. The refactored code replaced this with direct function calls at specific combat stages.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-16T09:51:55.065Z
Learning: In obj_ingame_menu/Step_0.gml, the line "if (effect=14){instance_create(0,0,obj_fade);fading=0.1;}" must not be commented out, as it's critical for menu button transitions. When clicking the Exit button, it sets effect=14, but without this handler creating the fade effect object, no transition occurs.

scripts/scr_ui_diplomacy/scr_ui_diplomacy.gml (2)

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-16T09:51:55.065Z
Learning: In obj_ingame_menu/Step_0.gml, the line "if (effect=14){instance_create(0,0,obj_fade);fading=0.1;}" must not be commented out, as it's critical for menu button transitions. When clicking the Exit button, it sets effect=14, but without this handler creating the fade effect object, no transition occurs.

Learnt from: MCPO-Spartan-117
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.

objects/obj_ncombat/Alarm_7.gml (6)

Learnt from: MCPO-Spartan-117
PR: #562
File: scripts/scr_marine_struct/scr_marine_struct.gml:0-0
Timestamp: 2025-03-07T01:56:40.971Z
Learning: Marines' ages should be incremented at the year transition in obj_turn_end/Alarm_1.gml rather than calculated dynamically based on the current year and recruitment date. This ensures proper aging without retroactive application.

Learnt from: OH296
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.

Learnt from: EttyKitty
PR: #649
File: objects/obj_enunit/Alarm_0.gml:289-291
Timestamp: 2025-03-31T15:41:45.611Z
Learning: GameMaker Studio's function action_if_variable(image_index, -500, 0) is auto-generated code from GameMaker's visual Drag and Drop system. It checks if image_index equals -500. In ChapterMaster, this was being used as a special flag for enemy unit movement, but wasn't triggering consistently, causing enemies to move only every other turn. The refactored code replaced this with direct function calls at specific combat stages.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-05T20:58:21.881Z
Learning: In the ChapterMaster game, there's a need to refactor hardcoded item effects and move them to a "specials" property of items, following the pattern established with the combi_tool special. This improves code maintainability and makes effects more explicit in item definitions.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-05T20:58:21.881Z
Learning: In the ChapterMaster game, there's a need to refactor hardcoded item effects and move them to a "specials" property of items, following the pattern established with the combi_tool special. This improves code maintainability and makes effects more explicit in item definitions.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-16T09:51:55.065Z
Learning: In obj_ingame_menu/Step_0.gml, the line "if (effect=14){instance_create(0,0,obj_fade);fading=0.1;}" must not be commented out, as it's critical for menu button transitions. When clicking the Exit button, it sets effect=14, but without this handler creating the fade effect object, no transition occurs.

scripts/scr_draw_planet_features/scr_draw_planet_features.gml (2)

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: #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.

scripts/scr_mission_functions/scr_mission_functions.gml (3)

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#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.

Learnt from: MCPO-Spartan-117
PR: #562
File: scripts/scr_marine_struct/scr_marine_struct.gml:0-0
Timestamp: 2025-03-07T01:56:40.971Z
Learning: Marines' ages should be incremented at the year transition in obj_turn_end/Alarm_1.gml rather than calculated dynamically based on the current year and recruitment date. This ensures proper aging without retroactive application.

Learnt from: VanWeapon
PR: #725
File: scripts/scr_special_view/scr_special_view.gml:49-49
Timestamp: 2025-04-15T10:54:19.720Z
Learning: In the ChapterMaster codebase, obj_ini.role[100][2] and obj_ini.role[100][eROLE.ChapterMaster] reference different roles, and both are needed in conditions checking for specific types of units. Numeric indices should not be assumed to match their corresponding enum values without verification.

scripts/scr_transfer_marines/scr_transfer_marines.gml (3)

Learnt from: MCPO-Spartan-117
PR: #562
File: scripts/scr_marine_struct/scr_marine_struct.gml:0-0
Timestamp: 2025-03-07T01:56:40.971Z
Learning: Marines' ages should be incremented at the year transition in obj_turn_end/Alarm_1.gml rather than calculated dynamically based on the current year and recruitment date. This ensures proper aging without retroactive application.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-16T09:51:55.065Z
Learning: In obj_ingame_menu/Step_0.gml, the line "if (effect=14){instance_create(0,0,obj_fade);fading=0.1;}" must not be commented out, as it's critical for menu button transitions. When clicking the Exit button, it sets effect=14, but without this handler creating the fade effect object, no transition occurs.

scripts/scr_controller_helpers/scr_controller_helpers.gml (2)

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: #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.

scripts/scr_unit_quick_find_pane/scr_unit_quick_find_pane.gml (6)

Learnt from: EttyKitty
PR: #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.

Learnt from: OH296
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.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-16T09:51:55.065Z
Learning: In obj_ingame_menu/Step_0.gml, the line "if (effect=14){instance_create(0,0,obj_fade);fading=0.1;}" must not be commented out, as it's critical for menu button transitions. When clicking the Exit button, it sets effect=14, but without this handler creating the fade effect object, no transition occurs.

Learnt from: MCPO-Spartan-117
PR: #562
File: scripts/scr_marine_struct/scr_marine_struct.gml:0-0
Timestamp: 2025-03-07T01:56:40.971Z
Learning: Marines' ages should be incremented at the year transition in obj_turn_end/Alarm_1.gml rather than calculated dynamically based on the current year and recruitment date. This ensures proper aging without retroactive application.

scripts/scr_promote/scr_promote.gml (3)

Learnt from: EttyKitty
PR: #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.

Learnt from: MCPO-Spartan-117
PR: #562
File: scripts/scr_marine_struct/scr_marine_struct.gml:0-0
Timestamp: 2025-03-07T01:56:40.971Z
Learning: Marines' ages should be incremented at the year transition in obj_turn_end/Alarm_1.gml rather than calculated dynamically based on the current year and recruitment date. This ensures proper aging without retroactive application.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-16T09:51:55.065Z
Learning: In obj_ingame_menu/Step_0.gml, the line "if (effect=14){instance_create(0,0,obj_fade);fading=0.1;}" must not be commented out, as it's critical for menu button transitions. When clicking the Exit button, it sets effect=14, but without this handler creating the fade effect object, no transition occurs.

objects/obj_popup/Mouse_50.gml (8)

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-16T09:51:55.065Z
Learning: In obj_ingame_menu/Step_0.gml, the line "if (effect=14){instance_create(0,0,obj_fade);fading=0.1;}" must not be commented out, as it's critical for menu button transitions. When clicking the Exit button, it sets effect=14, but without this handler creating the fade effect object, no transition occurs.

Learnt from: EttyKitty
PR: #649
File: objects/obj_enunit/Alarm_0.gml:289-291
Timestamp: 2025-03-31T15:41:45.611Z
Learning: GameMaker Studio's function action_if_variable(image_index, -500, 0) is auto-generated code from GameMaker's visual Drag and Drop system. It checks if image_index equals -500. In ChapterMaster, this was being used as a special flag for enemy unit movement, but wasn't triggering consistently, causing enemies to move only every other turn. The refactored code replaced this with direct function calls at specific combat stages.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-18T13:33:54.167Z
Learning: In obj_new_button/Step_0.gml, when using scr_click_left() for detecting clicks on menu buttons, it should be called with parameter 0 (scr_click_left(0)) to disable the default cooldown of 60 steps. Using the default cooldown can cause menu buttons to appear unresponsive since it prevents subsequent clicks from being detected.

Learnt from: MCPO-Spartan-117
PR: #562
File: scripts/scr_marine_struct/scr_marine_struct.gml:0-0
Timestamp: 2025-03-07T01:56:40.971Z
Learning: Marines' ages should be incremented at the year transition in obj_turn_end/Alarm_1.gml rather than calculated dynamically based on the current year and recruitment date. This ensures proper aging without retroactive application.

Learnt from: EttyKitty
PR: #649
File: objects/obj_enunit/Alarm_0.gml:289-291
Timestamp: 2025-03-31T15:41:45.611Z
Learning: GameMaker Studio's function action_if_variable(image_index, -500, 0) was part of an old enemy movement system in ChapterMaster. This syntax is auto-generated from GameMaker's Drag-and-Drop interface and checks if image_index is greater than or equal to -500. In the refactored code, enemy movement is triggered directly through function calls rather than relying on this conditional check.

ChapterMaster.yyp (6)

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-05T20:58:21.881Z
Learning: In the ChapterMaster game, there's a need to refactor hardcoded item effects and move them to a "specials" property of items, following the pattern established with the combi_tool special. This improves code maintainability and makes effects more explicit in item definitions.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-05T20:58:21.881Z
Learning: In the ChapterMaster game, there's a need to refactor hardcoded item effects and move them to a "specials" property of items, following the pattern established with the combi_tool special. This improves code maintainability and makes effects more explicit in item definitions.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-03-20T22:22:57.319Z
Learning: In the ChapterMaster game PR #424, the combat log was expanded to display up to 24 messages instead of 8, providing more detailed battle information.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#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.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-03-20T22:22:57.319Z
Learning: In the ChapterMaster game PR #424, the "Psyker Abundance" advantage was renamed to "Warp Touched", "Daemon Binders" advantage was removed, and "Warp Touched" disadvantage was renamed to "Warp Tainted".

scripts/scr_draw_management_unit/scr_draw_management_unit.gml (3)

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-18T13:33:54.167Z
Learning: In obj_new_button/Step_0.gml, when using scr_click_left() for detecting clicks on menu buttons, it should be called with parameter 0 (scr_click_left(0)) to disable the default cooldown of 60 steps. Using the default cooldown can cause menu buttons to appear unresponsive since it prevents subsequent clicks from being detected.

Learnt from: EttyKitty
PR: #734
File: objects/obj_creation/Draw_0.gml:765-771
Timestamp: 2025-04-18T19:18:34.387Z
Learning: When refactoring mouse input in ChapterMaster, prefer using the point_and_click([x1, y1, x2, y2]) function rather than scr_click_left(0) for UI elements. Setting a cooldown of 0 is problematic as it removes click protection, whereas point_and_click() uses a default cooldown of 60 and combines rectangle bounds checking with click detection.

Learnt from: EttyKitty
PR: #649
File: objects/obj_enunit/Alarm_0.gml:289-291
Timestamp: 2025-03-31T15:41:45.611Z
Learning: GameMaker Studio's function action_if_variable(image_index, -500, 0) is auto-generated code from GameMaker's visual Drag and Drop system. It checks if image_index equals -500. In ChapterMaster, this was being used as a special flag for enemy unit movement, but wasn't triggering consistently, causing enemies to move only every other turn. The refactored code replaced this with direct function calls at specific combat stages.

scripts/scr_special_view/scr_special_view.gml (5)

Learnt from: VanWeapon
PR: #725
File: scripts/scr_special_view/scr_special_view.gml:49-49
Timestamp: 2025-04-15T10:54:19.720Z
Learning: In the ChapterMaster codebase, obj_ini.role[100][2] and obj_ini.role[100][eROLE.ChapterMaster] reference different roles, and both are needed in conditions checking for specific types of units. Numeric indices should not be assumed to match their corresponding enum values without verification.

Learnt from: MCPO-Spartan-117
PR: #562
File: scripts/scr_marine_struct/scr_marine_struct.gml:0-0
Timestamp: 2025-03-07T01:56:40.971Z
Learning: Marines' ages should be incremented at the year transition in obj_turn_end/Alarm_1.gml rather than calculated dynamically based on the current year and recruitment date. This ensures proper aging without retroactive application.

Learnt from: EttyKitty
PR: #579
File: objects/obj_enunit/Alarm_0.gml:186-187
Timestamp: 2025-03-11T01:34:29.268Z
Learning: In the ChapterMaster game, the variable _column_size_value represents the physical size/mass of a column of units, calculated as (vehicles * 2.5) + (dreadnoughts * 2) + (men * 0.5), and is used for determining back row protection rules.

Learnt from: OH296
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.

Learnt from: OH296
PR: #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.

scripts/scr_librarium/scr_librarium.gml (9)

Learnt from: MCPO-Spartan-117
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
PR: #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.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-05T20:58:21.881Z
Learning: In the ChapterMaster game, there's a need to refactor hardcoded item effects and move them to a "specials" property of items, following the pattern established with the combi_tool special. This improves code maintainability and makes effects more explicit in item definitions.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-05T20:58:21.881Z
Learning: In the ChapterMaster game, there's a need to refactor hardcoded item effects and move them to a "specials" property of items, following the pattern established with the combi_tool special. This improves code maintainability and makes effects more explicit in item definitions.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-16T09:51:55.065Z
Learning: In obj_ingame_menu/Step_0.gml, the line "if (effect=14){instance_create(0,0,obj_fade);fading=0.1;}" must not be commented out, as it's critical for menu button transitions. When clicking the Exit button, it sets effect=14, but without this handler creating the fade effect object, no transition occurs.

Learnt from: EttyKitty
PR: #649
File: objects/obj_enunit/Alarm_0.gml:289-291
Timestamp: 2025-03-31T15:41:45.611Z
Learning: GameMaker Studio's function action_if_variable(image_index, -500, 0) is auto-generated code from GameMaker's visual Drag and Drop system. It checks if image_index equals -500. In ChapterMaster, this was being used as a special flag for enemy unit movement, but wasn't triggering consistently, causing enemies to move only every other turn. The refactored code replaced this with direct function calls at specific combat stages.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-18T13:33:54.167Z
Learning: In obj_new_button/Step_0.gml, when using scr_click_left() for detecting clicks on menu buttons, it should be called with parameter 0 (scr_click_left(0)) to disable the default cooldown of 60 steps. Using the default cooldown can cause menu buttons to appear unresponsive since it prevents subsequent clicks from being detected.

objects/obj_popup/Draw_0.gml (6)

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-16T09:51:55.065Z
Learning: In obj_ingame_menu/Step_0.gml, the line "if (effect=14){instance_create(0,0,obj_fade);fading=0.1;}" must not be commented out, as it's critical for menu button transitions. When clicking the Exit button, it sets effect=14, but without this handler creating the fade effect object, no transition occurs.

Learnt from: EttyKitty
PR: #649
File: objects/obj_enunit/Alarm_0.gml:289-291
Timestamp: 2025-03-31T15:41:45.611Z
Learning: GameMaker Studio's function action_if_variable(image_index, -500, 0) is auto-generated code from GameMaker's visual Drag and Drop system. It checks if image_index equals -500. In ChapterMaster, this was being used as a special flag for enemy unit movement, but wasn't triggering consistently, causing enemies to move only every other turn. The refactored code replaced this with direct function calls at specific combat stages.

Learnt from: MCPO-Spartan-117
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
PR: #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.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: #649
File: objects/obj_enunit/Alarm_0.gml:289-291
Timestamp: 2025-03-31T15:41:45.611Z
Learning: GameMaker Studio's function action_if_variable(image_index, -500, 0) was part of an old enemy movement system in ChapterMaster. This syntax is auto-generated from GameMaker's Drag-and-Drop interface and checks if image_index is greater than or equal to -500. In the refactored code, enemy movement is triggered directly through function calls rather than relying on this conditional check.

scripts/scr_get_item_names/scr_get_item_names.gml (7)

Learnt from: VanWeapon
PR: #725
File: scripts/scr_special_view/scr_special_view.gml:49-49
Timestamp: 2025-04-15T10:54:19.720Z
Learning: In the ChapterMaster codebase, obj_ini.role[100][2] and obj_ini.role[100][eROLE.ChapterMaster] reference different roles, and both are needed in conditions checking for specific types of units. Numeric indices should not be assumed to match their corresponding enum values without verification.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: #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.

Learnt from: OH296
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.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-05T20:58:21.881Z
Learning: In the ChapterMaster game, there's a need to refactor hardcoded item effects and move them to a "specials" property of items, following the pattern established with the combi_tool special. This improves code maintainability and makes effects more explicit in item definitions.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-05T20:58:21.881Z
Learning: In the ChapterMaster game, there's a need to refactor hardcoded item effects and move them to a "specials" property of items, following the pattern established with the combi_tool special. This improves code maintainability and makes effects more explicit in item definitions.

scripts/scr_gift_items/scr_gift_items.gml (7)

Learnt from: MCPO-Spartan-117
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
PR: #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.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-05T20:58:21.881Z
Learning: In the ChapterMaster game, there's a need to refactor hardcoded item effects and move them to a "specials" property of items, following the pattern established with the combi_tool special. This improves code maintainability and makes effects more explicit in item definitions.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-05T20:58:21.881Z
Learning: In the ChapterMaster game, there's a need to refactor hardcoded item effects and move them to a "specials" property of items, following the pattern established with the combi_tool special. This improves code maintainability and makes effects more explicit in item definitions.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-16T09:51:55.065Z
Learning: In obj_ingame_menu/Step_0.gml, the line "if (effect=14){instance_create(0,0,obj_fade);fading=0.1;}" must not be commented out, as it's critical for menu button transitions. When clicking the Exit button, it sets effect=14, but without this handler creating the fade effect object, no transition occurs.

scripts/scr_popup_functions/scr_popup_functions.gml (5)

Learnt from: OH296
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.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: #649
File: objects/obj_enunit/Alarm_0.gml:289-291
Timestamp: 2025-03-31T15:41:45.611Z
Learning: GameMaker Studio's function action_if_variable(image_index, -500, 0) is auto-generated code from GameMaker's visual Drag and Drop system. It checks if image_index equals -500. In ChapterMaster, this was being used as a special flag for enemy unit movement, but wasn't triggering consistently, causing enemies to move only every other turn. The refactored code replaced this with direct function calls at specific combat stages.

Learnt from: EttyKitty
PR: #649
File: objects/obj_enunit/Alarm_0.gml:289-291
Timestamp: 2025-03-31T15:41:45.611Z
Learning: GameMaker Studio's function action_if_variable(image_index, -500, 0) was part of an old enemy movement system in ChapterMaster. This syntax is auto-generated from GameMaker's Drag-and-Drop interface and checks if image_index is greater than or equal to -500. In the refactored code, enemy movement is triggered directly through function calls rather than relying on this conditional check.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-16T09:51:55.065Z
Learning: In obj_ingame_menu/Step_0.gml, the line "if (effect=14){instance_create(0,0,obj_fade);fading=0.1;}" must not be commented out, as it's critical for menu button transitions. When clicking the Exit button, it sets effect=14, but without this handler creating the fade effect object, no transition occurs.

scripts/scr_ui_manage/scr_ui_manage.gml (9)

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: #649
File: objects/obj_enunit/Alarm_0.gml:289-291
Timestamp: 2025-03-31T15:41:45.611Z
Learning: GameMaker Studio's function action_if_variable(image_index, -500, 0) is auto-generated code from GameMaker's visual Drag and Drop system. It checks if image_index equals -500. In ChapterMaster, this was being used as a special flag for enemy unit movement, but wasn't triggering consistently, causing enemies to move only every other turn. The refactored code replaced this with direct function calls at specific combat stages.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-16T09:51:55.065Z
Learning: In obj_ingame_menu/Step_0.gml, the line "if (effect=14){instance_create(0,0,obj_fade);fading=0.1;}" must not be commented out, as it's critical for menu button transitions. When clicking the Exit button, it sets effect=14, but without this handler creating the fade effect object, no transition occurs.

Learnt from: MCPO-Spartan-117
PR: #562
File: scripts/scr_marine_struct/scr_marine_struct.gml:0-0
Timestamp: 2025-03-07T01:56:40.971Z
Learning: Marines' ages should be incremented at the year transition in obj_turn_end/Alarm_1.gml rather than calculated dynamically based on the current year and recruitment date. This ensures proper aging without retroactive application.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-05T20:58:21.881Z
Learning: In the ChapterMaster game, there's a need to refactor hardcoded item effects and move them to a "specials" property of items, following the pattern established with the combi_tool special. This improves code maintainability and makes effects more explicit in item definitions.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-05T20:58:21.881Z
Learning: In the ChapterMaster game, there's a need to refactor hardcoded item effects and move them to a "specials" property of items, following the pattern established with the combi_tool special. This improves code maintainability and makes effects more explicit in item definitions.

Learnt from: OH296
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.

scripts/scr_buttons/scr_buttons.gml (1)

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-18T13:33:54.167Z
Learning: In obj_new_button/Step_0.gml, when using scr_click_left() for detecting clicks on menu buttons, it should be called with parameter 0 (scr_click_left(0)) to disable the default cooldown of 60 steps. Using the default cooldown can cause menu buttons to appear unresponsive since it prevents subsequent clicks from being detected.

scripts/scr_manage_task_selector/scr_manage_task_selector.gml (12)

Learnt from: MCPO-Spartan-117
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
PR: #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.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-05T20:58:21.881Z
Learning: In the ChapterMaster game, there's a need to refactor hardcoded item effects and move them to a "specials" property of items, following the pattern established with the combi_tool special. This improves code maintainability and makes effects more explicit in item definitions.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-05T20:58:21.881Z
Learning: In the ChapterMaster game, there's a need to refactor hardcoded item effects and move them to a "specials" property of items, following the pattern established with the combi_tool special. This improves code maintainability and makes effects more explicit in item definitions.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-16T09:51:55.065Z
Learning: In obj_ingame_menu/Step_0.gml, the line "if (effect=14){instance_create(0,0,obj_fade);fading=0.1;}" must not be commented out, as it's critical for menu button transitions. When clicking the Exit button, it sets effect=14, but without this handler creating the fade effect object, no transition occurs.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-18T13:33:54.167Z
Learning: In obj_new_button/Step_0.gml, when using scr_click_left() for detecting clicks on menu buttons, it should be called with parameter 0 (scr_click_left(0)) to disable the default cooldown of 60 steps. Using the default cooldown can cause menu buttons to appear unresponsive since it prevents subsequent clicks from being detected.

Learnt from: EttyKitty
PR: #649
File: objects/obj_enunit/Alarm_0.gml:289-291
Timestamp: 2025-03-31T15:41:45.611Z
Learning: GameMaker Studio's function action_if_variable(image_index, -500, 0) is auto-generated code from GameMaker's visual Drag and Drop system. It checks if image_index equals -500. In ChapterMaster, this was being used as a special flag for enemy unit movement, but wasn't triggering consistently, causing enemies to move only every other turn. The refactored code replaced this with direct function calls at specific combat stages.

Learnt from: VanWeapon
PR: #725
File: scripts/scr_special_view/scr_special_view.gml:49-49
Timestamp: 2025-04-15T10:54:19.720Z
Learning: In the ChapterMaster codebase, obj_ini.role[100][2] and obj_ini.role[100][eROLE.ChapterMaster] reference different roles, and both are needed in conditions checking for specific types of units. Numeric indices should not be assumed to match their corresponding enum values without verification.

Learnt from: MCPO-Spartan-117
PR: #562
File: scripts/scr_marine_struct/scr_marine_struct.gml:0-0
Timestamp: 2025-03-07T01:56:40.971Z
Learning: Marines' ages should be incremented at the year transition in obj_turn_end/Alarm_1.gml rather than calculated dynamically based on the current year and recruitment date. This ensures proper aging without retroactive application.

Learnt from: OH296
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.

scripts/scr_reequip_units/scr_reequip_units.gml (3)

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: #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.

scripts/scr_add_artifact/scr_add_artifact.gml (9)

Learnt from: MCPO-Spartan-117
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
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-05T20:58:21.881Z
Learning: In the ChapterMaster game, there's a need to refactor hardcoded item effects and move them to a "specials" property of items, following the pattern established with the combi_tool special. This improves code maintainability and makes effects more explicit in item definitions.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-05T20:58:21.881Z
Learning: In the ChapterMaster game, there's a need to refactor hardcoded item effects and move them to a "specials" property of items, following the pattern established with the combi_tool special. This improves code maintainability and makes effects more explicit in item definitions.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: #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.

Learnt from: EttyKitty
PR: #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.

Learnt from: MCPO-Spartan-117
PR: #526
File: objects/obj_popup/Draw_0.gml:141-143
Timestamp: 2025-02-28T11:12:50.567Z
Learning: Artifacts with the "MINOR" tag cannot simultaneously have chaos/daemon properties - they are mutually exclusive categories in the game's artifact system.

Learnt from: OH296
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.

Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-16T09:51:55.065Z
Learning: In obj_ingame_menu/Step_0.gml, the line "if (effect=14){instance_create(0,0,obj_fade);fading=0.1;}" must not be commented out, as it's critical for menu button transitions. When clicking the Exit button, it sets effect=14, but without this handler creating the fade effect object, no transition occurs.

🔇 Additional comments (69)
scripts/scr_marine_struct/scr_marine_struct.gml (1)

46-53: By the Omnissiah’s decree, enum references have been scanned and appear symbolically correct.

  • All EquipmentSlot.X usages across scripts now point to the reordered values.
  • The only raw numeric slot indices found are in scripts/scr_get_item_names/scr_get_item_names.gml (cases 0 and 1 for WEAPON_ONE and WEAPON_TWO), which align with the new zero-based mapping.

Remain vigilant: please manually verify any additional magic-number switches or array indices that map directly to equipment slots.

sprites/spr_pixel_button_left/spr_pixel_button_left.yy (1)

66-75: Sacred dimensions declared with proper machine-spirit compliance.

The explicit sequence dimensions and keyframe formatting standardise the sprite resource structure without altering functionality. These improvements align with the Omnissiah's preference for precise data organisation.

objects/obj_popup/obj_popup.yy (1)

19-19: New rendering subroutine integrated into the machine-spirit's processes.

The addition of Draw_64 event supports the centralised popup rendering architecture described in the sacred texts. This modularisation pleases the Omnissiah and improves code-temple maintainability.

scripts/scr_gift_items/scr_gift_items.yy (1)

1-13: The machine spirit acknowledges this sacred resource manifest!

The GameMaker script resource is properly configured with correct metadata and structure.

scripts/scr_draw_planet_features/scr_draw_planet_features.gml (1)

275-275: A minor ritual of spacing has been observed!

The formatting adjustment adds clarity to the object property assignment by spacing around the colon operator.

scripts/scr_promote/scr_promote.yy (1)

1-13: The promotion script's sacred manifest is blessed by the Machine God!

Another properly structured GameMaker script resource with correct metadata and configuration.

scripts/scr_transfer_marines/scr_transfer_marines.yy (1)

1-13: The transfer protocols' sacred documentation is sanctified!

The resource manifest maintains the blessed consistency of structure and proper GameMaker configuration observed in the other script resources.

scripts/scr_reequip_units/scr_reequip_units.yy (1)

1-13: By the Omnissiah's will, the resource manifest is correctly structured.

The GameMaker script resource definition follows proper formatting and metadata structure. The resource hierarchy and versioning are appropriately configured.

objects/obj_dropdown_sel/Draw_0.gml (2)

32-32: Sacred refactoring: Artifact access now flows through proper data channels.

The replacement of direct struct access with fetch_artifact() centralises artifact retrieval logic, adhering to proper modularity principles.


66-68: Consistent implementation of the artifact accessor pattern.

The tooltip assignment logic now uses the same centralised fetch_artifact() function, maintaining consistency with the earlier change.

scripts/scr_company_order/scr_company_order.gml (1)

238-238: Logic improvement: Only controllable units shall be considered for squadless reinsertion.

Adding the unit.controllable() check ensures that incapacitated or otherwise unavailable units are properly filtered from squad reassignment operations.

scripts/scr_controller_helpers/scr_controller_helpers.gml (1)

273-279: Sacred UI augmentation: The artifact slate component is properly instantiated.

The DataSlate configuration with defined dimensions and positioning parameters follows established patterns for UI component creation within the Librarium interface.

objects/obj_ncombat/Alarm_7.gml (3)

461-461: By the Omnissiah's grace, event logging functions correctly.

The event logging for successful protect_raiders missions appears properly formatted and consistent with other mission completion messages.


468-468: Mission failure logging sanctified.

The event logging for failed protect_raiders missions maintains consistency with the success case whilst properly conveying the failure state.


469-469: Instance deactivation logic refined.

Moving instance_deactivate_object(obj_star) outside the defeat conditional ensures proper cleanup occurs regardless of mission outcome. This appears to be an intentional improvement to the object lifecycle management.

sprites/spr_pixel_button_right/spr_pixel_button_right.yy (1)

16-16: Sprite configuration blessed by the Machine God.

The sprite resource has been properly updated to support a two-frame sequence. The technical modifications - adding the new frame, updating sequence length to 2.0, and configuring the keyframe track - are all correctly implemented according to GameMaker's sprite format specifications.

Also applies to: 53-53, 67-79

scripts/scr_pen_And_paper/scr_pen_And_paper.gml (2)

78-90: Ambush protocols integrated into the sacred algorithms.

The new "ambush" tag evaluation follows established patterns, properly checking for the "Ambushers" advantage and relevant unit traits. The modifier values appear balanced and consistent with other tag implementations.


224-232: Statistical calculation subroutine sanctified.

The stat_average function provides clean utility for calculating average stat values across unit arrays. The implementation is mathematically sound and will serve the mission systems well.

objects/obj_tooltip/Draw_75.gml (1)

10-10: Drawing state management protocols upgraded.

The implementation of stack-based drawing state preservation using add_draw_return_values() and pop_draw_return_values() represents a significant improvement over manual state management. The explicit vertical alignment setting ensures rendering consistency.

Also applies to: 26-26, 110-110

objects/obj_popup/Draw_64.gml (1)

1-12: By the Omnissiah's grace, this centralised dispatch pattern serves the machine well.

The modular approach properly delegates rendering to specialised functions, maintaining clean separation of concerns for each popup type.

scripts/scr_ui_diplomacy/scr_ui_diplomacy.gml (1)

217-223: The sacred routing protocols have been properly recalibrated.

The diplomacy exit logic now correctly channels artifact interactions to the Librarium and STC interactions to the Armamentarium, with proper flow control preventing premature closure. This separation aligns with the modular UI architecture blessed by the machine.

ChapterMaster.yyp (1)

820-826: All new script resources verified

The following script assets are present at their expected paths:

  • scripts/scr_gift_items/scr_gift_items.gml & .yy
  • scripts/scr_promote/scr_promote.gml & .yy
  • scripts/scr_reequip_units/scr_reequip_units.gml & .yy
  • scripts/scr_transfer_marines/scr_transfer_marines.gml & .yy

No missing assets detected.

objects/obj_controller/Draw_64.gml (4)

21-22: Drawing alignment initialization blessed by the Omnissiah.

Setting text alignment parameters at the start ensures consistent rendering throughout the drawing cycle.


26-48: Sacred drawing state preservation protocols engaged.

The implementation of stack-based state management prevents corruption of drawing parameters between UI components. The Machine Spirit approves.


55-69: menu_buttons initialised in Create_0 event
By the Omnissiah’s will, the menu_buttons structure is defined in objects/obj_controller/Create_0.gml (around line 400), ensuring all sub-objects exist before Draw_64 executes. No null-reference risk detected—no further action required.


215-218: Mechanicus Confirmation: GUI Drawing Functions Present
The Omnissiah’s logs confirm that:

  • scr_draw_armentarium_gui() is defined in scripts/scr_draw_armentarium/scr_draw_armentarium.gml at line 99
  • scr_librarium_gui() is defined in scripts/scr_librarium/scr_librarium.gml at line 19

No further actions required.

objects/obj_popup/Step_0.gml (1)

470-470: Sacred data access patterns properly observed.

Using fetch_artifact() instead of direct struct access maintains proper encapsulation protocols.

scripts/scr_draw_management_unit/scr_draw_management_unit.gml (2)

1-1: Parameter augmentation protocols correctly implemented.

The addition of click_lock with default value maintains backward compatibility while extending functionality.


437-437: Input lockdown protocols properly integrated.

The click_lock parameter correctly prevents interaction during modal states, as the Omnissiah intended.

scripts/is_specialist/is_specialist.gml (4)

368-372: Menu state machine logic optimized according to sacred patterns.

Conditional initialization prevents redundant operations when transitioning menu states.


383-383: Resource purification protocols engaged.

Explicit destruction of management panel prevents UI contamination.


428-428: Squad selection state properly initialized.

Setting managing to -1 ensures correct behavior for squad-based selection mode.


431-431: Menu state guarantee protocols activated.

Explicit menu assignment ensures consistent state regardless of execution path.

objects/obj_popup/Mouse_50.gml (1)

33-35: Turn progression safeguards properly calibrated.

The additional check for complex_event prevents temporal anomalies during multi-phase operations.

scripts/scr_company_struct/scr_company_struct.gml (3)

146-148: Blessed be the Omnissiah! Function encapsulation improves the machine-spirit's clarity.

Converting squad_selection_mode to a static function prevents corruption of its sacred logic and ensures consistent evaluation.


151-157: The machine-spirit detects incomplete augmentation.

The tooltip cogitation appears disabled. Verify if this omission is intentional or if the tooltip data should be restored.

Was the tooltip intentionally removed or should it display contextual information based on obj_controller.selection_data.purpose?


479-493: The Omnissiah approves of explicit coordinate sanctification.

Setting button positions during each update cycle ensures the machine-spirit maintains proper alignment.

objects/obj_popup/Create_0.gml (3)

48-49: Machine-spirit augmentation detected: subtype categorization added.

The new subtype variable enhances popup classification capabilities within the refactored system.


64-77: The Omnissiah smiles upon this data sanctification.

Converting to object notation with named properties enhances code clarity. The one-based indexing properly aligns with Imperial company designations.


235-236: The sacred function has been relocated to its proper forge.

Moving calculate_equipment_needs to the dedicated popup functions script follows the blessed principle of modular design.

scripts/scr_popup_functions/scr_popup_functions.gml (2)

4-10: The Omnissiah approves these sacred type designations.

Replacing profane magic numbers with named constants enhances code sanctity and prevents heretical type confusion.


179-183: Cogitation pattern requires clarification.

The all_good accumulation (0.4 + 0.3 + 0.3 = 1.0 max) followed by floor() will only return 0 or 1. Verify if boolean return is intended.

Should this function return a boolean or was a percentage (0-100) intended?

objects/obj_popup/Draw_0.gml (1)

19-19: The machine-spirit rejoices in proper type sanctification.

Using POPUP_TYPE.FLEET_MOVE instead of the profane number 99 enhances code clarity.

scripts/scr_unit_quick_find_pane/scr_unit_quick_find_pane.gml (1)

519-523: The Omnissiah approves this code clarification.

Early return pattern and local variable caching enhance the machine-spirit's efficiency and readability.

scripts/scr_special_view/scr_special_view.gml (1)

35-93: Blessed be the Omnissiah! The deduplication logic functions with proper efficiency.

The implementation correctly prevents duplicate marines across specialist groups and HQ by tracking marine numbers. Processing specialists before HQ units ensures proper categorization hierarchy.

scripts/scr_get_item_names/scr_get_item_names.gml (2)

538-595: The Machine Spirit approves of this zero-based indexing standardization.

The conversion maintains proper slot mappings while aligning with standard programming conventions. The intentional gaps in vehicle slot indices are preserved correctly.


638-920: By the Omnissiah's logic circuits, the enum usage enhances code clarity.

The transition to EquipmentSlot enum constants with zero-based indexing improves maintainability and reduces potential indexing errors. All slot references are consistently updated.

scripts/scr_draw_armentarium/scr_draw_armentarium.gml (2)

26-45: ****


99-144: The sacred UI protocols function within acceptable parameters.

The dynamic button positioning and STC fragment handling logic are properly implemented. The shop refresh after identification ensures immediate availability of new items.

scripts/scr_DataSlate/scr_DataSlate.gml (3)

1-20: The Omnissiah smiles upon this data initialization protocol.

Adding the optional data parameter enables flexible object construction while maintaining backward compatibility.


63-109: Coordinate calibration protocols properly executed.

The variable case corrections and bounds assignments enhance the component's interface consistency.


378-455: The sacred drawing state preservation rituals are properly observed.

The state management wrapper ensures drawing parameter isolation, preventing contamination of the rendering pipeline.

scripts/scr_mission_functions/scr_mission_functions.gml (1)

367-395: The training protocols have been enhanced with acceptable efficiency.

Natural leader trait integration provides appropriate bonuses to both success chance and diplomatic outcomes. The siege_master trait acquisition logic follows proper probability calculations.

scripts/scr_promote/scr_promote.gml (3)

108-108: Mathematical operation requires verification by the Omnissiah.

The operation i+=mem-2 appears unusual. Verify this is the intended increment logic, as it could cause unexpected loop behaviour.


245-246: Variable declaration protocol breach.

Variable role_x lacks proper declaration while role_y is correctly declared.

-	var role_x = 0;
-	role_y = 0;
+	var role_x = 0;
+	var role_y = 0;
⛔ Skipped due to learnings
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.
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.

87-89: Variable redeclaration violates the sacred patterns.

The variable mem_unit is declared with var on line 88 but reassigned without declaration on line 94.

-                            var mem_unit = fetch_unit(move_members[mem]);
+                            mem_unit = fetch_unit(move_members[mem]);
⛔ Skipped due to learnings
Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#424
File: objects/obj_pnunit/Alarm_0.gml:203-299
Timestamp: 2025-02-26T14:38:08.117Z
Learning: Variable shadowing/overshadowing (reusing the same variable name in nested scopes, particularly loop iterators) should be flagged as a critical issue, not a nitpick, as it can cause unpredictable behavior, bugs that are difficult to trace, and potential crashes.
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.
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.
scripts/scr_gift_items/scr_gift_items.gml (1)

168-168: Sacred TODO marker acknowledged.

As per the Machine Cult's records, this comment is intentionally retained as a reminder for future implementation.

scripts/scr_manage_task_selector/scr_manage_task_selector.gml (1)

5-11: Artifact equipping protocols successfully integrated.

The new artifact equipment handling seamlessly integrates with existing UI flow.

scripts/scr_buttons/scr_buttons.gml (1)

2-26: Exemplary implementation of state preservation protocols.

The stack-based drawing state management system demonstrates proper engineering principles and will improve code maintainability across the UI system.

scripts/scr_librarium/scr_librarium.gml (2)

4-17: The Omnissiah approves this data aggregation protocol.

The artifact counting subroutine functions within acceptable parameters.


52-55: Blessed be the error handling protocols.

Proper exception containment prevents machine-spirit corruption.

scripts/scr_ui_manage/scr_ui_manage.gml (6)

102-102: The Omnissiah approves this nomenclature correction.

The parameter designation target_company provides superior clarity compared to the ambiguous system.


813-823: The machine-spirit's filtering protocols function optimally.

The conditional display logic correctly limits unit rendering during popup interactions, preventing visual interference.


971-971: Sacred refactoring protocols engaged successfully.

The invocation correctly utilizes the new modular popup initialization system.


986-986: The Omnissiah smiles upon this code consolidation.

Centralized popup initialization reduces complexity and honors the DRY principle.


1059-1059: Transfer protocols updated to specification.

The new popup initialization maintains architectural consistency.


283-283: Rite of equipments_qual_string confirmed unchanged by art_only flag

By the Omnissiah, the investigation reveals that equipments_qual_string(slot, art_only = false) always returns the item’s name for non-artifact gear and the artifact’s name for true artifacts. The art_only parameter does not alter this outcome. Explicitly passing false simply matches the default behaviour. No further changes required.

scripts/scr_reequip_units/scr_reequip_units.gml (1)

214-225: Item manifest reload protocols functioning nominally.

The data refresh subroutine operates within expected parameters.

scripts/scr_add_artifact/scr_add_artifact.gml (1)

549-580: The Omnissiah requires validation protocols and clarity in corruption calculations.

Several optimisations detected by the sacred cogitators:

  • Line 566: irandom(10 + 2) yields 2-12 corruption. Express this as irandom(10) + 2 for clarity.
  • The method lacks validation that the unit can equip this artifact type. Invoke can_equip() before processing.
  • The popup at line 572 uses archaic patterns. Consider the new popup system for consistency.
 static equip_on_unit = function(unit, slot=-1){
+    if (!can_equip()) {
+        return false;
+    }
+    if (!is_struct(unit)) {
+        return false;
+    }
     var _item  = determine_base_type();
     if (_item == "mobility"){
         unit.update_mobility_item(index);
     } else if (_item == "gear"){
         unit.update_gear(index);
     } else if (_item == "armour"){
         unit.update_armour(index);
     } else if (_item == "weapon"){
         if (slot == -1 || slot == 0){
             unit.update_weapon_one(index);
         } else {
             unit.update_weapon_two(index);
         }
     }
     var _dwarn = false;
     if (has_tag("daemonic") || has_tag("chaos")) {
-        unit.corruption += irandom(10 + 2);
+        unit.corruption += irandom(10) + 2;
         if (unit.role() == obj_ini.role[100][eROLE.ChapterMaster]) {
             _dwarn = true;
         }
     }
     if (_dwarn == true) {
         var pip = instance_create(0, 0, obj_popup);
         pip.title = "Daemon Artifacts";
         pip.text = "Some artifacts, like the one you now wield, are a blasphemous union of the Materium's matter and the Immaterium's spirit, containing the essence of a bound daemon.  While they may offer great power, and enhanced perception, they are known to whisper poisonous lies to the wielder.  The path to damnation begins with good intentions, and many times artifacts such as these have been the cause.";
         pip.image = "";
         pip.cooldown = 8;
         obj_controller.cooldown = 8;
     }
+    return true;
 }
⛔ Skipped due to learnings
Learnt from: MCPO-Spartan-117
PR: Adeptus-Dominus/ChapterMaster#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
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.
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.
Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-05T20:58:21.881Z
Learning: In the ChapterMaster game, there's a need to refactor hardcoded item effects and move them to a "specials" property of items, following the pattern established with the `combi_tool` special. This improves code maintainability and makes effects more explicit in item definitions.
Learnt from: EttyKitty
PR: Adeptus-Dominus/ChapterMaster#0
File: :0-0
Timestamp: 2025-04-05T20:58:21.881Z
Learning: In the ChapterMaster game, there's a need to refactor hardcoded item effects and move them to a "specials" property of items, following the pattern established with the `combi_tool` special. This improves code maintainability and makes effects more explicit in item definitions.
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.
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.
Learnt from: VanWeapon
PR: Adeptus-Dominus/ChapterMaster#737
File: scripts/scr_save/scr_save.gml:203-205
Timestamp: 2025-04-19T23:59:08.325Z
Learning: In the ChapterMaster codebase, empty values are expected when retrieving units with fetch_unit(), and checking for empty strings with `if(unit == "")` is sufficient error handling. Additional struct validation is not required.

@EttyKitty
Copy link
Copy Markdown
Collaborator

I've visually checked as much of this as I can.
Due to the sheer volume of stuff changed, I can only hope that you're cooking and not too much got broken.
Everything is better than duke's code. So, if it works - good enough for me. Cook. 👍

@OH296 OH296 merged commit 4f6bca9 into Adeptus-Dominus:main Jul 23, 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: Warning Type: Feature Adds something new

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants