The Poltergeist's Abstract Factory
Summon families of spectral keystrokes and phantom clicks without binding your incantations to their mortal forms.
✧ GANG OF FOUR LINEAGE & ARCANUM ✧
GOF DESIGN PATTERN: Abstract Factory
ARCANUM SCHOOL: Conjuration // Poltergeist Automation
SCRIBE / ARCHON: Joshua Edward McLaughlin Cox
CANONICAL REGISTRATION:
// CODEX INCANTATION //
class AbstractGhostFactory {
CreateKeystrokeGhost() {
throw Error("Not implemented")
}
CreateMouseGhost() {
throw Error("Not implemented")
}
}
class MischiefFactory extends AbstractGhostFactory {
CreateKeystrokeGhost() {
return MischiefKeystroke()
}
CreateMouseGhost() {
return MischiefMouse()
}
}
class MischiefKeystroke {
Haunt() {
Send("^{Left}")
}
}
class MischiefMouse {
Haunt() {
Click("Right")
}
}
; Summoning
factory := MischiefFactory()
k := factory.CreateKeystrokeGhost()
m := factory.CreateMouseGhost()
k.Haunt()
m.Haunt()
Runic Tags:
#autohotkey
#abstract-factory
#automation
#poltergeist