Skip to content

Commit

Permalink
TShock PR16
Browse files Browse the repository at this point in the history
  • Loading branch information
Scavenger3 committed Oct 21, 2013
1 parent 2c0e0f8 commit 1b9524a
Show file tree
Hide file tree
Showing 6 changed files with 3 additions and 2 deletions.
Binary file modified Build/Essentials.dll
Binary file not shown.
Binary file modified Build/SignCommands.dll
Binary file not shown.
4 changes: 2 additions & 2 deletions Essentials/esMain.cs
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ public void OnJoin(JoinEventArgs args)
ePly.DisabledY = Disabled[TShock.Players[args.Who].Name][1];
ePly.TSPlayer.Teleport(ePly.DisabledX * 16F, ePly.DisabledY * 16F);
ePly.Disabled = true;
ePly.TSPlayer.Disable();
ePly.Disable();
ePly.LastDisabledCheck = DateTime.UtcNow;
ePly.TSPlayer.SendErrorMessage("You are still disabled.");
}
Expand Down Expand Up @@ -369,7 +369,7 @@ public void OnUpdate(EventArgs args)
if (ePly.Disabled && ((DateTime.UtcNow - ePly.LastDisabledCheck).TotalMilliseconds) > 3000)
{
ePly.LastDisabledCheck = DateTime.UtcNow;
ePly.TSPlayer.Disable();
ePly.Disable();
if ((ePly.TSPlayer.TileX > ePly.DisabledX + 5 || ePly.TSPlayer.TileX < ePly.DisabledX - 5) || (ePly.TSPlayer.TileY > ePly.DisabledY + 5 || ePly.TSPlayer.TileY < ePly.DisabledY - 5))
{
ePly.TSPlayer.Teleport(ePly.DisabledX * 16F, ePly.DisabledY * 16F);
Expand Down
1 change: 1 addition & 0 deletions Essentials/esPlayer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ public esPlayer(int index)

public void Disable()
{
this.TSPlayer.LastThreat = DateTime.UtcNow;
this.TSPlayer.SetBuff(33, 330, true); //Weak
this.TSPlayer.SetBuff(32, 330, true); //Slow
this.TSPlayer.SetBuff(23, 330, true); //Cursed
Expand Down
Binary file modified Refs/TShockAPI.dll
Binary file not shown.
Binary file modified Refs/TerrariaServer.exe
Binary file not shown.

0 comments on commit 1b9524a

Please sign in to comment.