From 4a6bacfe98ab661137c6d0043289e3c21e06e51b Mon Sep 17 00:00:00 2001 From: Deathmax Date: Sat, 2 Jul 2011 22:07:36 +0800 Subject: [PATCH] God damn casts --- TShockAPI/TShock.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/TShockAPI/TShock.cs b/TShockAPI/TShock.cs index 4c6934fa..3fa320e7 100755 --- a/TShockAPI/TShock.cs +++ b/TShockAPI/TShock.cs @@ -462,7 +462,7 @@ namespace TShockAPI writer.Write(Main.worldID); writer.Write(0 + (WorldGen.shadowOrbSmashed ? 1 : 0) + (NPC.downedBoss1 ? 2 : 0) + (NPC.downedBoss2 ? 4 : 0) + (NPC.downedBoss3 ? 8 : 0)); writer.Write(Main.worldName); - var length = stream.Position - 5; + var length = (int)(stream.Position - 5); stream.Position = 0; writer.Write(length); try