🦉 PROLOG ORACLE DIFFICULTY: Adept Structural

The Flyweight of Shared Runes

Conserve ethereal energy by sharing intrinsic magical states across many invocations.

✧ GANG OF FOUR LINEAGE & ARCANUM ✧
GOF DESIGN PATTERN: Flyweight
ARCANUM SCHOOL: Conjuration // Manamancy
SCRIBE / ARCHON: Joshua Edward McLaughlin Cox
CANONICAL REGISTRATION:
// PROLOG PATTERN //
% Intrinsic State (Flyweight Pool)
rune_glyph(fire, 'ᚠ', 'Burns with inner heat').
rune_glyph(frost, 'ᛁ', 'Cold to the touch').

% Extrinsic State (Context-specific)
% A drawn rune relies on the shared flyweight for its intrinsic properties
draw_rune(Type, X, Y) :-
    rune_glyph(Type, Symbol, Property),
    format('Drawing ~w at (~w, ~w) - ~w.', [Symbol, X, Y, Property]).

% ?- draw_rune(fire, 10, 20).
% "Drawing ᚠ at (10, 20) - Burns with inner heat."
Runic Tags: #flyweight #structural #prolog #optimization #runes