Resetting EventManager IDs when ending the round, NaN/INF check when setting camera position
This commit is contained in:
@@ -234,7 +234,14 @@ namespace Barotrauma
|
||||
public Vector2 Position
|
||||
{
|
||||
get { return position; }
|
||||
set { position = value; }
|
||||
set
|
||||
{
|
||||
if (!MathUtils.IsValid(value))
|
||||
{
|
||||
return;
|
||||
}
|
||||
position = value;
|
||||
}
|
||||
}
|
||||
|
||||
public Vector2 ScreenToWorld(Vector2 coords)
|
||||
|
||||
@@ -100,6 +100,8 @@ namespace Barotrauma.Networking
|
||||
|
||||
public void Clear()
|
||||
{
|
||||
ID = 0;
|
||||
|
||||
events.Clear();
|
||||
eventLastSent.Clear();
|
||||
}
|
||||
|
||||
@@ -96,7 +96,10 @@ namespace Barotrauma.Networking
|
||||
|
||||
public void Clear()
|
||||
{
|
||||
ID = 0;
|
||||
events.Clear();
|
||||
|
||||
server.ConnectedClients.ForEach(c => c.entityEventLastSent.Clear());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user