mirror of
https://github.com/evennia/evennia.git
synced 2026-03-27 02:06:32 +01:00
Run Migrate. Implemented a full separation between Player and Character - Players (OOC entities) can now also hold cmdsets and execute commands. This means that "disconnecting" from a Character becomes possible, putting the Player in an "OOC" state outside the game. This overall makes the game much more stable since there used to be issues if the character was destroyed. Having an OOC set also avoids the previous problem of @puppeting into an object that didn't have any cmdset of its own - you couldn't get back out! A new default OOC-Cmdset handles commands available to a player while OOC. Commands in this set are applied with a low priority, allowing "IC" mode to give precedence if desired.
This change meant several changes to the lock and permission functionality, since it becomes important if permissions are assigned on the Player or on their Character (lock functions pperm() and pid() etc check on Player rather than Character). This has the boon of allowing Admins to switch and play/test the game as a "Low access" character as they like. Plenty of bug fixes and adjustments. Migrations should make sure to move over all data properly.
This commit is contained in:
parent
ce2a8e9ffe
commit
28fe2ad3f4
37 changed files with 1622 additions and 555 deletions
|
|
@ -179,7 +179,7 @@ class CmdSetHandler(object):
|
|||
string += "\n"
|
||||
merged = True
|
||||
|
||||
# Display the currently active cmdset
|
||||
# Display the currently active cmdset, limited by self.obj's permissions
|
||||
mergetype = self.mergetype_stack[-1]
|
||||
if mergetype != self.current.mergetype:
|
||||
merged_on = self.cmdset_stack[-2].key
|
||||
|
|
@ -187,7 +187,8 @@ class CmdSetHandler(object):
|
|||
if merged:
|
||||
string += " <Merged (%s)>: %s" % (mergetype, self.current)
|
||||
else:
|
||||
string += " <%s (%s)>: %s" % (self.current.key, mergetype, self.current)
|
||||
string += " <%s (%s)>: %s" % (self.current.key, mergetype,
|
||||
", ".join(cmd.key for cmd in self.current if cmd.access(self.obj, "cmd")))
|
||||
return string.strip()
|
||||
|
||||
def update(self, init_mode=False):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue