Fix admin tags
- Fix get size group - Fix admin tags - Fix texture already used
This commit is contained in:
parent
1df4cb3e17
commit
e973921390
@ -117,4 +117,8 @@ export class Group implements Movable {
|
||||
this.leave(user);
|
||||
}
|
||||
}
|
||||
|
||||
get getSize(){
|
||||
return this.users.size;
|
||||
}
|
||||
}
|
||||
|
@ -130,6 +130,7 @@ export class SocketManager {
|
||||
userJoinedMessage.setPosition(ProtobufUtils.toPositionMessage(player.position));
|
||||
|
||||
roomJoinedMessage.addUser(userJoinedMessage);
|
||||
roomJoinedMessage.setTagList(client.tags);
|
||||
} else if (thing instanceof Group) {
|
||||
const groupUpdateMessage = new GroupUpdateMessage();
|
||||
groupUpdateMessage.setGroupid(thing.getId());
|
||||
@ -493,6 +494,7 @@ export class SocketManager {
|
||||
const groupUpdateMessage = new GroupUpdateMessage();
|
||||
groupUpdateMessage.setGroupid(group.getId());
|
||||
groupUpdateMessage.setPosition(pointMessage);
|
||||
groupUpdateMessage.setGroupsize(group.getSize);
|
||||
|
||||
const subMessage = new SubMessage();
|
||||
subMessage.setGroupupdatemessage(groupUpdateMessage);
|
||||
|
@ -410,9 +410,14 @@ export class GameScene extends ResizableScene implements CenterListener {
|
||||
this.initCamera();
|
||||
|
||||
// Let's generate the circle for the group delimiter
|
||||
const circleElement = Object.values(this.textures.list).find((object: Texture) => object.key === 'circleSprite');
|
||||
let circleElement = Object.values(this.textures.list).find((object: Texture) => object.key === 'circleSprite-white');
|
||||
if (circleElement) {
|
||||
this.textures.remove('circleSprite');
|
||||
this.textures.remove('circleSprite-white');
|
||||
}
|
||||
|
||||
circleElement = Object.values(this.textures.list).find((object: Texture) => object.key === 'circleSprite-red');
|
||||
if (circleElement) {
|
||||
this.textures.remove('circleSprite-red');
|
||||
}
|
||||
|
||||
//create white circle canvas use to create sprite
|
||||
|
Loading…
Reference in New Issue
Block a user