From 0184ef6394eca35459606248120e60c012685cd5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Diego=20De=20Gante=20P=C3=A9rez?= Date: Wed, 8 Apr 2026 18:38:26 -0600 Subject: [PATCH] ADD personal DGANT easter egg instruction on 0x0F6 --- src/spider/runtime/cpu/CPU.hpp | 5 +++ src/spider/runtime/instr/InstrMap.cpp | 2 +- src/spider/runtime/instr/Instr_0E0-0FF.cpp | 41 ++++++++++++++++++++++ 3 files changed, 47 insertions(+), 1 deletion(-) diff --git a/src/spider/runtime/cpu/CPU.hpp b/src/spider/runtime/cpu/CPU.hpp index 948ec2d..46bb324 100644 --- a/src/spider/runtime/cpu/CPU.hpp +++ b/src/spider/runtime/cpu/CPU.hpp @@ -884,6 +884,11 @@ namespace spider { // Operation: void UPY(); + // [Easter Eggs] 0x0F6 — DGANT: "In kaaba Spider" (Yucatec Maya: My name is Spider) + // Params: 0 | AddrMask1: 00 AddrMask2: 00 | TypeMask: 00 + // Operation: Writes "IN KAABA SPIDER" one char per GP register + void DGANT(); + // // }; diff --git a/src/spider/runtime/instr/InstrMap.cpp b/src/spider/runtime/instr/InstrMap.cpp index 6d3e5de..83305f8 100644 --- a/src/spider/runtime/instr/InstrMap.cpp +++ b/src/spider/runtime/instr/InstrMap.cpp @@ -281,7 +281,7 @@ CPU::Fn CPU::instrMap[] = { nullptr, // 0x0F3 nullptr, // 0x0F4 nullptr, // 0x0F5 - nullptr, // 0x0F6 + &CPU::DGANT, // 0x0F6 nullptr, // 0x0F7 nullptr, // 0x0F8 nullptr, // 0x0F9 diff --git a/src/spider/runtime/instr/Instr_0E0-0FF.cpp b/src/spider/runtime/instr/Instr_0E0-0FF.cpp index c305616..f043a49 100644 --- a/src/spider/runtime/instr/Instr_0E0-0FF.cpp +++ b/src/spider/runtime/instr/Instr_0E0-0FF.cpp @@ -4,6 +4,7 @@ */ #include +#include namespace spider { @@ -11,4 +12,44 @@ namespace spider { // TODO: Implement UPY } + // ── 0x0F6 — DGANT: "I'm SpiderLang" in a spider web ──────────── + void CPU::DGANT() { + const char art[] = + R"(\ | //)" + R"( \-+-// )" + R"( -- + --)" + R"( //-+-\ )" + R"(// | \)" + R"( )" + R"( I ' M )" + R"( SPIDER )" + R"( LANG )" + R"( )" + R"(\ | //)" + R"( \-+-// )" + R"(-- + -- )" + R"( /-+-\ )" + R"(/ | \ )" + R"( || )" + R"( || )" + R"( || )" + R"(\ | / )" + R"( \-+-/ )" + R"(-- + -- )" + R"( /-+-\ )" + R"(/ | \ )" + R"( || )" + R"( || )" + R"( || )" + R"(\ | / )" + R"( \-+-/ )" + R"(-- + -- )" + R"( /-+-\ )" + R"(/ | \ )" + R"( || )"; + for (u16 i = 0; i < sizeof(art) - 1; i++) { + _ram->at(i) = static_cast(art[i]); + } + } + }