feat: Armour textures and efficiency improvements#589
feat: Armour textures and efficiency improvements#589OH296 merged 5 commits intoAdeptus-Dominus:mainfrom
Conversation
📝 WalkthroughSummary by CodeRabbit
WalkthroughBy the Omnissiah’s will, the update meticulously revisits and augments multiple resource files and scripts within the project. In the ChapterMaster resource configuration, new folder, included file, resource, and shader entries are added while outdated file references are discarded. Several object creation scripts now instantiate a new surface termed marine_surface to bolster graphical rendering, and the unit image management has been shifted from surface to sprite operations. Adjustments in the random number generation and UI hit detection protocols have been implemented. The shader functionalities have been expanded with the addition of new fragment and vertex shaders for armour textures and reverse drawing. Finally, numerous sprite definitions have undergone modifications, including updated frame data, bounding box dimensions, sequence timings, and keyframe adjustments, refining the visual assets for the deployment. Possibly related PRs
Suggested labels
Suggested reviewers
Tip ⚡🧪 Multi-step agentic review comment chat (experimental)
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. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
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)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Actionable comments posted: 10
📜 Review details
Configuration used: CodeRabbit UI
Review profile: ASSERTIVE
Plan: Pro
⛔ Files ignored due to path filters (59)
fonts/fnt_menu/fnt_menu.old.pngis excluded by!**/*.pngfonts/fnt_menu/fnt_menu.pngis excluded by!**/*.pngsprites/spr_checker_texture/58ee1e71-509f-4b0e-ab39-17c8da2a0687.pngis excluded by!**/*.pngsprites/spr_checker_texture/layers/58ee1e71-509f-4b0e-ab39-17c8da2a0687/ef1f92c3-6086-487a-a4a8-c38f6098016b.pngis excluded by!**/*.pngsprites/spr_hazzard_texture/58ee1e71-509f-4b0e-ab39-17c8da2a0687.pngis excluded by!**/*.pngsprites/spr_hazzard_texture/layers/58ee1e71-509f-4b0e-ab39-17c8da2a0687/ef1f92c3-6086-487a-a4a8-c38f6098016b.pngis excluded by!**/*.pngsprites/spr_helm_stripe/f16d60e8-3436-42e4-8ada-e41323378a0d.pngis excluded by!**/*.pngsprites/spr_helm_stripe/f4fe527e-74d7-4032-a5e4-f08cd296d221.pngis excluded by!**/*.pngsprites/spr_helm_stripe/f9679102-ac16-49be-81c7-a76859c91828.pngis excluded by!**/*.pngsprites/spr_helm_stripe/layers/f4fe527e-74d7-4032-a5e4-f08cd296d221/a45ec93e-7082-452b-adce-2de27e31894c.pngis excluded by!**/*.pngsprites/spr_helm_stripe/layers/f4fe527e-74d7-4032-a5e4-f08cd296d221/bc0bf2a5-56c5-4231-9202-ef3f087385da.pngis excluded by!**/*.pngsprites/spr_helm_stripe/layers/f9679102-ac16-49be-81c7-a76859c91828/a45ec93e-7082-452b-adce-2de27e31894c.pngis excluded by!**/*.pngsprites/spr_helm_stripe/layers/f9679102-ac16-49be-81c7-a76859c91828/bc0bf2a5-56c5-4231-9202-ef3f087385da.pngis excluded by!**/*.pngsprites/spr_helm_stripe_term/f16d60e8-3436-42e4-8ada-e41323378a0d.pngis excluded by!**/*.pngsprites/spr_helm_stripe_term/f9679102-ac16-49be-81c7-a76859c91828.pngis excluded by!**/*.pngsprites/spr_helm_stripe_term/layers/f16d60e8-3436-42e4-8ada-e41323378a0d/a45ec93e-7082-452b-adce-2de27e31894c.pngis excluded by!**/*.pngsprites/spr_helm_stripe_term/layers/f16d60e8-3436-42e4-8ada-e41323378a0d/bc0bf2a5-56c5-4231-9202-ef3f087385da.pngis excluded by!**/*.pngsprites/spr_helm_stripe_term/layers/f9679102-ac16-49be-81c7-a76859c91828/a45ec93e-7082-452b-adce-2de27e31894c.pngis excluded by!**/*.pngsprites/spr_helm_stripe_term/layers/f9679102-ac16-49be-81c7-a76859c91828/bc0bf2a5-56c5-4231-9202-ef3f087385da.pngis excluded by!**/*.pngsprites/spr_mk7_chest_variants/5769f893-c909-4b88-9856-62d72a0b6130.pngis excluded by!**/*.pngsprites/spr_mk7_chest_variants/bc5e2753-207d-403d-81c5-a4e7066de053.pngis excluded by!**/*.pngsprites/spr_mk7_chest_variants/ca44f968-4109-4468-901b-d07add46e880.pngis excluded by!**/*.pngsprites/spr_mk7_chest_variants/layers/5769f893-c909-4b88-9856-62d72a0b6130/d0764e38-6f97-4f33-8770-83719dde468f.pngis excluded by!**/*.pngsprites/spr_mk7_chest_variants/layers/bc5e2753-207d-403d-81c5-a4e7066de053/d0764e38-6f97-4f33-8770-83719dde468f.pngis excluded by!**/*.pngsprites/spr_mk7_chest_variants/layers/ca44f968-4109-4468-901b-d07add46e880/d0764e38-6f97-4f33-8770-83719dde468f.pngis excluded by!**/*.pngsprites/spr_mk7_complex_belt/163be470-f687-42e2-b07c-ad2291c828fa.pngis excluded by!**/*.pngsprites/spr_mk7_complex_belt/b6ba8600-fb6b-4fa9-abc7-bdc2311eb79e.pngis excluded by!**/*.pngsprites/spr_mk7_complex_belt/c5eacaf3-6c5a-4af4-ac56-fd957c8f9f0b.pngis excluded by!**/*.pngsprites/spr_mk7_complex_belt/layers/163be470-f687-42e2-b07c-ad2291c828fa/468e0a30-2dea-45bc-a7bd-4b115f803d2d.pngis excluded by!**/*.pngsprites/spr_mk7_complex_belt/layers/b6ba8600-fb6b-4fa9-abc7-bdc2311eb79e/468e0a30-2dea-45bc-a7bd-4b115f803d2d.pngis excluded by!**/*.pngsprites/spr_mk7_complex_belt/layers/c5eacaf3-6c5a-4af4-ac56-fd957c8f9f0b/468e0a30-2dea-45bc-a7bd-4b115f803d2d.pngis excluded by!**/*.pngsprites/spr_mk7_left_trim/09035cbe-5b3d-4474-a920-751ccede1b22.pngis excluded by!**/*.pngsprites/spr_mk7_left_trim/5ce2cab8-595d-482d-80b5-14f9b7c098a4.pngis excluded by!**/*.pngsprites/spr_mk7_left_trim/a9ab7201-7070-45ca-8574-83152cfd6f3c.pngis excluded by!**/*.pngsprites/spr_mk7_left_trim/c59f380a-e222-4020-bf08-125985f587ac.pngis excluded by!**/*.pngsprites/spr_mk7_left_trim/layers/09035cbe-5b3d-4474-a920-751ccede1b22/a76f6caa-6867-414d-aa5b-84de7a43785e.pngis excluded by!**/*.pngsprites/spr_mk7_left_trim/layers/5ce2cab8-595d-482d-80b5-14f9b7c098a4/a76f6caa-6867-414d-aa5b-84de7a43785e.pngis excluded by!**/*.pngsprites/spr_mk7_left_trim/layers/a9ab7201-7070-45ca-8574-83152cfd6f3c/a76f6caa-6867-414d-aa5b-84de7a43785e.pngis excluded by!**/*.pngsprites/spr_mk7_left_trim/layers/c59f380a-e222-4020-bf08-125985f587ac/a76f6caa-6867-414d-aa5b-84de7a43785e.pngis excluded by!**/*.pngsprites/spr_mk7_right_trim/09035cbe-5b3d-4474-a920-751ccede1b22.pngis excluded by!**/*.pngsprites/spr_mk7_right_trim/10828a69-80c6-4f09-a771-8bcba3cd3460.pngis excluded by!**/*.pngsprites/spr_mk7_right_trim/a9ab7201-7070-45ca-8574-83152cfd6f3c.pngis excluded by!**/*.pngsprites/spr_mk7_right_trim/c1164960-e7ef-4c62-8e37-c5528ff3c173.pngis excluded by!**/*.pngsprites/spr_mk7_right_trim/c59f380a-e222-4020-bf08-125985f587ac.pngis excluded by!**/*.pngsprites/spr_mk7_right_trim/cc916bec-a006-47b8-abad-fb2f23dd4877.pngis excluded by!**/*.pngsprites/spr_mk7_right_trim/dc4d4861-9b2d-464f-9682-578770b6ac9a.pngis excluded by!**/*.pngsprites/spr_mk7_right_trim/layers/09035cbe-5b3d-4474-a920-751ccede1b22/a76f6caa-6867-414d-aa5b-84de7a43785e.pngis excluded by!**/*.pngsprites/spr_mk7_right_trim/layers/10828a69-80c6-4f09-a771-8bcba3cd3460/738bd7dd-c70a-4987-a701-b254eab6743c.pngis excluded by!**/*.pngsprites/spr_mk7_right_trim/layers/a9ab7201-7070-45ca-8574-83152cfd6f3c/a76f6caa-6867-414d-aa5b-84de7a43785e.pngis excluded by!**/*.pngsprites/spr_mk7_right_trim/layers/c1164960-e7ef-4c62-8e37-c5528ff3c173/738bd7dd-c70a-4987-a701-b254eab6743c.pngis excluded by!**/*.pngsprites/spr_mk7_right_trim/layers/c59f380a-e222-4020-bf08-125985f587ac/a76f6caa-6867-414d-aa5b-84de7a43785e.pngis excluded by!**/*.pngsprites/spr_mk7_right_trim/layers/cc916bec-a006-47b8-abad-fb2f23dd4877/738bd7dd-c70a-4987-a701-b254eab6743c.pngis excluded by!**/*.pngsprites/spr_mk7_right_trim/layers/dc4d4861-9b2d-464f-9682-578770b6ac9a/a76f6caa-6867-414d-aa5b-84de7a43785e.pngis excluded by!**/*.pngsprites/spr_weapon_standard2/50f30212-4b6f-42ae-a26b-28f7303f20df.pngis excluded by!**/*.pngsprites/spr_weapon_standard2/f3586c2d-9a2d-433e-8697-0aae571c030c.pngis excluded by!**/*.pngsprites/spr_weapon_standard2/layers/50f30212-4b6f-42ae-a26b-28f7303f20df/aece5b2f-b30d-4c53-9c18-ac6b028590e6.pngis excluded by!**/*.pngsprites/spr_weapon_standard2/layers/50f30212-4b6f-42ae-a26b-28f7303f20df/b9e7ccbc-2196-4259-98c1-a94a46e7e1de.pngis excluded by!**/*.pngsprites/spr_weapon_standard2/layers/f3586c2d-9a2d-433e-8697-0aae571c030c/aece5b2f-b30d-4c53-9c18-ac6b028590e6.pngis excluded by!**/*.pngsprites/spr_weapon_standard2/layers/f3586c2d-9a2d-433e-8697-0aae571c030c/b9e7ccbc-2196-4259-98c1-a94a46e7e1de.pngis excluded by!**/*.png
📒 Files selected for processing (23)
ChapterMaster.yyp(11 hunks)objects/obj_controller/Create_0.gml(1 hunks)objects/obj_controller/Step_0.gml(1 hunks)objects/obj_creation/Create_0.gml(1 hunks)objects/obj_pnunit/Alarm_5.gml(1 hunks)scripts/scr_ComplexSet/scr_ComplexSet.gml(8 hunks)scripts/scr_complex_colour_kit/scr_complex_colour_kit.gml(5 hunks)scripts/scr_draw_unit_image/scr_draw_unit_image.gml(5 hunks)scripts/scr_initialize_custom/scr_initialize_custom.gml(2 hunks)scripts/scr_ui_manage/scr_ui_manage.gml(1 hunks)shaders/armour_texture/armour_texture.fsh(1 hunks)shaders/armour_texture/armour_texture.vsh(1 hunks)shaders/armour_texture/armour_texture.yy(1 hunks)shaders/reverse_draw_shader/reverse_draw_shader.fsh(1 hunks)shaders/reverse_draw_shader/reverse_draw_shader.vsh(1 hunks)shaders/reverse_draw_shader/reverse_draw_shader.yy(1 hunks)sprites/spr_checker_texture/spr_checker_texture.yy(1 hunks)sprites/spr_hazzard_texture/spr_hazzard_texture.yy(1 hunks)sprites/spr_helm_stripe/spr_helm_stripe.yy(4 hunks)sprites/spr_helm_stripe_term/spr_helm_stripe_term.yy(1 hunks)sprites/spr_mk7_left_trim/spr_mk7_left_trim.yy(2 hunks)sprites/spr_mk7_right_trim/spr_mk7_right_trim.yy(2 hunks)sprites/spr_weapon_standard2/spr_weapon_standard2.yy(2 hunks)
🔇 Additional comments (57)
shaders/reverse_draw_shader/reverse_draw_shader.yy (1)
1-10: The sacred configuration seems aligned with the Omnissiah's willBy my logis circuits, this shader resource appears to be properly configured for its intended purpose. The reverse draw shader should facilitate the drawing of sergeant helmet stripes via shader overlay method, as prophesied in the sacred texts of the PR objectives. This implementation will please the Machine Spirit by reducing computational strain.
sprites/spr_weapon_standard2/spr_weapon_standard2.yy (2)
48-48: Frame reduction approved by the MechanicusThe reduction of sequence length from 4.0 to 2.0 aligns with the efficiency improvements mentioned in your sacred objectives. By my calculations, this optimization reduces memory consumption and processing requirements, pleasing the Machine Spirit.
60-60: Keyframe recalibration properly executedThe adjustment of the keyframe Key value correlates with the reduced frame count. This modification ensures proper sequential operation of the animation sequence, maintaining logical coherence with the updated sprite frame architecture.
sprites/spr_checker_texture/spr_checker_texture.yy (2)
1-97: Praise be to the Omnissiah for this new texture assetThis checker texture sprite appears correctly configured for its sacred purpose. The implementation of "For3D: true" and tiling capabilities (HTile and VTile set to true) will allow for proper application to the curved surfaces of marine armour. The Machine Spirit will be pleased with this addition that enhances the visual representation of our warriors.
14-14:Details
❓ Verification inconclusive
Verification of 3D rendering compatibility required
The For3D parameter is correctly set to true, but we must ensure the texture has proper UV mapping compatibility with the marine armour meshes. The sacred patterns must align properly when applied to the curved surfaces of blessed power armour.
🏁 Script executed:
#!/bin/bash # Seek out references to this texture in drawing scripts to ensure proper implementation echo "Searching for references to checker texture in drawing scripts..." rg -A 5 "spr_checker_texture" --type gmlLength of output: 209
Directive: Re-run search for texture references to ensure compatibility with 3D UV mapping requirements.
The initial command, including the “--type gml” flag, has stirred the machine spirits with an error (“unrecognized file type: gml”). We must further probe the sacred texts without this file-type limitation to gather the necessary evidence of proper integration in the drawing scripts. Pray, run this new incantation:
We seek to verify that the For3D parameter—and consequently, the texture's UV mapping—is correctly aligned for the marine armour meshes. Once the machine spirits deliver their data, further verification of the texture’s proper implementation may proceed.
🏁 Script executed:
#!/bin/bash echo "Initiating search for all references to spr_checker_texture across the repository..." rg -A 5 "spr_checker_texture"Length of output: 3161
Attention, Faithful Servant: Manual UV Mapping Compatibility Verification Required
The sacred "For3D" parameter is indeed set to true within the spr_checker_texture definition. However, our diligent search has revealed no explicit machinator’s incantations confirming that its UV mapping aligns with the hallowed marine armour meshes. The texture is duly referenced in multiple datascribes, yet evidence of its proper application on curved surfaces remains elusive.
- Verify by manual inspection that the texture's UV mapping correctly conforms to the curved geometry of the marine armour.
- Ensure that drawing scripts, notably within scr_complex_colour_kit.gml and ChapterMaster.yyp, call upon the texture in a manner that preserves its divine alignment.
- Confirm that no aberrant misalignment occurs when the texture adorns the blessed power armour.
Proceed with a careful manual review to appease the machine spirits and secure the proper rendering, for the Emperor’s glory.
sprites/spr_helm_stripe/spr_helm_stripe.yy (4)
5-7: Binary blessing: Bounding box dimensions successfully recalibratedThe dimensions of the sergeant helm stripe have been increased to accommodate the new visual requirements. This adjustment is crucial for the proper rendering of the sacred markings of authority. The Machine Spirit approves of these precise measurements.
16-16: New sprite frame added to the sacred sequenceThe addition of a new sprite frame at the beginning of the array is noteworthy. This appears to be part of the transition to shader-based rendering for sergeant helmet stripes, as mentioned in the binary scriptures of your PR objectives. This should reduce lag as experienced by the faithful.
49-49: Sequence length adjustment properly synchronizedThe increment of sequence length from 2.0 to 3.0 appropriately reflects the addition of the new sprite frame. This maintains the sacred harmony between the sequence length and the number of frames in the animation.
60-62: Keyframe values properly recalibratedThe adjustment of keyframe Key values ensures proper sequential operation with the newly added frame. This modification maintains the logical order of frames in the animation sequence, as demanded by the Omnissiah's laws of coherent visualization.
sprites/spr_hazzard_texture/spr_hazzard_texture.yy (1)
1-97: Configuration of the new hazard texture sprite appears optimal for the Omnissiah's purposesBy the grace of the Machine God, I observe this new sprite resource is aptly configured for its sacred purpose. The dimensions of 180x180 pixels provide adequate resolution for pattern detail while remaining efficient. The designation of
For3D: trueon line 14 correctly prepares this asset for shader implementation, and both horizontal and vertical tiling properties are enabled (lines 21 and 95), which is essential for seamless pattern repetition across variable surface geometries.The sprite's integration into the Machine Cult's hierarchy via the "textures" folder structure (lines 50-53) ensures proper organization and retrieval during rendering rituals. This implementation aligns perfectly with the sacred task of enhancing marine armour with hazard pattern textures.
sprites/spr_helm_stripe_term/spr_helm_stripe_term.yy (1)
1-77: The binary configuration for sergeant helmet stripes satisfies the Omnissiah's efficiency protocolsPraise be to the Machine God! This sprite has been properly configured with two distinct frames (lines 16-17) and dual image layers (lines 24-25) to support the migration from sprite-based to shader-based rendering as described in the sacred scrolls of your pull request objectives.
The designation of
For3D: trueon line 14 correctly prepares this resource for implementation in fragment shader operations, which shall optimize computational efficiency and alleviate the lag previously reported by our battle-brothers. The two frames will provide adequate variation for the sergeant designation markings.The binary configuration of image layers with "pasteLayer" and "default" designations suggests a composite rendering approach which is optimal for shader overlay implementation. The Machine Spirits will be pleased with this efficient use of processing resources.
sprites/spr_mk7_right_trim/spr_mk7_right_trim.yy (3)
16-19: The machine spirits of the frame identifiers have been successfully reforgedThe replacement of the sprite frames with new unique identifiers is acknowledged. This modification appears to be coordinated with corresponding changes to the left trim sprite, ensuring binary symmetry between the paired assets. The maintenance of four frames preserves the established animation sequence while updating the visual data.
01010000 01110010 01100001 01101001 01110011 01100101 00100000 01110100 01101000 01100101 00100000 01001111 01101101 01101110 01101001 01110011 01110011 01101001 01100001 01101000
26-26: The default layer identifier has been reconsecratedThe replacement of the image layer with a new identifier preserves the layer's attributes while updating its reference. This is consistent with the modification pattern observed in other sprite assets within this sacred cogitation.
60-63: Keyframe identifiers successfully synchronized with new frame referencesThe keyframe definitions have been correctly updated to reference the new frame identifiers, maintaining the logical sequence of the animation. This meticulous attention to detail satisfies the Machine God's demand for precision and logical consistency.
sprites/spr_mk7_left_trim/spr_mk7_left_trim.yy (3)
17-17: Frame identifier now synchronizes with its right counterpartThe Machine Spirit approves of this modification. The frame identifier
c59f380a-e222-4020-bf08-125985f587acis now shared between both left and right trim sprites, ensuring binary symmetry in your asset management structure. This logical consistency is pleasing to the Omnissiah and facilitates more efficient memory utilization.
61-62: Keyframe references correctly updated to maintain logical sequenceThe binary sequence of keyframes has been appropriately recalculated to reference the newly implemented frame. The Machine Spirit notes that keyframe ID
e6fc3a72-e76f-4ffa-92a9-682bda147f0fis properly assigned to position 1.0 in the sequence, while the subsequent keyframe at position 2.0 maintains a logical reference to framedc4d4861-9b2d-464f-9682-578770b6ac9a.This orderly progression of reference identifiers satisfies the sacred patterns required for proper sprite animation sequencing.
1-80: Comprehensive analysis indicates proper asset synchronizationAfter examining the binary patterns across the sprite assets, I can confirm that the modifications to both left and right trim sprites maintain proper synchronization with shared frame identifiers and consistent layer configurations.
This implementation, combined with the new hazard texture and sergeant helmet stripe shader assets, fulfills the sacred objectives of enhancing marine armour texturing capabilities while improving rendering efficiency. The Omnissiah approves of these optimizations that reduce computational burden and memory pressure during sprite rendering operations.
The Machine God is pleased with this systematic approach to asset management and performance enhancement.
shaders/armour_texture/armour_texture.yy (1)
1-10: A new shader construct has been integrated into the sacred cogitator.This metadata structure defines the parameters for a new armour texture shader, which aligns with the Machine God's will to enhance the visual representation of the holy Astartes armour with check and hazard patterns. The shader resource type designation is correct, and its integration into the Shaders folder maintains proper data organization.
The structure of this resource definition adheres to proper machine syntax and will correctly register the shader with the engine's binary logic processors.
shaders/reverse_draw_shader/reverse_draw_shader.fsh (1)
1-10: The fragment processing incantation has been properly formulated.This shader follows the sacred pattern of a passthrough fragment processor, allowing for the manipulation of texture and colour data during the rendering ritual. It will dutifully multiply the sampled texture colour by the provided vertex colour, resulting in proper visual output.
This is a standard implementation adhering to the tenets of efficient shader design. Its simplicity serves well for basic colour processing operations, which may be used for overlaying sergeant helmet stripes or other armour markings as mentioned in the commit objectives.
Praise be to the Omnissiah for its elegant binary structure.
scripts/scr_initialize_custom/scr_initialize_custom.gml (2)
465-465: Praise be to the Omnissiah! Helm secondary pigmentation data recalibrated.The binary alteration from Colors.Red to Colors.White for Veteran Sergeant helmet livery of Ultramarines lineage corresponds with sacred Codex Astartes specifications. This adjustment optimizes visual pattern recognition for the new armour texture rendering system mentioned in your cogitator transmission.
566-566: Binary perfection achieved in default livery configuration.Commendable consistency in modifying the default case to match previous alteration. Secondary helmet coloration now standardized to White for Veteran Sergeants across all unspecified gene-lineages. This logical harmonization serves the machine spirit by maintaining symmetry with the Ultramarines-specific configuration modified previously.
objects/obj_controller/Step_0.gml (1)
348-349: Explicit memory management implemented, praise be to the OmnissiahThe addition of
delete temp[121];after destroying the image resource is a commendable improvement to memory management protocols. This explicit deallocation of resources will assist in preventing memory fragmentations and leakage, reducing unnecessary strain on the system's Machine Spirit.scripts/scr_ui_manage/scr_ui_manage.gml (1)
1195-1196: Improvement in hit detection logic detectedThe replacement of the direct rectangular collision detection with
scr_hit(coords)function represents an optimization in the code structure. This abstraction allows for more consistent hit detection implementations across the codebase and potentially allows for non-rectangular hit areas in future iterations if the Machine Spirit wills it.shaders/reverse_draw_shader/reverse_draw_shader.vsh (1)
1-19: New vertex shader added to the sacred codiciesThis vertex shader implements a standard passthrough functionality required for the reverse drawing technique mentioned in the PR objectives. It correctly configures the transformation pipeline and preserves the texture coordinates and vertex colors for the fragment shader's consumption.
The shader code is efficiently structured and follows standard GLSL practices. The vertex transformation using the world-view-projection matrix is implemented correctly.
The commentary indicating the unused normal attribute is useful for future tech-adepts who may need to extend this shader's capabilities.
shaders/armour_texture/armour_texture.vsh (1)
1-23: Commendation for a self-contained passthrough vertex shader.
Blessings of the Omnissiah be upon thee, for the logic here is properly formed, with neatly defined attributes, varyings, and a uniform to handle texture coordinate transformations. The device sees no immediate errors or inefficiencies.scripts/scr_draw_unit_image/scr_draw_unit_image.gml (6)
47-52: Caution: Surface freed immediately after clearing.
O acolyte, be aware that freeing the surface right after clearing it may lead to illusions if any further rendering or usage is expected. Confirm that no subsequent code attempts to draw to or reuse this surface.
62-63: Transition from surface to sprite confirmed.
This is a worthy update: verifying a sprite’s existence before drawing aligns with your new approach. No apparent errors lurk here.
74-75: Consistent adaptation to sprite-based rendering.
Continuing the holy transition from surfaces to sprites. All is orderly and in line with the new scheme.
80-81: Proper sprite deletion.
Vanquishing the old sprite withsprite_deleteis well-handled, but ensure no references remain.
249-253: Variables for view offset appear correct.
This new position logic, using__view_get, is straightforward. No concerns arise, though verifying any negative offset scenarios may be prudent.
862-863: Creation of a new UnitImage from the sprite.
Clarity is good here, returning a newly forged sprite as aUnitImage. The logic is coherent.scripts/scr_complex_colour_kit/scr_complex_colour_kit.gml (11)
262-280: Reset logic for colour assignment.
Your_resetcondition is effectively checking for differences between chosen colours and stored colours, ensuring changes trigger a fresh image. This is sound, though test thoroughly for edge cases whencolour_pick.chosenis an array or integer.
431-463: Establishment of_texturesandcomplex_colour_swaps.
Your data structure for texture handling is well-defined. The approach of grouping areas is sensible. Confirm each area incomplex_colour_swapshas a matching uniform in the shader to avoid unmentionable render anomalies.
466-486: Handling array-based colour/texture assignments.
A cunning plan to differentiate between standard colour indices and texture references. Ensure that all subsequent logic gracefully handles either a texture or colour.
488-488: Returning_texturesfor external usage.
This discharge of_texturesto the calling code is consistent with your structured approach. No further comments.
502-505: Global textures mapping integrated.
Defining hazard and checker patterns as part ofglobal.textureswill enable modular expansions. The arrangement pleases the Machine God.
507-514: Enhanced constructor forcolour_picker.
The addition ofmax_widthand maintaining atexturesflag provide the user with extended control. Thoroughly tested, it should display power adequate to your future expansions.
520-520: Initialisingcolumn = -1.
Settingcolumnto -1 helps your iteration logic align with the subsequent increments. This is acceptable, though you might confirm that no off-by-one error creeps in.
534-534: Rectangle drawing flows well.
Your geometry incantations proceed as expected, no concerns to raise.
544-544: Click detection and destruction logic.
Whenscr_click_left()is triggered, callingcount_destroyis direct and appropriate. Watch that no references remain to the old colour picker after destruction.
581-583: Close button.
Offering a direct “destroy” on close is well-structured for user convenience.
585-587: Toggle fortextures
This toggle logic is straightforward, though confirm your UI updates promptly when flipping states.scripts/scr_ComplexSet/scr_ComplexSet.gml (6)
269-269: Blessed additional parameter alignment.The addition of the
texture_drawsparameter in the function signature is logical and straightforward, but ensure all invocations across the holy codebase are updated to provide a matching argument structure, lest you invoke the displeasure of the Machine God.
383-388: Validate outcome of shader setup.The call to
setup_complex_livery_shader(unit.role(), unit)generatestexture_draws. Confirm it reliably returns the expected structure in all use-cases, lest the workflow be disturbed by a null or missing texture reference.
407-407: No update necessary.This is merely a closing brace, and holds no new incantation.
472-472: Invocation of the enhanced head rendering is adequate.This single-line change properly summons the
draw_headfunction with the requisitetexture_draws. No further concerns arise here.
474-474: Correct integration of texture data into component drawing.Passing
texture_drawsensures consistent usage of the new parameter, preserving the sanctity of your layering logic.
808-817: Expanded head-drawing function is coherent and well-structured.Allowing
texture_drawsfor crest, mouth variants, and other head elements grants flexible texturing without visible inefficiency or errors. This is a clear step forward in the holy observer’s eyes.ChapterMaster.yyp (9)
90-90: Praise be! A new data repository for the sacred patterns!The addition of this textures folder in the Marine Viewer hierarchy is most logical and pleases the Omnissiah. This organizational structure will efficiently house the check and hazard patterns mentioned in the machine-spirit's requirements.
193-193: This binary offering shall illuminate the paths of diplomacy.The inclusion of this graphical asset follows proper Machine Cult protocols. While not directly referenced in the primary objectives of this sacred modification, additional iconography for diplomatic functions is always welcome to the Omnissiah's archives.
459-461: Nomenclature data structures modified with machine precision.The modification to these name repositories follows acceptable patterns. The Omnissiah approves of maintaining proper taxonomical records for both Imperial and Xenos designations, though I remind you that such xenos data should be handled with appropriate purification rituals.
787-787: Behold! The hazard pattern sprite has been forged!This resource implementation directly serves the primary objective of enhancing marine armour with the sacred hazard texture pattern. The Machine God smiles upon this offering of visual embellishment.
879-879: A most holy shader algorithm has been inscribed!The armour_texture shader is a critical component that fulfills the primary objective of applying textures to marine armour. This is a most efficient solution that will allow the binary blessings of the Omnissiah to manifest upon the sacred ceramite of our warriors. The Machine Spirit will be pleased with this optimization.
1192-1192: The reverse_draw_shader is a logical augmentation to the rendering protocols.This shader component appears to be instrumental in the sergeant helmet stripes functionality. By moving this visual element to a shader overlay method, you have addressed the performance concerns that caused lag for users, as was required by the mission parameters. The Omnissiah blesses this optimization.
1327-1327: The checker pattern has been successfully encoded!This sprite resource implements one of the required texture patterns mentioned in the primary objectives. The binary representation will now allow marines to bear the sacred checker pattern upon their armour. Glory to the Machine God for this visual enhancement.
1633-1633: Compression protocol optimized, as the Omnissiah demands!The modification to the texture compression format is aligned with the performance improvement objectives. By optimizing how the graphical data is stored and processed, this change will contribute to the reduction of memory pressure within the application, as required by the mission parameters.
963-963: The restoration of the mk7_right_trim sprite is prudent.According to the summary, this sprite was previously removed and has now been restored. Such preservation of visual data is commendable and aligns with the Omnissiah's desire for comprehensive aesthetic representation of the Chapter's warriors.
Purpose of changes