/// <summary> /// Leaving the specified player and forAnotherRegion. /// </summary> /// <param name='player'> /// Player. /// </param> /// <param name='forAnotherRegion'> /// If going into another region dont tell the player, leaving /// </param> internal virtual void Leaving(Client player, WorldRegion nextRegion) { if (Type == SpawnRegion.Type) { SpawnRegion.Leaving(player); } if (Type == SpawnTimeRegion.Type) { SpawnTimeRegion.Leaving(player); return; } Log.WriteRegion(player, this, false); if (nextRegion == null || nextRegion.SubRegions != null && nextRegion.SubRegions.Contains(this)) { player.TellAbove(Chat.Gray, "Leaving " + Name); } if (player.Settings.Cloaked != null) { return; } if (ReportVisits == false) { return; } TellResidentsSystem(player, Chat.Gray, player.Name + " left " + Name + " " + FromDirection(player.Session.Position)); }
static internal void Leaving(Client player) { //Resume outside weather player.SendToClient(World.Main.Weather); player.TellAbove(Chat.Aqua, "Chat range: " + Parser.DistanceMax + " blocks"); }
public static bool Trigger(Client player, WorldRegion r) { #if DEBUG player.TellAbove("DEBUG: ", "You triggered the ban"); #else player.BanByServer(DateTime.Now.AddMinutes(30), r.Name); #endif return(true); }
public static bool Trigger(Client player, WorldRegion r) { #if DEBUG player.TellAbove("DEBUG: ", "You triggered the ban"); #else player.BanByServer(DateTime.Now.AddMinutes(30), r.Name); #endif return true; }
internal virtual void Entering(Client player) { if (Type == SpawnRegion.Type) { SpawnRegion.Entering(player); } if (Type == SpawnTimeRegion.Type) { SpawnTimeRegion.Entering(player); return; } Log.WriteRegion(player, this, true); Regions.WarpPortalVisuals.EnterRegion(player, this); //Region message if (Message != null) { player.TellAbove(Chat.DarkAqua + "[region] ", Message); } else { player.TellAbove(Chat.DarkAqua, "Entering " + Name); } if (player.Settings.Cloaked != null) { return; } if (ReportVisits == false) { return; } string message = player.Name + " entered " + ColorName + " " + FromDirection(player.Session.Position); #if DEBUG player.TellSystem("DEBUG " + Chat.Blue, message); #endif TellResidentsSystem(player, Chat.Blue, message); }
static bool DiggProtect(Client player, PlayerDigging pd) { if (pd.Status == PlayerDigging.StatusEnum.FinishedDigging) { BlockChange bc = new BlockChange(pd.Position.Offset(pd.Face), BlockID.Fire); player.SendToClient(bc); player.TellAbove(Chat.Purple, "You are still in spawn"); return(true); } return(false); }
static bool DiggProtect(Client player, PlayerDigging pd) { if (pd.Status == PlayerDigging.StatusEnum.FinishedDigging) { BlockChange bc = new BlockChange(pd.Position.Offset(pd.Face), BlockID.Fire); player.SendToClient(bc); player.TellAbove(Chat.Purple, "You are still in spawn"); return true; } return false; }