Server passwords are disabled, moving this to TShock handling soon.

Change stat tracker mono detection
Fixed collision check to ignore tileSolidTop
This commit is contained in:
Zidonuke 2011-12-28 10:56:45 -05:00
parent 08069c6f97
commit 37c550c167
3 changed files with 14 additions and 18 deletions

View file

@ -2477,7 +2477,7 @@ namespace TShockAPI
return;
}
if (args.Player.mute)
args.Player.SendMessage("You Are Muted! You Need To Be Unmuted!!");
args.Player.SendMessage("You are muted.");
else
TShock.Utils.Broadcast(string.Format("*{0} {1}", args.Player.Name, String.Join(" ", args.Parameters)), 205, 133, 63);
}
@ -2492,7 +2492,7 @@ namespace TShockAPI
int playerTeam = args.Player.Team;
if (args.Player.mute)
args.Player.SendMessage("You Are Muted! You Need To Be Unmuted!!");
args.Player.SendMessage("You are muted.");
else if (playerTeam != 0)
{
string msg = string.Format("<{0}> {1}", args.Player.Name, String.Join(" ", args.Parameters));
@ -2524,18 +2524,18 @@ namespace TShockAPI
{
var plr = players[0];
plr.mute = false;
plr.SendMessage("You Have Been UnMuted! Thank " + args.Player.Name);
TShock.Utils.Broadcast(plr.Name + " Has Been Unmuted By " + args.Player.Name, Color.Yellow);
plr.SendMessage("You have been unmuted.");
TShock.Utils.Broadcast(plr.Name + " has been unmuted by " + args.Player.Name, Color.Yellow);
}
else if (!players[0].Group.HasPermission(Permissions.mute))
{
var plr = players[0];
plr.mute = true;
plr.SendMessage("You Have Been Muted! You Should Have Behaved...");
TShock.Utils.Broadcast(plr.Name + " Has Been Muted By " + args.Player.Name, Color.Yellow);
plr.SendMessage("You have been muted.");
TShock.Utils.Broadcast(plr.Name + " has been muted by " + args.Player.Name, Color.Yellow);
}
else
args.Player.SendMessage("You Cannot Mute Player");
args.Player.SendMessage("You cannot mute this player.");
}
@ -2567,7 +2567,7 @@ namespace TShockAPI
args.Player.SendMessage("More than one player matched!", Color.Red);
}
else if (args.Player.mute)
args.Player.SendMessage("You Are Muted! You Need To Be Unmuted!!");
args.Player.SendMessage("You are muted.");
else
{
var plr = players[0];
@ -2582,7 +2582,7 @@ namespace TShockAPI
private static void Reply(CommandArgs args)
{
if (args.Player.mute)
args.Player.SendMessage("You Are Muted! You Need To Be Unmuted!!");
args.Player.SendMessage("You are muted.");
else if (args.Player.LastWhisper != null)
{
var msg = string.Join(" ", args.Parameters);

View file

@ -51,10 +51,6 @@ namespace TShockAPI
tr.Close();
}
string mono = "false";
if (Type.GetType("Mono.Runtime") != null)
mono = "true";
using (var client = new WebClient())
{
client.Headers.Add("user-agent",
@ -64,11 +60,11 @@ namespace TShockAPI
string response;
if (TShock.Config.DisablePlayerCountReporting)
{
response = client.DownloadString("http://tshock.co/tickto.php?do=log&fp=" + fp + "&ver=" + TShock.VersionNum + "&os=" + System.Environment.OSVersion.ToString() + "&mono=" + mono + "&port=" + Netplay.serverPort + "&plcount=0");
response = client.DownloadString("http://tshock.co/tickto.php?do=log&fp=" + fp + "&ver=" + TShock.VersionNum + "&os=" + System.Environment.OSVersion.ToString() + "&mono=" + Main.runningMono + "&port=" + Netplay.serverPort + "&plcount=0");
}
else
{
response = client.DownloadString("http://tshock.co/tickto.php?do=log&fp=" + fp + "&ver=" + TShock.VersionNum + "&os=" + System.Environment.OSVersion.ToString() + "&mono=" + mono + "&port=" + Netplay.serverPort + "&plcount=" + TShock.Utils.ActivePlayers());
response = client.DownloadString("http://tshock.co/tickto.php?do=log&fp=" + fp + "&ver=" + TShock.VersionNum + "&os=" + System.Environment.OSVersion.ToString() + "&mono=" + Main.runningMono + "&port=" + Netplay.serverPort + "&plcount=" + TShock.Utils.ActivePlayers());
}
Log.ConsoleInfo("Stat Tracker: " + response + "\n");
}

View file

@ -643,7 +643,7 @@ namespace TShockAPI
}
else if (tsplr.mute)
{
tsplr.SendMessage("You Are Muted! You Need To Be Unmuted!!");
tsplr.SendMessage("You are muted!");
e.Handled = true;
}
}
@ -1220,7 +1220,7 @@ namespace TShockAPI
{
for (int h = y; h < y + 4; h++)
{
if (!Main.tile[i, h].active || !Main.tileSolid[Main.tile[i, h].type])
if (!Main.tile[i, h].active || !Main.tileSolid[Main.tile[i, h].type] || Main.tileSolidTop[Main.tile[i, h].type])
return false;
}
}
@ -1249,7 +1249,7 @@ namespace TShockAPI
if (file.MaxSlots > 235)
file.MaxSlots = 235;
Main.maxNetPlayers = file.MaxSlots + 20;
Netplay.password = "";
Netplay.spamCheck = false;
RconHandler.Password = file.RconPassword;