Fixed the potions when emptied

This commit is contained in:
Howard Abrams 2025-08-18 22:19:51 -07:00
parent ec011949ef
commit 4c348e0fb6
2 changed files with 5 additions and 5 deletions

View file

@ -507,7 +507,7 @@ class CmdRead(Command):
else:
tidied = md_to_evennia(buf, reader.is_utf(), width)
if prefix:
tidied = prefix + "|/" + tidied
tidied = prefix + "\n\n" + tidied
EvMore(reader, tidied, session=session,
justify=True, justify_kwargs={"width": width})

View file

@ -274,8 +274,6 @@ class Cauldron(Object):
})[0]
vial.db.amount = 1
vial.db.spell = potion.db.spell
vial.db.empty_name = "empty vial"
vial.db.empty_desc = "Small crystal vial. May have contained a potion."
vial.location = maker
maker.announce_action(f"$You() $conj(fill) a small vial with $pron(your) << stew ^ elixir ^ potion ^ concoction >>.")
@ -305,8 +303,8 @@ class Cauldron(Object):
"""
potion = spawn({
"typeclass": "typeclasses.alchemy.Potion",
"key": "laughing potion",
"desc": "A purple elixir guaranteed to elicit a chuckle or two."
"key": "potion",
"desc": "Small glass vial containing a purple liquid, labeled: |mElixir Risorium|n"
})[0]
potion.location = self
potion.db.spell = LaughterSpell
@ -324,6 +322,7 @@ class Vial(Container):
"""
self.db.amount = 0
self.db.empty_name = "empty vial"
vial.db.empty_desc = "Small crystal vial. May have contained a potion."
def do_drink(self, drinker):
"""
@ -333,6 +332,7 @@ class Vial(Container):
drinker.msg("The vial is empty.")
else:
drinker.announce_action("$You() $conj(<< down ^ quaff ^ imbibe >>) a small vial.")
self.do_empty()
drinker.scripts.add(self.db.spell, autostart=True)