Skip to content
This repository has been archived by the owner on Aug 9, 2023. It is now read-only.

Commit

Permalink
Merge pull request #96 from SynapseSL/development
Browse files Browse the repository at this point in the history
fixed Player.ArtificialHealth
  • Loading branch information
GrafDimenzio authored Feb 19, 2022
2 parents e6cca20 + c069bd8 commit 486a58b
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 7 deletions.
7 changes: 1 addition & 6 deletions Synapse/Api/Events/EventHandler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -121,12 +121,7 @@ private void KeyPress(SynapseEventArguments.PlayerKeyPressEventArgs ev)
break;

case KeyCode.Alpha4:
foreach (var ob in SynapseController.Server.Map.Lockers)
{
ob.Position = ev.Player.Position;
MEC.Timing.CallDelayed(5f, () => ob.Rotation = ev.Player.transform.rotation);
MEC.Timing.CallDelayed(10f, () => ob.Scale = Vector3.one * 2);
}
ev.Player.ArtificialHealth = 100;
break;
}
}
Expand Down
2 changes: 1 addition & 1 deletion Synapse/Api/Player.cs
Original file line number Diff line number Diff line change
Expand Up @@ -563,7 +563,7 @@ public float Health
public float ArtificialHealth
{
get => Hub.playerStats.GetModule<AhpStat>().CurValue;
set => Hub.playerStats.GetModule<AhpStat>().CurValue = value;
set => Hub.playerStats.GetModule<AhpStat>().ServerAddProcess(value,value, 1.2f, 0f, 0f, false);
}

private int maxahp = 75;
Expand Down

0 comments on commit 486a58b

Please sign in to comment.