Skip to content

fix: post array removal equipment and role issues - #1430

Merged
OH296 merged 13 commits into
Adeptus-Dominus:mainfrom
OH296:creation_role_fix
Aug 10, 2026
Merged

fix: post array removal equipment and role issues#1430
OH296 merged 13 commits into
Adeptus-Dominus:mainfrom
OH296:creation_role_fix

Conversation

@OH296

@OH296 OH296 commented Aug 10, 2026

Copy link
Copy Markdown
Collaborator

Summary by cubic

Replaces legacy role/equipment and livery flows with structured popups in creation. Fixes name blocking and makes equipment selection consistent across creation and re‑equip.

  • Bug Fixes

    • Role name input now uses TextBarArea with tooltips, case‑insensitive blocked values, and “allowed” checks so invalid names never overwrite; prevents stuck blocked states.
    • Creation equipment popup uses shared draw_popup_equip with before/after view off, quality changes off, and from_inventory off; sets recipient type (Marine vs. Dreadnought) and writes role data via array↔struct conversion.
    • reload_items respects from_inventory; UnitEquipment ignores unknown keys, counts inventory only when needed, enforces Dreadnought/experience rules, and avoids invalid slot checks.
    • Livery picking preserves starting colours, updates complex livery data, and shows role names from player_role_data.
  • Refactors

    • Centralized eEQUIPMENT_SLOT in scripts/enums/enums.gml; removed duplicate enum.
    • Added setup_UI_elements_equipment_selector(x,y) and made draw_popup_equip(before_after_styling) reusable for both re‑equip and creation.
    • Added convert_equipment_struct_into_array; used for role editing and UI. add_unit_to_company now merges role defaults with overrides before alter_equipment.
    • Popups created via instance_create_depth with typed data; added ePOPUP_TYPE.LIVERYPICK; role selection opens EQUIP popup; advisor/distribution UI split into scr_distribution_and_advisor_setup.

Written for commit f62e5cd. Summary will update on new commits.

Review in cubic

@github-actions github-actions Bot added Size: Huge Type: Fix This is a fix for a bug labels Aug 10, 2026

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

All reported issues were addressed across 12 files

Tip: cubic used a learning from your PR history. Let your coding agent read cubic learnings directly with the cubic MCP.

Re-trigger cubic

Comment thread scripts/scr_role_setup/scr_role_setup.gml
Comment thread objects/obj_creation_popup/Create_0.gml
Comment thread scripts/scr_role_setup/scr_role_setup.gml
Comment thread objects/obj_creation_popup/Create_0.gml
Comment thread scripts/scr_buttons/scr_buttons.gml Outdated
Comment thread scripts/scr_unit_equip_functions/scr_unit_equip_functions.gml Outdated
Comment thread scripts/scr_marine_struct/scr_marine_struct.gml
Comment thread scripts/scr_reequip_units/scr_reequip_units.gml
Comment thread scripts/scr_unit_equip_functions/scr_unit_equip_functions.gml
Comment thread scripts/scr_initialize_custom/scr_initialize_custom.gml Outdated
OH296 and others added 3 commits August 10, 2026 21:29
Co-authored-by: cubic-dev-ai[bot] <191113872+cubic-dev-ai[bot]@users.noreply.github.com>
Co-authored-by: cubic-dev-ai[bot] <191113872+cubic-dev-ai[bot]@users.noreply.github.com>
Co-authored-by: cubic-dev-ai[bot] <191113872+cubic-dev-ai[bot]@users.noreply.github.com>

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

0 issues found across 3 files (changes from recent commits).

Confidence score: 5/5

  • Automated review surfaced no issues in the provided summaries.
  • No files require special attention.

Requires human review: Auto-approval blocked by 7 unresolved issues from previous reviews.

Re-trigger cubic

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

All reported issues were addressed across 5 files (changes from recent commits).

Tip: Review your code locally with the cubic CLI to iterate faster.

Re-trigger cubic

Comment thread scripts/scr_buttons/scr_buttons.gml
Comment thread scripts/scr_buttons/scr_buttons.gml

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

All reported issues were addressed across 1 file (changes from recent commits).

Tip: Review your code locally with the cubic CLI to iterate faster.

Re-trigger cubic

Comment thread scripts/scr_buttons/scr_buttons.gml Outdated
Co-authored-by: cubic-dev-ai[bot] <191113872+cubic-dev-ai[bot]@users.noreply.github.com>
@OH296
OH296 merged commit 42b2493 into Adeptus-Dominus:main Aug 10, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant