moss-n-puddles/commands/wizards.py
2025-04-24 11:34:48 -07:00

30 lines
802 B
Python
Executable file

#!/usr/bin/env python
from .command import Command
from evennia import CmdSet
class CmdFly(Command):
"""Cast the 'fly' spell.
Make sure you set the following properties, for instance:
@set self/disappear_msg = "The wizard disappears in a puff of smoke."
@set self/reappear_msg = "A plume of <<white ^ light blue ^ gray ^ >> smoke appears... ;; When the smoke clears, a wizard <<emerges ^ materializes>>."
@set self/appear_delay = 3
The last setting is the number of seconds between message segments
(those are separated by double semicolons).
"""
key = "^fly"
def func(self):
self.caller.do_fly(self.args.strip())
class CmdSetWizardSpells(CmdSet):
def at_cmdset_creation(self):
super().at_cmdset_creation()
self.add(CmdFly)