home · contact · privacy
Fix remixer drop bug.
authorChristian Heller <c.heller@plomlompom.de>
Mon, 7 Dec 2020 06:05:47 +0000 (07:05 +0100)
committerChristian Heller <c.heller@plomlompom.de>
Mon, 7 Dec 2020 06:05:47 +0000 (07:05 +0100)
plomrogue/tasks.py
plomrogue/things.py

index 2312ab4f6e0b268fa32254c9b5815e713623887c..9d3c23e7b69359da3dd9cdcd23a6cf853eb4ebbc 100644 (file)
@@ -231,12 +231,13 @@ class Task_WEAR(Task):
             t.design = self.thing.game.hats[self.thing.name]
             del self.thing.game.hats[self.thing.name]
             self.thing.send_msg('CHAT "You drop your hat."')
-            for t in [t for t in self.thing.game.things
-                      if t.type_ == 'HatRemixer'
-                      and t.position == self.thing.position]:
-                t.accept(t)
+            for remixer in [t for t in self.thing.game.things
+                            if t.type_ == 'HatRemixer'
+                            and t.position == self.thing.position]:
+                remixer.accept(t)
                 break
         else:
+            from plomrogue.misc import quote
             self.thing.game.hats[self.thing.name] = self.thing.carrying.design
             self.thing.game.things.remove(self.thing.carrying)
             self.thing.carrying = None
index 53837e36194b9479454500381153e67cff8f5248..116ad696338ffea4fae46fc579426f8e6489048f 100644 (file)
@@ -182,6 +182,7 @@ class Thing_HatRemixer(Thing):
             new_design += random.choice(list(legal_chars))
         hat.design = new_design
         self.sound('HAT REMIXER', 'remixing a hat …')
+        self.game.changed = True