✨ ARCANUM RUNE DIFFICULTY: Apprentice Creational

Builder for Sprite Enchantment

Construct complex, layered sprite enchantments step by step.

✧ GANG OF FOUR LINEAGE & ARCANUM ✧
GOF DESIGN PATTERN: Builder
ARCANUM SCHOOL: Transmutation // Sprite Enchantment
SCRIBE / ARCHON: Joshua Edward McLaughlin Cox
CANONICAL REGISTRATION:
// CODEX INCANTATION //
function SpriteEnchantmentBuilder() constructor {
    sprite_target = noone;
    color_blend = c_white;
    alpha_level = 1.0;
    glow_radius = 0;
    
    static set_target = function(_sprite) { sprite_target = _sprite; return self; };
    static set_blend = function(_color) { color_blend = _color; return self; };
    static set_glow = function(_radius) { glow_radius = _radius; return self; };
    
    static build = function() {
        return new EnchantedSprite(sprite_target, color_blend, alpha_level, glow_radius);
    };
}

The Builder pattern breaks down the complex ritual of enchanting a sprite into sequential steps. Rather than invoking a colossal summoning function with myriad arguments, the transmuter applies colors, opacities, and auras methodically before finalizing the spell.

Runic Tags: #gml #creational #builder #sprite-enchantment