ece6ead...7b471b5
commit 7b471b565d49a165ef54357fe6d165bf5df6522b Author: Joonas Rikkonen <poe.regalis@gmail.com> Date: Sun Mar 24 13:49:53 2019 +0200 Don't apply smoothing to client cursor positions server-side commit f6a67ca31e98a353bde591789bb42a2f84d1bcc1 Author: Joonas Rikkonen <poe.regalis@gmail.com> Date: Sat Mar 23 22:29:01 2019 +0200 Nuclear shells and nuclear depth charges are removed after they've exploded. Closes #1316 commit 2d7b7b9643d3640f784ba5ab8e84caf55abad6b9 Author: Joonas Rikkonen <poe.regalis@gmail.com> Date: Sat Mar 23 22:28:26 2019 +0200 Option to configure when afflictions become visible with the health scanner. Closes #1310
This commit is contained in:
@@ -962,8 +962,6 @@ namespace Barotrauma
|
||||
}
|
||||
}
|
||||
}
|
||||
element.Value = lines[i];
|
||||
i++;
|
||||
}
|
||||
}, isCheat: false));
|
||||
#endif
|
||||
|
||||
@@ -181,7 +181,7 @@ namespace Barotrauma.Items.Components
|
||||
Dictionary<AfflictionPrefab, float> combinedAfflictionStrengths = new Dictionary<AfflictionPrefab, float>();
|
||||
foreach (Affliction affliction in allAfflictions)
|
||||
{
|
||||
if (affliction.Strength < affliction.Prefab.ActivationThreshold || affliction.Strength <= 0.0f) continue;
|
||||
if (affliction.Strength < affliction.Prefab.ShowInHealthScannerThreshold || affliction.Strength <= 0.0f) continue;
|
||||
if (combinedAfflictionStrengths.ContainsKey(affliction.Prefab))
|
||||
{
|
||||
combinedAfflictionStrengths[affliction.Prefab] += affliction.Strength;
|
||||
|
||||
@@ -940,7 +940,7 @@ namespace Barotrauma
|
||||
string targetingTag = null;
|
||||
if (targetCharacter != null)
|
||||
{
|
||||
if (targetCharacter.Submarine != null && Character.Submarine == null)
|
||||
if (targetCharacter.IsDead)
|
||||
{
|
||||
targetingTag = "dead";
|
||||
if (targetCharacter.Submarine != Character.Submarine)
|
||||
@@ -1042,11 +1042,6 @@ namespace Barotrauma
|
||||
|
||||
valueModifier *= targetingPriorities[targetingTag].Priority;
|
||||
|
||||
if (targetingTag == null) continue;
|
||||
if (!targetingPriorities.ContainsKey(targetingTag)) continue;
|
||||
|
||||
valueModifier *= targetingPriorities[targetingTag].Priority;
|
||||
|
||||
if (valueModifier == 0.0f) continue;
|
||||
|
||||
Vector2 toTarget = target.WorldPosition - character.WorldPosition;
|
||||
|
||||
@@ -1110,13 +1110,15 @@ namespace Barotrauma
|
||||
ViewTarget = null;
|
||||
if (!AllowInput) return;
|
||||
|
||||
Vector2 smoothedCursorDiff = cursorPosition - SmoothedCursorPosition;
|
||||
if (Controlled == this)
|
||||
if (Controlled == this || (GameMain.NetworkMember != null && GameMain.NetworkMember.IsServer))
|
||||
{
|
||||
SmoothedCursorPosition = cursorPosition;
|
||||
}
|
||||
else
|
||||
{
|
||||
//apply some smoothing to the cursor positions of remote players when playing as a client
|
||||
//to make aiming look a little less choppy
|
||||
Vector2 smoothedCursorDiff = cursorPosition - SmoothedCursorPosition;
|
||||
smoothedCursorDiff = NetConfig.InterpolateCursorPositionError(smoothedCursorDiff);
|
||||
SmoothedCursorPosition = cursorPosition - smoothedCursorDiff;
|
||||
}
|
||||
|
||||
@@ -153,7 +153,10 @@ namespace Barotrauma
|
||||
//how high the strength has to be for the affliction icon to be shown in the UI
|
||||
public readonly float ShowIconThreshold = 0.05f;
|
||||
public readonly float MaxStrength = 100.0f;
|
||||
|
||||
|
||||
//how high the strength has to be for the affliction icon to be shown with a health scanner
|
||||
public readonly float ShowInHealthScannerThreshold = 0.05f;
|
||||
|
||||
public float BurnOverlayAlpha;
|
||||
public float DamageOverlayAlpha;
|
||||
|
||||
@@ -257,6 +260,8 @@ namespace Barotrauma
|
||||
ShowIconThreshold = element.GetAttributeFloat("showiconthreshold", Math.Max(ActivationThreshold, 0.05f));
|
||||
MaxStrength = element.GetAttributeFloat("maxstrength", 100.0f);
|
||||
|
||||
ShowInHealthScannerThreshold = element.GetAttributeFloat("showinhealthscannerthreshold", Math.Max(ActivationThreshold, 0.05f));
|
||||
|
||||
DamageOverlayAlpha = element.GetAttributeFloat("damageoverlayalpha", 0.0f);
|
||||
BurnOverlayAlpha = element.GetAttributeFloat("burnoverlayalpha", 0.0f);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user