mirror of
https://github.com/simon987/Much-Assembly-Required.git
synced 2025-04-19 10:36:43 +00:00
Reformat + Should fix #159
This commit is contained in:
parent
07160138aa
commit
2f74dd45fc
@ -60,13 +60,13 @@ public class User implements MongoSerializable {
|
|||||||
public static User deserialize(Document obj) throws CancelledException {
|
public static User deserialize(Document obj) throws CancelledException {
|
||||||
|
|
||||||
User user = new User((ControllableUnit) GameServer.INSTANCE.getGameUniverse().getObject((long) obj.get("controlledUnit")));
|
User user = new User((ControllableUnit) GameServer.INSTANCE.getGameUniverse().getObject((long) obj.get("controlledUnit")));
|
||||||
|
user.getControlledUnit().setParent(user);
|
||||||
user.username = (String) obj.get("username");
|
user.username = (String) obj.get("username");
|
||||||
user.userCode = (String) obj.get("code");
|
user.userCode = (String) obj.get("code");
|
||||||
user.password = (String) obj.get("password");
|
user.password = (String) obj.get("password");
|
||||||
user.moderator = (boolean) obj.get("moderator");
|
user.moderator = (boolean) obj.get("moderator");
|
||||||
user.stats = new UserStats((Document) obj.get("stats"));
|
user.stats = new UserStats((Document) obj.get("stats"));
|
||||||
|
|
||||||
|
|
||||||
return user;
|
return user;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user