🐛 Remove listener inside callback

This commit is contained in:
2023-07-30 16:56:11 +03:00
parent c01b748031
commit 5199b5271b
8 changed files with 62 additions and 46 deletions
+4 -2
View File
@@ -117,13 +117,15 @@ public class RagonEntity : IRagonEntity
{
buffer.WriteUShort(Type);
buffer.WriteUShort(Id);
if (StaticId != 0)
buffer.WriteUShort(StaticId);
buffer.WriteUShort(Owner.Connection.Id);
buffer.WriteUShort(Payload.Size);
Payload.Write(buffer);
_state.Snapshot(buffer);
}
@@ -72,7 +72,7 @@ public sealed class SceneLoadedOperation : IRagonOperation
var playerInfo = $"Player {context.Connection.Id}|{context.LobbyPlayer.Name}";
var entityInfo = $"{entity.Id}:{entity.Type}";
_logger.Trace($"{playerInfo} created entity {entityInfo}");
_logger.Trace($"{playerInfo} created static entity {entityInfo}");
entity.Attach(player);
room.AttachEntity(entity);