Health, bleeding, oxygen & stun syncing, sending aim and use inputs and cursor positions to clients so other players will be able to see when someone is shooting, hitting with a wrench etc
This commit is contained in:
@@ -47,7 +47,7 @@ namespace Barotrauma
|
||||
AnimController.SimplePhysicsEnabled = false;
|
||||
}
|
||||
|
||||
if (isDead || health <= 0.0f) return;
|
||||
if (isDead || Health <= 0.0f) return;
|
||||
|
||||
if (Controlled == this || !aiController.Enabled) return;
|
||||
|
||||
@@ -90,7 +90,7 @@ namespace Barotrauma
|
||||
{
|
||||
AttackResult result = base.AddDamage(attacker, worldPosition, attack, deltaTime, playSound);
|
||||
|
||||
aiController.OnAttacked(attacker, (result.Damage + result.Bleeding) / Math.Max(health,1.0f));
|
||||
aiController.OnAttacked(attacker, (result.Damage + result.Bleeding) / Math.Max(Health, 1.0f));
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user