mirror of
https://github.com/evennia/evennia.git
synced 2026-04-05 15:37:17 +02:00
Fixed bug in @batchcommand (Resolves Issue 287). Also updated @dig to again handle deleting ranges of dbrefs (with or without # in front).
This commit is contained in:
parent
86a44ab84d
commit
4dff822764
5 changed files with 14 additions and 12 deletions
|
|
@ -43,11 +43,11 @@
|
|||
# everything in this block will be appended to the beginning of
|
||||
# all other #CODE blocks when they are executed.
|
||||
|
||||
from ev import create, search
|
||||
from ev import create_object, search_object
|
||||
from game.gamesrc.objects.examples import red_button
|
||||
from game.gamesrc.objects import baseobjects
|
||||
from ev import Object
|
||||
|
||||
limbo = search.objects('Limbo', global_search=True)[0]
|
||||
limbo = search_object('Limbo')[0]
|
||||
|
||||
|
||||
#CODE (create red button)
|
||||
|
|
@ -59,7 +59,7 @@ limbo = search.objects('Limbo', global_search=True)[0]
|
|||
# won't be able to be deleted in debug mode.
|
||||
|
||||
# create a red button in limbo
|
||||
red_button = create.create_object(red_button.RedButton, key="Red button",
|
||||
red_button = create_object(red_button.RedButton, key="Red button",
|
||||
location=limbo, aliases=["button"])
|
||||
|
||||
# we take a look at what we created
|
||||
|
|
@ -76,8 +76,8 @@ caller.msg("A %s was created." % red_button.key)
|
|||
# the python variables we assign to must match the ones given in the
|
||||
# header for the system to be able to delete them afterwards during a
|
||||
# debugging run.
|
||||
table = create.create_object(baseobjects.Object, key="Table", location=limbo)
|
||||
chair = create.create_object(baseobjects.Object, key="Chair", location=limbo)
|
||||
table = create_object(Object, key="Table", location=limbo)
|
||||
chair = create_object(Object, key="Chair", location=limbo)
|
||||
|
||||
string = "A %s and %s were created. If debug was active, they were deleted again."
|
||||
caller.msg(string % (table, chair))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue