Revert "spellbook: Golf related magic words for easier debugging"
This reverts commit c0de7f6713
.
This commit is contained in:
parent
c0de7f6713
commit
0ceb3383e5
1 changed files with 1 additions and 46 deletions
|
@ -332,51 +332,6 @@ class AbortMinigame(MagicWord):
|
||||||
messenger.send("minigameAbort")
|
messenger.send("minigameAbort")
|
||||||
return "Requested minigame abort."
|
return "Requested minigame abort."
|
||||||
|
|
||||||
class SkipMiniGolfHole(MagicWord):
|
|
||||||
aliases = ["skipgolfhole", "skiphole"]
|
|
||||||
desc = "Skips the current golf hole."
|
|
||||||
execLocation = MagicWordConfig.EXEC_LOC_SERVER
|
|
||||||
arguments = []
|
|
||||||
|
|
||||||
def handleWord(self, invoker, avId, toon, *args):
|
|
||||||
from toontown.golf.DistributedGolfCourseAI import DistributedGolfCourseAI
|
|
||||||
course = None
|
|
||||||
for do in simbase.air.doId2do.values():
|
|
||||||
if isinstance(do, DistributedGolfCourseAI):
|
|
||||||
if invoker.doId in do.avIdList:
|
|
||||||
course = do
|
|
||||||
break
|
|
||||||
if not course:
|
|
||||||
return "You aren't in a golf course!"
|
|
||||||
|
|
||||||
if course.isPlayingLastHole():
|
|
||||||
course.demand('WaitReward')
|
|
||||||
else:
|
|
||||||
course.holeOver()
|
|
||||||
|
|
||||||
return "Skipped the current hole."
|
|
||||||
|
|
||||||
class AbortGolfCourse(MagicWord):
|
|
||||||
aliases = ["abortminigolf", "abortgolf", "abortcourse", "leavegolf", "leavecourse"]
|
|
||||||
desc = "Aborts the current golf course."
|
|
||||||
execLocation = MagicWordConfig.EXEC_LOC_SERVER
|
|
||||||
arguments = []
|
|
||||||
|
|
||||||
def handleWord(self, invoker, avId, toon, *args):
|
|
||||||
from toontown.golf.DistributedGolfCourseAI import DistributedGolfCourseAI
|
|
||||||
course = None
|
|
||||||
for do in simbase.air.doId2do.values():
|
|
||||||
if isinstance(do, DistributedGolfCourseAI):
|
|
||||||
if invoker.doId in do.avIdList:
|
|
||||||
course = do
|
|
||||||
break
|
|
||||||
if not course:
|
|
||||||
return "You aren't in a golf course!"
|
|
||||||
|
|
||||||
course.setCourseAbort()
|
|
||||||
|
|
||||||
return "Aborted golf course."
|
|
||||||
|
|
||||||
class Minigame(MagicWord):
|
class Minigame(MagicWord):
|
||||||
aliases = ["mg"]
|
aliases = ["mg"]
|
||||||
desc = "Teleport to or request the next trolley minigame."
|
desc = "Teleport to or request the next trolley minigame."
|
||||||
|
|
Loading…
Reference in a new issue