mirror of
https://github.com/evennia/evennia.git
synced 2026-03-29 12:07:17 +02:00
Notify people in the room when others arrive/leave.
This commit is contained in:
parent
4fff8fea3a
commit
595a09d4c1
1 changed files with 3 additions and 1 deletions
|
|
@ -475,14 +475,16 @@ class Object(models.Model):
|
|||
except:
|
||||
return None
|
||||
|
||||
def move_to(self, target):
|
||||
def move_to(self, target, quiet=False):
|
||||
"""
|
||||
Moves the object to a new location.
|
||||
|
||||
target: (Object) Reference to the object to move to.
|
||||
"""
|
||||
self.get_location().emit_to_contents("%s has left." % (self.get_name(),), exclude=self)
|
||||
self.location = target
|
||||
self.save()
|
||||
self.get_location().emit_to_contents("%s has arrived." % (self.get_name(),), exclude=self)
|
||||
|
||||
def dbref_match(self, oname):
|
||||
"""
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue