Backported vsync changes from new-netcode, WIP hull visibility culling
The hull culling functions are there, they just aren't being used right now because there are some annoying bugs.
This commit is contained in:
@@ -58,6 +58,9 @@ namespace Barotrauma
|
||||
}
|
||||
}
|
||||
|
||||
public Hull PreviousHull = null;
|
||||
public Hull CurrentHull = null;
|
||||
|
||||
public readonly bool IsNetworkPlayer;
|
||||
|
||||
private bool networkUpdateSent;
|
||||
@@ -1132,6 +1135,10 @@ namespace Barotrauma
|
||||
{
|
||||
if (!Enabled) return;
|
||||
|
||||
PreviousHull = CurrentHull;
|
||||
CurrentHull = Hull.FindHull(WorldPosition, CurrentHull, true);
|
||||
//if (PreviousHull != CurrentHull && Character.Controlled == this) Hull.DetectItemVisibility(this); //WIP item culling
|
||||
|
||||
speechBubbleTimer = Math.Max(0.0f, speechBubbleTimer - deltaTime);
|
||||
|
||||
obstructVisionAmount = Math.Max(obstructVisionAmount - deltaTime, 0.0f);
|
||||
|
||||
Reference in New Issue
Block a user