Format issues and tile place check for walls
This commit is contained in:
parent
3e9c88685e
commit
11a85dc817
2 changed files with 10 additions and 8 deletions
|
|
@ -1750,7 +1750,7 @@ namespace TShockAPI
|
|||
return true;
|
||||
}
|
||||
|
||||
if (type == 1 && !args.Player.Group.HasPermission(Permissions.ignoreplacetiledetection))
|
||||
if ( ( type == 1 || type == 3 ) && !args.Player.Group.HasPermission(Permissions.ignoreplacetiledetection))
|
||||
{
|
||||
args.Player.TilePlaceThreshold++;
|
||||
var coords = new Vector2(tileX, tileY);
|
||||
|
|
|
|||
|
|
@ -1289,6 +1289,7 @@ namespace TShockAPI
|
|||
{
|
||||
if (TShock.Config.AllowIce && actionType != 1)
|
||||
{
|
||||
|
||||
foreach (Point p in player.IceTiles)
|
||||
{
|
||||
if (p.X == tileX && p.Y == tileY && (Main.tile[p.X, p.Y].type == 0 || Main.tile[p.X, p.Y].type == 127))
|
||||
|
|
@ -1297,11 +1298,12 @@ namespace TShockAPI
|
|||
return false;
|
||||
}
|
||||
}
|
||||
if (((DateTime.Now.Ticks / TimeSpan.TicksPerMillisecond) - player.BPm) > 2000){
|
||||
player.SendMessage("You do not have permission to build!", Color.Red);
|
||||
player.BPm=DateTime.Now.Ticks / TimeSpan.TicksPerMillisecond;
|
||||
|
||||
}
|
||||
if (((DateTime.Now.Ticks / TimeSpan.TicksPerMillisecond) - player.BPm) > 2000){
|
||||
player.SendMessage("You do not have permission to build!", Color.Red);
|
||||
player.BPm=DateTime.Now.Ticks / TimeSpan.TicksPerMillisecond;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
@ -1311,11 +1313,11 @@ namespace TShockAPI
|
|||
return false;
|
||||
}
|
||||
|
||||
if (((DateTime.Now.Ticks / TimeSpan.TicksPerMillisecond) - player.BPm) > 2000){
|
||||
if (((DateTime.Now.Ticks / TimeSpan.TicksPerMillisecond) - player.BPm) > 2000){
|
||||
player.SendMessage("You do not have permission to build!", Color.Red);
|
||||
player.BPm=DateTime.Now.Ticks / TimeSpan.TicksPerMillisecond;
|
||||
player.BPm=DateTime.Now.Ticks / TimeSpan.TicksPerMillisecond;
|
||||
}
|
||||
|
||||
}
|
||||
return true;
|
||||
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue