diff --git a/README.md b/README.md index 434ef6cd..5a013f43 100644 --- a/README.md +++ b/README.md @@ -14,4 +14,12 @@ We communicate on the ShankShock Temspeak server whilst programming. __IP__: ts3.shankshock.com -__Port__: 9987 \ No newline at end of file +__Port__: 9987 + +### IRC + +We love IRC. + +__IP__: irc.shankshock.com + +__Channel__: #terraria \ No newline at end of file diff --git a/TShockAPI/TShock.cs b/TShockAPI/TShock.cs index 3b942154..df64c85f 100755 --- a/TShockAPI/TShock.cs +++ b/TShockAPI/TShock.cs @@ -18,9 +18,9 @@ namespace TShockAPI public static string saveDir = "./tshock/"; - public static Version VersionNum = new Version(1, 9, 0, 1); + public static Version VersionNum = new Version(2, 0, 0, 1); - public static string VersionCodename = "SPACEEE"; + public static string VersionCodename = "UnrealIRCd ftw (irc.shankshock.com #terraria)"; public static bool shownVersion; @@ -336,48 +336,6 @@ namespace TShockAPI return Tools.HandleGriefer(e.Msg.whoAmI, "Update Player abuse"); } } - else if (e.MsgID == 0x10) - { - using (var br = new BinaryReader(new MemoryStream(e.Msg.readBuffer, e.Index, e.Length))) - { - byte ply = br.ReadByte(); - short life = br.ReadInt16(); - short maxLife = br.ReadInt16(); - - if (maxLife > Main.player[ply].statLifeMax + 20 || life > maxLife) - { - if (players[ply].syncHP) - { - return Tools.HandleCheater(ply, "Abnormal life increase"); - } - else - { - players[ply].syncHP = true; - } - } - } - } - else if (e.MsgID == 0x2a) - { - using (var br = new BinaryReader(new MemoryStream(e.Msg.readBuffer, e.Index, e.Length))) - { - byte ply = br.ReadByte(); - short mana = br.ReadInt16(); - short maxmana = br.ReadInt16(); - - if (maxmana > Main.player[ply].statManaMax + 20 || mana > maxmana) - { - if (players[ply].syncMP) - { - return Tools.HandleCheater(ply, "Abnormal mana increase"); - } - else - { - players[ply].syncMP = true; - } - } - } - } else if (e.MsgID == 0x1B) // New Projectile { using (var br = new BinaryReader(new MemoryStream(e.Msg.readBuffer, e.Index, e.Length))) @@ -392,7 +350,7 @@ namespace TShockAPI byte owner = br.ReadByte(); byte type = br.ReadByte(); - if (type == 29 || type == 28 || type == 30) + if (type == 29 || type == 28 || type == 37) { return Tools.HandleExplosivesUser(e.Msg.whoAmI, "Throwing an explosive device."); } @@ -441,8 +399,7 @@ namespace TShockAPI if (Main.player[e.Msg.whoAmI].selectedItem == 0x72) //Dirt Rod { - Tools.ForceKick(e.Msg.whoAmI, "Using dirt rod"); - return true; + return Tools.Kick(e.Msg.whoAmI, "Using dirt rod"); } int plyX = Math.Abs((int)Main.player[e.Msg.whoAmI].position.X / 16); diff --git a/TShockAPI/Tools.cs b/TShockAPI/Tools.cs index b3610800..d8ae36b3 100755 --- a/TShockAPI/Tools.cs +++ b/TShockAPI/Tools.cs @@ -254,7 +254,7 @@ namespace TShockAPI string ip = GetPlayerIP(plr); string playerName = Main.player[plr].name; TShock.Bans.AddBan(ip, playerName, reason); - if (!Main.player[plr].active || Netplay.serverSock[plr].kill) + if (Main.player[plr].active || !Netplay.serverSock[plr].kill) NetMessage.SendData(0x2, plr, -1, "Banned: " + reason, 0x0, 0f, 0f, 0f); Log.Info("Banned " + playerName + " for : " + reason); if (adminUserName.Length == 0) diff --git a/Update/Program.cs b/Update/Program.cs index f1aef4c0..74b8a367 100644 --- a/Update/Program.cs +++ b/Update/Program.cs @@ -19,7 +19,6 @@ namespace Update StreamReader sr = new StreamReader("pn"); procname = sr.ReadToEnd(); sr.Close(); - string[] datat = procname.Split(' '); procname = datat[0]; procargs = ""; diff --git a/Update/Resources.Designer.cs b/Update/Resources.Designer.cs index 027612f0..35d6a914 100644 --- a/Update/Resources.Designer.cs +++ b/Update/Resources.Designer.cs @@ -1,7 +1,7 @@ //------------------------------------------------------------------------------ // // This code was generated by a tool. -// Runtime Version:4.0.30319.1 +// Runtime Version:4.0.30319.225 // // Changes to this file may cause incorrect behavior and will be lost if // the code is regenerated. diff --git a/Update/Resources.resx b/Update/Resources.resx index fd37f4ea..b1ad6d77 100644 --- a/Update/Resources.resx +++ b/Update/Resources.resx @@ -119,6 +119,6 @@ - ..\TShockAPI\bin\Release\TShockAPI.dll;System.Byte[], mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + Resources\TShockAPI.dll;System.Byte[], mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 \ No newline at end of file diff --git a/Update/Update.csproj b/Update/Update.csproj index 36027cc3..f37c3dee 100644 --- a/Update/Update.csproj +++ b/Update/Update.csproj @@ -59,8 +59,9 @@ Designer + - +