|
You last visited: Today at 16:52
Advertisement
[Release]Massive list of commands!
Discussion on [Release]Massive list of commands! within the CO2 PServer Guides & Releases forum part of the CO2 Private Server category.
07/17/2010, 00:19
|
#16
|
elite*gold: 0
Join Date: Mar 2007
Posts: 13
Received Thanks: 0
|
Quote:
Originally Posted by grillmad
chat.cs
|
i did
i changed it to this :
Code:
using System;
using System.Collections.Generic;
using System.Collections;
using System.Linq;
using System.Threading;
using System.Text;
using System.IO;
namespace NewestCOServer.PacketHandling
{
public class Chat
{
public static void Handle(Main.GameClient GC, byte[] Data)
{
MemoryStream MS = new MemoryStream(Data);
BinaryReader BR = new BinaryReader(MS);
BR.ReadBytes(8);
ushort ChatType = (ushort)BR.ReadUInt32();
BR.ReadBytes(13);
string From = Encoding.ASCII.GetString(BR.ReadBytes(BR.ReadByte()));
string To = Encoding.ASCII.GetString(BR.ReadBytes(BR.ReadByte()));
BR.ReadByte();
string Message = Encoding.ASCII.GetString(BR.ReadBytes(BR.ReadByte()));
BR.Close();
MS.Close();
#region BadWords
Message = Message.Replace("damn", "****");
Message = Message.Replace("fuck", "****");
Message = Message.Replace("shit", "****");
Message = Message.Replace("stupid", "******");
Message = Message.Replace("wtf", "***");
Message = Message.Replace("idiot", "*****");
Message = Message.Replace("fucker", "******");
#endregion
if (ChatType == 2104 && GC.MyChar.MyShop != null)
GC.MyChar.MyShop.Hawk = Message;
try
{
if (Message[0] == '/')
{
string[] Cmd = Message.Split(' ');
#region Disconnect Command - /dc
if (Cmd[0] == "/dc")
{
GC.Disconnect();
return;
}
#endregion
#region Whisper all players Command - /whsp [PM ONLY]
if (Cmd[0] == "/whsp")
{
if (GC.AuthInfo.Status == "[PM]")
{
Game.World.SendMsgToAll("SYSTEM", Message.Remove(0, 6), 2001, 0);
}
}
#endregion
#region Scroll to city's Command - /scroll
if (Cmd[0] == "/scroll")
{
if (Cmd[1] == "tc")
{
GC.MyChar.Teleport(1002, 431, 379);
}
if (Cmd[1] == "gmspot")
{
GC.MyChar.Teleport(1009, 025, 023);
}
if (Cmd[1] == "tg")
{
GC.MyChar.Teleport(1039, 200, 200);
}
if (Cmd[1] == "ja")
{
GC.MyChar.Teleport(6000, 30, 75);
}
if (Cmd[1] == "am")
{
GC.MyChar.Teleport(1020, 567, 576);
}
if (Cmd[1] == "dc")
{
GC.MyChar.Teleport(1000, 500, 650);
}
if (Cmd[1] == "mc")
{
GC.MyChar.Teleport(1001, 316, 642);
}
if (Cmd[1] == "bi")
{
GC.MyChar.Teleport(1015, 723, 573);
}
if (Cmd[1] == "pc")
{
GC.MyChar.Teleport(1011, 190, 271);
}
if (Cmd[1] == "ma")
{
GC.MyChar.Teleport(1036, 200, 200);
}
if (Cmd[1] == "pka")
{
GC.MyChar.Teleport(1005, 052, 069);
}
if (Cmd[1] == "lotto")
{
GC.MyChar.Teleport(700, 052, 069);
}
if (Cmd[1] == "qmap")
{
GC.MyChar.Teleport(1844, 150, 162);
}
}
#endregion
#region Broadcast Command - /bc [PM ONLY]
if (Cmd[0] == "/bc")
{
if (GC.AuthInfo.Status == "[PM]")
{
Game.World.SendMsgToAll(GC.MyChar.Name, Message.Remove(0, 4), 2500, 0);
}
}
#endregion
#region Send message 2010 Command - /ccc [PM ONLY]
if (Cmd[0] == "/ccc")
{
if (GC.AuthInfo.Status == "[PM]")
{
Game.World.SendMsgToAll(GC.MyChar.Name, GC.MyChar.Name + ": " + Message.Remove(0, 3), 2010, 0);
}
}
#endregion
#region Revive another player Command - /reviver playername [PM AND GM ONLY]
if (Cmd[0] == "/revive")
{
if (GC.AuthInfo.Status == "[PM]" ||GC.AuthInfo.Status == "[GM")
{
Game.Character Target = Game.World.CharacterFromName(Cmd[1]);
if (Target != null)
{
Target.Ghost = false;
Target.BlueName = false;
Target.CurHP = (ushort)Target.MaxHP;
Target.Alive = true;
Target.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.Dead);
Target.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.BlueName);
Target.Body = Target.Body;
Target.Hair = Target.Hair;
Target.Equips.Send(Target.MyClient, false);
}
}
}
#endregion
#region Kill whole map Command - /killmap mapid [PM ONLY]
if (Cmd[0] == "/killmap")
{
if (GC.AuthInfo.Status == "[PM]")
{
foreach (Game.Character Target in Game.World.H_Chars.Values)
{
if (Target.Loc.Map == ushort.Parse(Cmd[1]))
{
Target.Ghost = true;
Target.BlueName = false;
Target.CurHP = 0;
Target.Alive = false;
Target.Equips.Send(Target.MyClient, true);
Target.StatEff.Remove(StatusEffectEn.Cyclone);
Target.StatEff.Remove(StatusEffectEn.FatalStrike);
Target.StatEff.Remove(StatusEffectEn.BlueName);
Target.StatEff.Remove(StatusEffectEn.Flashy);
Target.StatEff.Remove(StatusEffectEn.ShurikenVortex);
Target.BlueName = false;
Target.StatEff.Remove(StatusEffectEn.SuperMan);
Target.StatEff.Remove(StatusEffectEn.XPStart);
Target.StatEff.Remove(StatusEffectEn.Ride);
Target.StatEff.Add(StatusEffectEn.Dead);
Target.DeathHit = DateTime.Now;
Game.World.SendMsgToAll("SYSTEM", "" + GC.MyChar.Name + " has just owned everyone on the map with the ID of " + Cmd[1] + "", 2011, 0);
}
}
}
}
#endregion
#region Revive whole map Command - /revmap mapid [PM ONLY]
if (Cmd[0] == "/revmap")
{
if (GC.AuthInfo.Status == "[PM]")
{
foreach (Game.Character Target in Game.World.H_Chars.Values)
{
if (Target.Loc.Map == ushort.Parse(Cmd[1]))
{
Target.Ghost = false;
Target.BlueName = false;
Target.CurHP = (ushort)Target.MaxHP;
Target.Alive = true;
Target.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.Dead);
Target.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.BlueName);
Target.Body = Target.Body;
Target.Hair = Target.Hair;
Target.Equips.Send(Target.MyClient, false);
Game.World.SendMsgToAll("SYSTEM", "" + GC.MyChar.Name + " has just revived everyone on the map with the ID of " + Cmd[1] + "", 2011, 0);
}
}
}
}
#endregion
#region Revive yourself Command - /rev [PM ONLY]
if (Cmd[0] == "/rev")
{
if (GC.AuthInfo.Status == "[PM]")
{
GC.MyChar.Ghost = false;
GC.MyChar.BlueName = false;
GC.MyChar.CurHP = (ushort)GC.MyChar.MaxHP;
GC.MyChar.Alive = true;
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.Dead);
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.BlueName);
GC.MyChar.Body = GC.MyChar.Body;
GC.MyChar.Hair = GC.MyChar.Hair;
GC.MyChar.Equips.Send(GC, false);
}
}
#endregion
#region Kill a player Command - /pwn playername [PM AND GM ONLY]
if (Cmd[0] == "/pwn")
{
if (GC.AuthInfo.Status == "[PM]" || GC.AuthInfo.Status == "[GM]")
{
Game.Character Target = Game.World.CharacterFromName(Cmd[1]);
if (Target != null)
{
Target.Ghost = true;
Target.BlueName = false;
Target.CurHP = 0;
Target.Alive = false;
Target.Equips.Send(Target.MyClient, true);
Target.StatEff.Remove(StatusEffectEn.Cyclone);
Target.StatEff.Remove(StatusEffectEn.FatalStrike);
Target.StatEff.Remove(StatusEffectEn.BlueName);
Target.StatEff.Remove(StatusEffectEn.Flashy);
Target.StatEff.Remove(StatusEffectEn.ShurikenVortex);
Target.BlueName = false;
Target.StatEff.Remove(StatusEffectEn.SuperMan);
Target.StatEff.Remove(StatusEffectEn.XPStart);
Target.StatEff.Remove(StatusEffectEn.Ride);
Target.StatEff.Add(StatusEffectEn.Dead);
Target.DeathHit = DateTime.Now;
}
}
}
#endregion
#region Kill yourself Command - /sucide OR /die
if (Cmd[0] == "/sucide" || Cmd[0] == "/die")
{
if (GC.MyChar.BlueName == false)
{
GC.MyChar.Ghost = true;
GC.MyChar.CurHP = 0;
GC.MyChar.Alive = false;
GC.MyChar.Equips.Send(GC.MyChar.MyClient, true);
GC.MyChar.StatEff.Remove(StatusEffectEn.Cyclone);
GC.MyChar.StatEff.Remove(StatusEffectEn.FatalStrike);
GC.MyChar.StatEff.Remove(StatusEffectEn.BlueName);
GC.MyChar.StatEff.Remove(StatusEffectEn.Flashy);
GC.MyChar.StatEff.Remove(StatusEffectEn.ShurikenVortex);
GC.MyChar.BlueName = false;
GC.MyChar.StatEff.Remove(StatusEffectEn.SuperMan);
GC.MyChar.StatEff.Remove(StatusEffectEn.XPStart);
GC.MyChar.StatEff.Remove(StatusEffectEn.Ride);
GC.MyChar.StatEff.Add(StatusEffectEn.Dead);
GC.MyChar.DeathHit = DateTime.Now;
}
else if (GC.MyChar.Loc.Map == 1950 || GC.MyChar.PKPoints >= 30)
{
return;
}
else
{
return;
}
}
#endregion
#region Special effect Command - /seffect effect [PM ONLY]
if (Cmd[0] == "/seffect")
{
if (GC.AuthInfo.Status == "[PM]")
{
if (Cmd[1] == "pm")
{
GC.MyChar.StatEff.Add(ProjectToxicCo.Game.StatusEffectEn.TopWaterTaoist);
}
if (Cmd[1] == "rpm")
{
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.TopWaterTaoist);
}
if (Cmd[1] == "gm")
{
GC.MyChar.StatEff.Add(ProjectToxicCo.Game.StatusEffectEn.TopWarrior);
}
if (Cmd[1] == "rgm")
{
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.TopWarrior);
}
if (Cmd[1] == "blueflag")
{
GC.MyChar.StatEff.Add(ProjectToxicCo.Game.StatusEffectEn.TopArcher);
}
if (Cmd[1] == "rblueflag")
{
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.TopArcher);
}
if (Cmd[1] == "redflag")
{
GC.MyChar.StatEff.Add(ProjectToxicCo.Game.StatusEffectEn.TopFireTaoist);
}
if (Cmd[1] == "rredflag")
{
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.TopFireTaoist);
}
if (Cmd[1] == "redteam")
{
GC.MyChar.StatEff.Add(ProjectToxicCo.Game.StatusEffectEn.TopNinja);
}
if (Cmd[1] == "rredteam")
{
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.TopNinja);
}
if (Cmd[1] == "blueteam")
{
GC.MyChar.StatEff.Add(ProjectToxicCo.Game.StatusEffectEn.TopDeputyLeader);
}
if (Cmd[1] == "rblueteam")
{
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.TopDeputyLeader);
}
}
}
#endregion
#region Alert all players Command - /al message [PM ONLY]
if (Cmd[0] == "/al")
{
if (GC.AuthInfo.Status == "[PM]")
{
Game.World.SendMsgToAll(GC.MyChar.Name, Message.Remove(0, 4), 2500, 0);
Game.World.SendMsgToAll(GC.MyChar.Name, Message.Remove(0, 3), 2010, 0);
Game.World.SendMsgToAll(GC.MyChar.Name, Message.Remove(0, 3), 2011, 0);
Game.World.SendMsgToAll(GC.MyChar.Name, Message.Remove(0, 3), 2012, 0);
}
}
#endregion
#region End Guildwar Command - /endgw [PM ONLY]
if (Cmd[0] == "/endgw")
{
if (GC.AuthInfo.Status == "[PM]")
Features.GuildWars.EndWar();
}
#endregion
#region Change body (apperance) Command - /body body [PM ONLY]
if (Cmd[0] == "/body")
{
if (GC.AuthInfo.Status == "[PM]" || GC.AuthInfo.Status == "[PM]")
{
if (Cmd[1] == "whitetiger")
{
GC.MyChar.Body = 384;
}
if (Cmd[1] == "yellowtiger")
{
GC.MyChar.Body = 385;
}
if (Cmd[1] == "redtiger")
{
GC.MyChar.Body = 386;
}
if (Cmd[1] == "smale")
{
GC.MyChar.Body = 1003;
}
if (Cmd[1] == "lmale")
{
GC.MyChar.Body = 1004;
}
if (Cmd[1] == "sfemale")
{
GC.MyChar.Body = 2001;
}
if (Cmd[1] == "lfemale")
{
GC.MyChar.Body = 2002;
}
if (Cmd[1] == "guard")
{
GC.MyChar.Body = 900;
}
if (Cmd[1] == "guard2")
{
GC.MyChar.Body = 910;
}
if (Cmd[1] == "guard3")
{
GC.MyChar.Body = 920;
}
if (Cmd[1] == "nd")
{
GC.MyChar.Body = 377;
}
if (Cmd[1] == "satan")
{
GC.MyChar.Body = 166;
}
if (Cmd[1] == "vampire")
{
GC.MyChar.Body = 111;
}
if (Cmd[1] == "bunny")
{
GC.MyChar.Body = 222;
}
if (Cmd[1] == "bunny2")
{
GC.MyChar.Body = 224;
}
if (Cmd[1] == "bunny3")
{
GC.MyChar.Body = 225;
}
if (Cmd[1] == "fairy")
{
GC.MyChar.Body = 130;
}
if (Cmd[1] == "pig")
{
GC.MyChar.Body = 215;
}
if (Cmd[1] == "titan")
{
GC.MyChar.Body = 153;
}
if (Cmd[1] == "pluto")
{
GC.MyChar.Body = 168;
}
if (Cmd[1] == "revenant")
{
GC.MyChar.Body = 265;
}
if (Cmd[1] == "eidolon")
{
GC.MyChar.Body = 266;
}
if (Cmd[1] == "troll")
{
GC.MyChar.Body = 353;
}
if (Cmd[1] == "soldier")
{
GC.MyChar.Body = 263;
}
if (Cmd[1] == "phantom")
{
GC.MyChar.Body = 363;
}
if (Cmd[1] == "spearman")
{
GC.MyChar.Body = 165;
}
if (Cmd[1] == "titan")
{
GC.MyChar.Body = 153;
}
if (Cmd[1] == "gano")
{
GC.MyChar.Body = 133;
}
if (Cmd[1] == "phe")
{
GC.MyChar.Body = 104;
}
if (Cmd[1] == "ghost")
{
GC.MyChar.Body = 1098;
}
}
}
#endregion
#region Unlimited xp skill Command - /xp xpskillname [PM ONLY]
if (Cmd[0] == "/xp")
{
if (GC.AuthInfo.Status == "[PM]")
{
if (Cmd[1] == "smon")
{
GC.MyChar.StatEff.Add(ProjectToxicCo.Game.StatusEffectEn.SuperMan);
}
else if (Cmd[1] == "smoff")
{
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.SuperMan);
}
else if (Cmd[1] == "fatalon")
{
GC.MyChar.StatEff.Add(ProjectToxicCo.Game.StatusEffectEn.FatalStrike);
}
else if (Cmd[1] == "fataloff")
{
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.FatalStrike);
}
else if (Cmd[1] == "flyon")
{
GC.MyChar.StatEff.Add(ProjectToxicCo.Game.StatusEffectEn.Fly);
}
else if (Cmd[1] == "flyoff")
{
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.Fly);
}
else if (Cmd[1] == "ivon")
{
GC.MyChar.StatEff.Add(ProjectToxicCo.Game.StatusEffectEn.Invisible);
}
else if (Cmd[1] == "ivoff")
{
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.Invisible);
}
else if (Cmd[1] == "accon")
{
GC.MyChar.StatEff.Add(ProjectToxicCo.Game.StatusEffectEn.Accuracy);
}
else if (Cmd[1] == "accoff")
{
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.Accuracy);
}
if (Cmd[1] == "speedon")
{
GC.MyChar.StatEff.Add(ProjectToxicCo.Game.StatusEffectEn.Cyclone);
}
else if (Cmd[1] == "speedoff")
{
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.Cyclone);
}
if (Cmd[1] == "alloff")
{
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.SuperMan);
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.FatalStrike);
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.Fly);
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.Invisible);
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.Accuracy);
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.Cyclone);
GC.AddSend(Packets.ChatMessage(0, "SYSTEM", GC.MyChar.Name, "All XP skills have been turned off", 2001, 0));
}
if (Cmd[1] == "help")
{
GC.AddSend(Packets.ChatMessage(0, "SYSTEM", GC.MyChar.Name, "/xp skills.", 2001, 0));
GC.AddSend(Packets.ChatMessage(0, "SYSTEM", GC.MyChar.Name, "SuperMan: /xp smon / /xp smoff", 2001, 0));
GC.AddSend(Packets.ChatMessage(0, "SYSTEM", GC.MyChar.Name, "Fatal Strike: /xp fatalon / /xp fataloff", 2001, 0));
GC.AddSend(Packets.ChatMessage(0, "SYSTEM", GC.MyChar.Name, "Fly: /xp flyon / /xp flyoff", 2001, 0));
GC.AddSend(Packets.ChatMessage(0, "SYSTEM", GC.MyChar.Name, "Invisible: /xp ivon / /xp ivoff", 2001, 0));
GC.AddSend(Packets.ChatMessage(0, "SYSTEM", GC.MyChar.Name, "Accuracy: /xp accon / /xp accoff", 2001, 0));
GC.AddSend(Packets.ChatMessage(0, "SYSTEM", GC.MyChar.Name, "Cyclone: /xp speedon / /xp speedoff)", 2001, 0));
GC.AddSend(Packets.ChatMessage(0, "SYSTEM", GC.MyChar.Name, "Turn off all xp skills: /xp alloff", 2001, 0));
}
}
}
#endregion
#region How many people online Command - /playercount
if (Cmd[0] == "/playercount")
{
GC.LocalMessage(2011, "Players Online: " + Game.World.H_Chars.Count);
}
#endregion
#region Day and Night Commands - /day, /night, /night2 [PM ONLY]
if (Cmd[0] == "/day")
{
if (GC.AuthInfo.Status == "[PM]")
{
Game.World.ScreenColor = 0;
foreach (Game.Character Target in Game.World.H_Chars.Values)
try
{
Target.MyClient.AddSend(Packets.GeneralData(Target.EntityID, Game.World.ScreenColor, 0, 0, 104));
}
catch { }
}
}
if (Cmd[0] == "/night")
{
if (GC.AuthInfo.Status == "[PM]")
{
Game.World.ScreenColor = 5855577;
foreach (Game.Character Target in Game.World.H_Chars.Values)
try
{
Target.MyClient.AddSend(Packets.GeneralData(Target.EntityID, Game.World.ScreenColor, 0, 0, 104));
}
catch { }
}
}
if (Cmd[0] == "/night1")
{
if (GC.AuthInfo.Status == "[PM]")
{
Game.World.ScreenColor = 5355577;
foreach (Game.Character Target in Game.World.H_Chars.Values)
try
{
Target.MyClient.AddSend(Packets.GeneralData(Target.EntityID, Game.World.ScreenColor, 0, 0, 104));
}
catch { }
}
}
if (Cmd[0] == "/night2")
{
if (GC.AuthInfo.Status == "[PM]")
{
Game.World.ScreenColor = 6908265;
foreach (Game.Character Target in Game.World.H_Chars.Values)
try
{
Target.MyClient.AddSend(Packets.GeneralData(Target.EntityID, Game.World.ScreenColor, 0, 0, 104));
}
catch { }
}
}
#endregion
#region Ban a player Command - /ban playername [PM ONLY]
if (Cmd[0] == "/ban")
{
if (GC.AuthInfo.Status == "[PM]")
{
Game.Character C = Game.World.CharacterFromName(Cmd[1]);
if (C != null)
Database.AddBan(C.AccountName);
C.MyClient.Disconnect();
}
}
#endregion
#region Give CPs to player - /acps playername [PM ONLY]
if (Cmd[0] == "/acps")
{
if (GC.AuthInfo.Status == "[PM]")
{
Game.Character C = Game.World.CharacterFromName(Cmd[1]);
if (C != null)
C.CPs += uint.Parse(Cmd[2]);
}
}
#endregion
#region Remove CPs from player Command - /rcps playername [PM ONLY]
if (Cmd[0] == "/rcps")
{
if (GC.AuthInfo.Status == "[PM]")
{
Game.Character C = Game.World.CharacterFromName(Cmd[1]);
if (C != null)
C.CPs -= uint.Parse(Cmd[2]);
}
}
#endregion
#region Twincity monsters drop certian Item Command - /dropevent itemname[PM ONLY]
if (Cmd[0] == "/dropevent")
{
if (GC.AuthInfo.Status == "[PM]")
{
try
{
if (Program.DropEventTimer == null)
{
bool start = true;
if (Cmd[1].ToLower() == "dragonball")
{
Program.DropEventType = "dragonball";
Program.SaveOldRate = DropRates.DragonBall;
DropRates.DragonBall = (DropRates.DragonBall * int.Parse(Cmd[3]));
}
else if (Cmd[1].ToLower() == "meteor")
{
Program.DropEventType = "meteor";
Program.SaveOldRate = DropRates.Meteor;
DropRates.Meteor = (DropRates.Meteor * int.Parse(Cmd[3]));
}
else if (Cmd[1].ToLower() == "minicpbag")
{
Program.DropEventType = "minicpbag";
Program.SaveOldRate = DropRates.CPMiniBag;
DropRates.CPMiniBag = (DropRates.CPMiniBag == 0 ? 1 : DropRates.CPMiniBag * int.Parse(Cmd[3]));
}
else if (Cmd[1].ToLower() == "cpbag")
{
Program.DropEventType = "cpbag";
Program.SaveOldRate = DropRates.CPBag;
DropRates.CPBag = (DropRates.CPBag == 0 ? 1 : DropRates.CPBag * int.Parse(Cmd[3]));
}
else
start = false;
if (start)
{
Program.DropEventTimer = new System.Timers.Timer();
Program.DropEventTimer.Interval = (int.Parse(Cmd[2]) * 60000);
Program.DropEventTimer.Elapsed += new System.Timers.ElapsedEventHandler(Program.QuestDropDone);
Program.DropEventTimer.Start();
Game.World.SendMsgToAll("SYSTEM", "Monsters in TwinCity will drop " + Cmd[1] + "s " + Cmd[3] + "x for " + Cmd[2] + " minute(s).", 2011, 0);
}
else
GC.LocalMessage(2001, "Item name is not a dropevent!");
}
else
GC.LocalMessage(2001, "There is a running event, you must wait it end to start a new!");
}
catch { GC.LocalMessage(2001, "Wrongs values!"); GC.LocalMessage(2001, "Format: /dropevent ItemName Minutes Timers"); GC.LocalMessage(2001, "Example: /dropevent dragonball 15 1000 its in up the rates to 1000x in 15 minutes."); }
}
}
#endregion
#region Revive a player Command - /revive playername [PM OR GM ONLY]
if (Cmd[0] == "/revive")
{
if (GC.AuthInfo.Status == "[PM]")
{
Game.Character Target = Game.World.CharacterFromName(Cmd[1]);
if (Target != null && Target != GC.MyChar)
Target.Ghost = false;
Target.BlueName = false;
Target.CurHP = (ushort)GC.MyChar.MaxHP;
Target.CurMP = (ushort)GC.MyChar.MaxMP;
Target.Alive = true;
Target.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.Dead);
Target.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.BlueName);
Target.Body = GC.MyChar.Body;
Target.Hair = GC.MyChar.Hair;
Target.Equips.Send(GC, false);
}
}
#endregion
#region Arrest a player Command - /arrest playername [PM ONLY]
if (Cmd[0] == "/arrest")
{
if (GC.AuthInfo.Status == "[PM]")
{
Game.Character Target = Game.World.CharacterFromName(Cmd[1]);
if (Target != null && Target != GC.MyChar)
Target.Teleport(6000, 032, 072);
Target.PKPoints = 150;
Target.Trading = false;
Target.CurHP = 1;
Target.Stamina = 0;
Game.World.SendMsgToAll(" + C.Name + ", "I'm a Biggest Idiot and I win 130kp And im send to jail. " + GC.MyChar.Name + "[GM] Thanks.", 2011, 0);
}
}
#endregion
#region Set Str,Vit,Agi,Spi Command - /setstats statforall [PM ONLY]
if (Cmd[0] == "/setstats")
{
if (GC.AuthInfo.Status == "[PM]" || GC.AuthInfo.Status == "[GM]")
{
GC.MyChar.Str = byte.Parse(Cmd[1]);
GC.MyChar.Vit = byte.Parse(Cmd[1]);
GC.MyChar.Agi = byte.Parse(Cmd[1]);
GC.MyChar.Spi = byte.Parse(Cmd[1]);
}
}
#endregion
#region Clear inv Command - /clearinv
if (Cmd[0] == "/clearinv")
{
foreach (Game.Item Item in GC.MyChar.Inventory)
GC.AddSend(Packets.ItemPacket(Item.UID, 0, 3));
GC.MyChar.Inventory = new ArrayList(40);
}
#endregion
#region Get mana and HP Command - /life [PM AND GM ONLY]
if (Cmd[0] == "/life")
{
if (GC.AuthInfo.Status == "[PM]" || GC.AuthInfo.Status == "[GM]")
{
if (GC.MyChar.BlessingLasts == 0)
{
GC.MyChar.CurHP = /*(ushort)*/GC.MyChar.MaxHP;
GC.MyChar.CurMP = /*(ushort)*/GC.MyChar.MaxMP;
GC.MyChar.Stamina = 150;
}
else
{
GC.MyChar.CurHP = /*(ushort)*/GC.MyChar.MaxHP;
GC.MyChar.CurMP = /*(ushort)*/GC.MyChar.MaxMP;
GC.MyChar.Stamina = 150;
}
}
}
#endregion
#region Bring a player to you Command - /bring playername [GM AND PM]
if (Cmd[0] == "/bring")
{
if (GC.AuthInfo.Status == "[PM]" || GC.AuthInfo.Status == "[GM]")
{
Game.Character Target = Game.World.CharacterFromName(Cmd[1]);
if (Target != null)
Target.Teleport(GC.MyChar.Loc.Map, GC.MyChar.Loc.X += 3, GC.MyChar.Loc.Y += 3);
}
}
#endregion
#region Drop an item Command - /drop itemname [PM ONLY]
if (Cmd[0] == "/drop")
{
if (GC.AuthInfo.Status == "[PM]")
{
uint DropID = 0;
Random Rnd = new Random();
string DropWhat = Cmd[1].ToLower();
byte HowMany = (byte)Math.Min(ushort.Parse(Cmd[2]), (ushort)255);
switch (DropWhat)
{
case "dragonball": DropID = 1088000; break;
case "meteor": DropID = 1088001; break;
case "pointcard": DropID = 780000; break;
case "moonbox": DropID = 721080; break;
case "bag": DropID = 729910; break;
case "ball": DropID = 723834; break;
}
Game.DroppedItem DI = new Game.DroppedItem();
DI.DropTime = DateTime.Now;
DI.UID = (uint)Rnd.Next(10000000);
DI.Loc = new Game.Location();
DI.Loc.Map = GC.MyChar.Loc.Map;
DI.Info = new Game.Item();
DI.Info.ID = DropID;
DI.Info.UID = (uint)Rnd.Next(10000000);
for (int x = 0; x < HowMany; x++)
{
DI.Loc.X = (ushort)(GC.MyChar.Loc.X + Rnd.Next(15) - Rnd.Next(15));
DI.Loc.Y = (ushort)(GC.MyChar.Loc.Y + Rnd.Next(15) - Rnd.Next(15));
if (!DI.FindPlace((Hashtable)Game.World.H_Items[GC.MyChar.Loc.Map])) continue;
DI.Drop();
}
}
}
#endregion
#region Start guildwar Command - /gw [PM AND GM ONLY]
if (Cmd[0] == "/gw" && !Features.GuildWars.War)
{
if (GC.AuthInfo.Status == "[PM]" || GC.AuthInfo.Status == "[GM]")
{
Features.GuildWars.StartWar();
}
}
#endregion
#region EVERYONE take 1's off you Command - /invinsable [PM AND GM ONLY]
if (Cmd[0] == "/invinsable")
{
if (GC.AuthInfo.Status == "[PM]" || GC.AuthInfo.Status == "[GM]")
{
GC.MyChar.Protection = !GC.MyChar.Protection;
}
}
#endregion
#region Make an effect happen Command - /effect effectname [PM ONLY]
if (Cmd[0] == "/effect")
{
if (GC.AuthInfo.Status == "[PM]")
{
GC.AddSend(Packets.String(GC.MyChar.EntityID, 10, Cmd[1]));
}
}
#endregion
#region PKPoints remove/add Command - /pkp totalpkp [PM AND GM ONLY]
if (Cmd[0] == "/pkp")
{
if (GC.AuthInfo.Status == "[PM]" || GC.AuthInfo.Status == "[GM]")
{
GC.MyChar.PKPoints = ushort.Parse(Cmd[1]);
}
}
#endregion
#region 2011 Message Command - /c message [PM ONLY]
if (Cmd[0] == "/c")
{
if (GC.AuthInfo.Status == "[PM]")
{
}
}
#endregion
#region 2012 Message Command - /cc [PM ONLY]
if (Cmd[0] == "/cc")
{
if (GC.AuthInfo.Status == "[PM]")
Game.World.SendMsgToAll(GC.MyChar.Name, GC.MyChar.Name + ": " + Message.Remove(0, 3), 2012, 0);
}
#endregion
#region Steed Command - /steed steedid [GM OR PM ONLY]
if (Cmd[0] == "/steed")
{
if (GC.AuthInfo.Status == "[PM]" || GC.AuthInfo.Status == "[GM]")
{
Game.Item I = new ProjectToxicCo.Game.Item();
I.ID = 300000;
I.Plus = byte.Parse(Cmd[1]);
I.MaxDur = I.DBInfo.Durability;
I.CurDur = I.MaxDur;
I.Effect = ProjectToxicCo.Game.Item.RebornEffect.Horsie;
I.TalismanProgress = BitConverter.ToUInt32(new byte[4] { byte.Parse(Cmd[4]), byte.Parse(Cmd[3]), byte.Parse(Cmd[2]), 0 }, 0);
I.UID = (uint)Program.Rnd.Next(10000000);
GC.MyChar.AddItem(I);
}
}
#endregion
#region Mountsteed Command - /ridesteed [GM AND PM ONLY]
if (Cmd[0] == "/ridesteed")
{
if (GC.AuthInfo.Status == "[PM]" || GC.AuthInfo.Status == "[GM]")
{
GC.MyChar.StatEff.Add(ProjectToxicCo.Game.StatusEffectEn.Ride);
}
}
#endregion
#region Goto a player Command - /goto playername [PM AND GM ONLY]
if (Cmd[0] == "/goto")
{
if (GC.AuthInfo.Status == "[PM]" || GC.AuthInfo.Status == "[GM]")
{
Game.Character Target = Game.World.CharacterFromName(Cmd[1]);
if (Target != null)
GC.MyChar.Teleport(Target.Loc.Map, Target.Loc.X += 3, Target.Loc.Y += 3);
}
}
#endregion
#region Give away VIP Command - /awardvip playername viplevel [PM ONLY]
if (Cmd[0] == "/awardvip")
{
if (GC.AuthInfo.Status == "[PM]")
{
Game.Character Target = Game.World.CharacterFromName(Cmd[1]);
if (Target != null)
{
Target.VipLevel = byte.Parse(Cmd[2]);
Target.SendScreen(Packets.ChatMessage(0, "SYSTEM", Target.Name, "Congratulations! Your vip level is " + Target.VipLevel + " Thanks for donating, ToxicCo.", 2001, 0));
}
}
}
#endregion
#region Give yourself VIP Command - /vip level
if (Cmd[0] == "/vip")
{
if (GC.AuthInfo.Status == "[PM]")
{
GC.MyChar.VipLevel = byte.Parse(Cmd[1]);
GC.AddSend(Packets.ChatMessage(0, "SYSTEM", GC.MyChar.Name, "Congratulations! Your vip level is " + GC.MyChar.VipLevel + " Thanks for donating, ToxicCo", 2001, 0));
}
}
#endregion
#region Quiz show (start) Command - /eventquiz [PM ONLY]
if (Cmd[0] == "/eventquiz")
{
if (GC.AuthInfo.Status == "[PM]")
{
if (!Features.QuizShow.QuizON)
Features.QuizShow.Start();
}
}
#endregion
#region Give yourself moonbox Command - /mb [PM AND GM ONLY]
if (Cmd[0] == "/mb")
{
if (GC.AuthInfo.Status == "[PM]")
{
GC.MyChar.AddItem(721080);
}
}
#endregion
#region Make XP full Command - /xp [PM AND GM ONLY]
if (Cmd[0] == "/xp")
{
if (GC.AuthInfo.Status == "[PM]" || GC.AuthInfo.Status == "[GM]")
{
GC.MyChar.StatEff.Add(ProjectToxicCo.Game.StatusEffectEn.XPStart);
GC.MyChar.Buffs.Add(new Game.Buff() { StEff = ProjectToxicCo.Game.StatusEffectEn.XPStart, Lasts = 20, Started = DateTime.Now, Eff = ProjectToxicCo.Features.SkillsClass.ExtraEffect.None });
}
}
#endregion
#region Give full mana Command - /mana [GM AND PM ONLY]
if (Cmd[0] == "/mana")
{
if (GC.AuthInfo.Status == "[PM]" || GC.AuthInfo.Status == "[GM]")
{
GC.MyChar.CurMP = (ushort)GC.MyChar.MaxMP;
}
}
#endregion
#region Give full hp Command - /hp [GM AND PM ONLY]
if (Cmd[0] == "/hp")
{
if (GC.AuthInfo.Status == "[PM]" || GC.AuthInfo.Status == "[GM]")
{
GC.MyChar.CurHP = (ushort)GC.MyChar.MaxHP;
}
}
#endregion
#region Give full stamina Command - /stamina [GM AND PM ONLY]
if (Cmd[0] == "/stamina")
{
if (GC.AuthInfo.Status == "[PM]")
{
GC.MyChar.Stamina = 255;
}
}
#endregion
#region Skill Command - /skill skillid
if (Cmd[0] == "/skill")
{
GC.MyChar.RWSkill(new Game.Skill() { ID = ushort.Parse(Cmd[1]), Lvl = byte.Parse(Cmd[2]), Exp = 0 });
}
#endregion
#region Prof Command - /prof profid
if (Cmd[0] == "/prof")
{
GC.MyChar.RWProf(new Game.Prof() { ID = ushort.Parse(Cmd[1]), Lvl = byte.Parse(Cmd[2]), Exp = 0 });
}
#endregion
#region Make you bluenamed or removes it Command - /blue [GM AND PM ONLY]
if (Cmd[0] == "/blue")
{
if (GC.AuthInfo.Status == "[PM]" || GC.AuthInfo.Status == "[GM]")
{
if (GC.MyChar.BlueName == true)
{
GC.MyChar.BlueName = false;
}
else
{
GC.MyChar.BlueName = true;
}
}
}
#endregion
#region Level's you up Command - /level 130
if (Cmd[0] == "/level")
{
if (Cmd[1] == "130")
{
GC.MyChar.Level = 130;
GC.MyChar.Experience = 0;
}
else if (GC.AuthInfo.Status == "[PM]")
{
GC.MyChar.Level = byte.Parse(Cmd[1]);
GC.MyChar.Experience = 0;
}
}
#endregion
#region Kick a player Command - /kick playername [PM ONLY]
if (Cmd[0] == "/kick")
{
if (GC.AuthInfo.Status == "[PM]")
{
Game.Character Target = Game.World.CharacterFromName(Cmd[1]);
if (Target != null)
{
Target.MyClient.Disconnect();
}
}
}
#endregion
#region Virute points show - /vp
if (Cmd[0] == "/vp")
{
GC.LocalMessage(2000, "You have " + GC.MyChar.VP + " virtue points.");
}
#endregion
#region Map id Command - /map [GM AND PM ONLY]
if (Cmd[0] == "/map")
{
if (GC.AuthInfo.Status == "[PM]" || GC.AuthInfo.Status == "[GM]")
{
GC.LocalMessage(2000, "The ID of the map you are on is " + GC.MyChar.Loc.Map);
}
}
#endregion
#region Change job Command - /job jobid
if (Cmd[0] == "/job")
{
GC.MyChar.Job = byte.Parse(Cmd[1]);
}
#endregion
#region Gives silvers to you Command - /silvers amount [GM AND PM ONLY]
if (Cmd[0] == "/silvers")
{
if (GC.AuthInfo.Status == "[PM]" || GC.AuthInfo.Status == "[GM]")
{
GC.MyChar.Silvers = uint.Parse(Cmd[1]);
}
}
#endregion
#region Gives CPs to you Command - /cps amount [GM AND PM ONLY]
if (Cmd[0] == "/cps")
{
if (GC.AuthInfo.Status == "[PM]" || GC.AuthInfo.Status == "[GM]")
{
GC.MyChar.CPs = uint.Parse(Cmd[1]);
}
}
#endregion
#region teleport Command - /mm cityID X Y
if (Cmd[0] == "/mm")
{
if (GC.MyChar.Loc.Map == 1950 || GC.MyChar.Loc.Map == 1080 || GC.MyChar.Loc.Map == 2020 || GC.MyChar.Loc.Map == 1038 || GC.MyChar.Loc.Map == 1047 || GC.MyChar.Loc.Map == 1037)
{
return;
}
else if (GC.AuthInfo.Status == "[PM]")
{
GC.MyChar.Teleport(ushort.Parse(Cmd[1]), ushort.Parse(Cmd[2]), ushort.Parse(Cmd[3]));
}
else
{
GC.MyChar.Teleport(ushort.Parse(Cmd[1]), ushort.Parse(Cmd[2]), ushort.Parse(Cmd[3]));
}
}
#endregion
#region Teleport a player to a city Command - /teleplayer tc [PM ONLY]
if (Cmd[0] == "/teleplayer")
{
if (GC.AuthInfo.Status == "[PM]")
{
Game.Character Target = World.CharacterFromName(Cmd[1]);
if (Target != null)
{
if (Cmd[2] == "tc")
{
Target.Teleport(1002, 430, 380);
}
}
else
{
return;
}
}
}
#endregion
#region Item Command - /item itemname etc etc etc 13 13 13
if (Cmd[0] == "/item")
{
uint ID = 0;
foreach (DatabaseItem DI in Database.DatabaseItems.Values)
if (DI.Name == Cmd[1])
{
ID = DI.ID;
Game.ItemIDManipulation e = new Game.ItemIDManipulation(ID);
Game.Item.ItemQuality Quality = e.Quality;
if (Cmd[2].ToLower() == "refined") Quality = Game.Item.ItemQuality.Refined;
else if (Cmd[2].ToLower() == "unique") Quality = Game.Item.ItemQuality.Unique;
else if (Cmd[2].ToLower() == "elite") Quality = Game.Item.ItemQuality.Elite;
else if (Cmd[2].ToLower() == "super") Quality = Game.Item.ItemQuality.Super;
else if (Cmd[2].ToLower() == "simple") Quality = Game.Item.ItemQuality.Simple;
else if (Cmd[2].ToLower() == "fixed") Quality = Game.Item.ItemQuality.Fixed;
else if (Cmd[2].ToLower() == "poor") Quality = Game.Item.ItemQuality.Poor;
else if (Cmd[2].ToLower() == "normal") Quality = Game.Item.ItemQuality.Normal;
if (e.Quality == Quality)
break;
}
if (ID != 0 && GC.MyChar.Inventory.Count < 40)
{
Game.ItemIDManipulation e = new Game.ItemIDManipulation(ID);
Game.Item.ItemQuality Quality = e.Quality;
bool change = true;
if (Cmd[2].ToLower() == "refined") Quality = Game.Item.ItemQuality.Refined;
else if (Cmd[2].ToLower() == "unique") Quality = Game.Item.ItemQuality.Unique;
else if (Cmd[2].ToLower() == "elite") Quality = Game.Item.ItemQuality.Elite;
else if (Cmd[2].ToLower() == "super") Quality = Game.Item.ItemQuality.Super;
else if (Cmd[2].ToLower() == "simple") Quality = Game.Item.ItemQuality.Simple;
else if (Cmd[2].ToLower() == "fixed") Quality = Game.Item.ItemQuality.Fixed;
else if (Cmd[2].ToLower() == "poor") Quality = Game.Item.ItemQuality.Poor;
else if (Cmd[2].ToLower() == "normal") Quality = Game.Item.ItemQuality.Normal;
else change = false;
if (change)
e.QualityChange(Quality);
ID = e.ToID();
if (!Database.DatabaseItems.ContainsKey(ID))
{
return;
}
Game.Item I = new ProjectToxicCo.Game.Item();
if (e.Part(0, 2) == 11 || e.Part(0, 2) == 13 || e.Part(0, 3) == 123 || e.Part(0, 3) == 141 || e.Part(0, 3) == 142)
I.Color = ProjectToxicCo.Game.Item.ArmorColor.Orange;
//I.FreeItem = true;
I.ID = ID;
I.UID = (uint)Program.Rnd.Next(10000000);
try
{
I.MaxDur = I.DBInfo.Durability;
I.CurDur = I.MaxDur;
}
catch (Exception Exc) { Program.WriteLine(Exc); }
try
{
I.Plus = byte.Parse(Cmd[3]);
}
catch { }
try
{
I.Bless = byte.Parse(Cmd[4]);
}
catch { }
try
{
I.Enchant = byte.Parse(Cmd[5]);
}
catch { }
try
{
I.Soc1 = (Game.Item.Gem)byte.Parse(Cmd[6]);
}
catch { }
try
{
I.Soc2 = (Game.Item.Gem)byte.Parse(Cmd[7]);
}
catch { }
I.Effect = ProjectToxicCo.Game.Item.RebornEffect.None;
GC.MyChar.AddItem(I);
}
}
#endregion
#region Summon pet - /pet [PM and GM only NOT WORKING]
if (Cmd[0] == "/pet")
{
// /pet HP atk name mech lvl
uint MinAttack = 0;
uint MaxAttack = 0;
short Level = 0;
uint SkillUses = 0;
uint CurHP = 0;
uint MaxHP = 0;
int Mesh = 0;
MinAttack = (uint.Parse(Cmd[1]));
MaxAttack = (uint.Parse(Cmd[2]));
Level = (short.Parse(Cmd[3]));
SkillUses = (uint.Parse(Cmd[4]));
CurHP = (uint.Parse(Cmd[5]));
MaxHP = (uint.Parse(Cmd[6]));
Mesh = (int.Parse(Cmd[7]));
string Name = (Cmd[8]);
// Game.Companion.Pet(Convert.ToInt16(GC.MyChar.Loc.X), Convert.ToInt16(GC.MyChar.Loc.Y), Convert.ToInt16(GC.MyChar.Loc.Map), MinAttack, MaxAttack, Level, SkillUses, CurHP, MaxHP, Mesh, Name, GC.MyChar.EntityID);
}
#endregion
#region FreezeSkill test Command - /freeze [PM ONLY]
if (Cmd[0] == "/freeze")
{
if (GC.AuthInfo.Status == "[PM]" || GC.AuthInfo.Status == "[GM]")
{
Game.Character Target = World.CharacterFromName(Cmd[1]);
{
Target.AtkMem.Attacking = false;
Target.Frozen = true;
Target.FrozenSeconds = int.Parse(Cmd[2] += 0);
Target.Frozentime = DateTime.Now;
Game.World.Spawns(Target, true);
}
}
}
#endregion
why it doesn't work 4 me ?
|
|
|
07/17/2010, 10:55
|
#17
|
elite*gold: 0
Join Date: May 2010
Posts: 298
Received Thanks: 57
|
Becuase you will encounter errors. Var's, methods etc...I am not releasing those to the public thats my bit not hard to code either so...
|
|
|
07/21/2010, 09:08
|
#18
|
elite*gold: 0
Join Date: Jun 2010
Posts: 12
Received Thanks: 0
|
if (Cmd[0] == "goo goo gaga goo goo")
{
switch (Cmd[1])
{
case "farts":
dun dun dun
break;
case "hisaga":
ti ni po ni
}
if this was true =P Thanks It kinda helped i guess, i don't really care how it's placed as long as it works - _ - !
}
if
you guys don't like it
[suck some ballz]
{
break;
}
}
|
|
|
08/13/2010, 00:21
|
#19
|
elite*gold: 0
Join Date: Feb 2006
Posts: 29
Received Thanks: 6
|
Quote:
Originally Posted by Figher9999
i did
i changed it to this :
Code:
using System;
using System.Collections.Generic;
using System.Collections;
using System.Linq;
using System.Threading;
using System.Text;
using System.IO;
namespace NewestCOServer.PacketHandling
{
public class Chat
{
public static void Handle(Main.GameClient GC, byte[] Data)
{
MemoryStream MS = new MemoryStream(Data);
BinaryReader BR = new BinaryReader(MS);
BR.ReadBytes(8);
ushort ChatType = (ushort)BR.ReadUInt32();
BR.ReadBytes(13);
string From = Encoding.ASCII.GetString(BR.ReadBytes(BR.ReadByte()));
string To = Encoding.ASCII.GetString(BR.ReadBytes(BR.ReadByte()));
BR.ReadByte();
string Message = Encoding.ASCII.GetString(BR.ReadBytes(BR.ReadByte()));
BR.Close();
MS.Close();
#region BadWords
Message = Message.Replace("damn", "****");
Message = Message.Replace("fuck", "****");
Message = Message.Replace("shit", "****");
Message = Message.Replace("stupid", "******");
Message = Message.Replace("wtf", "***");
Message = Message.Replace("idiot", "*****");
Message = Message.Replace("fucker", "******");
#endregion
if (ChatType == 2104 && GC.MyChar.MyShop != null)
GC.MyChar.MyShop.Hawk = Message;
try
{
if (Message[0] == '/')
{
string[] Cmd = Message.Split(' ');
#region Disconnect Command - /dc
if (Cmd[0] == "/dc")
{
GC.Disconnect();
return;
}
#endregion
#region Whisper all players Command - /whsp [PM ONLY]
if (Cmd[0] == "/whsp")
{
if (GC.AuthInfo.Status == "[PM]")
{
Game.World.SendMsgToAll("SYSTEM", Message.Remove(0, 6), 2001, 0);
}
}
#endregion
#region Scroll to city's Command - /scroll
if (Cmd[0] == "/scroll")
{
if (Cmd[1] == "tc")
{
GC.MyChar.Teleport(1002, 431, 379);
}
if (Cmd[1] == "gmspot")
{
GC.MyChar.Teleport(1009, 025, 023);
}
if (Cmd[1] == "tg")
{
GC.MyChar.Teleport(1039, 200, 200);
}
if (Cmd[1] == "ja")
{
GC.MyChar.Teleport(6000, 30, 75);
}
if (Cmd[1] == "am")
{
GC.MyChar.Teleport(1020, 567, 576);
}
if (Cmd[1] == "dc")
{
GC.MyChar.Teleport(1000, 500, 650);
}
if (Cmd[1] == "mc")
{
GC.MyChar.Teleport(1001, 316, 642);
}
if (Cmd[1] == "bi")
{
GC.MyChar.Teleport(1015, 723, 573);
}
if (Cmd[1] == "pc")
{
GC.MyChar.Teleport(1011, 190, 271);
}
if (Cmd[1] == "ma")
{
GC.MyChar.Teleport(1036, 200, 200);
}
if (Cmd[1] == "pka")
{
GC.MyChar.Teleport(1005, 052, 069);
}
if (Cmd[1] == "lotto")
{
GC.MyChar.Teleport(700, 052, 069);
}
if (Cmd[1] == "qmap")
{
GC.MyChar.Teleport(1844, 150, 162);
}
}
#endregion
#region Broadcast Command - /bc [PM ONLY]
if (Cmd[0] == "/bc")
{
if (GC.AuthInfo.Status == "[PM]")
{
Game.World.SendMsgToAll(GC.MyChar.Name, Message.Remove(0, 4), 2500, 0);
}
}
#endregion
#region Send message 2010 Command - /ccc [PM ONLY]
if (Cmd[0] == "/ccc")
{
if (GC.AuthInfo.Status == "[PM]")
{
Game.World.SendMsgToAll(GC.MyChar.Name, GC.MyChar.Name + ": " + Message.Remove(0, 3), 2010, 0);
}
}
#endregion
#region Revive another player Command - /reviver playername [PM AND GM ONLY]
if (Cmd[0] == "/revive")
{
if (GC.AuthInfo.Status == "[PM]" ||GC.AuthInfo.Status == "[GM")
{
Game.Character Target = Game.World.CharacterFromName(Cmd[1]);
if (Target != null)
{
Target.Ghost = false;
Target.BlueName = false;
Target.CurHP = (ushort)Target.MaxHP;
Target.Alive = true;
Target.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.Dead);
Target.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.BlueName);
Target.Body = Target.Body;
Target.Hair = Target.Hair;
Target.Equips.Send(Target.MyClient, false);
}
}
}
#endregion
#region Kill whole map Command - /killmap mapid [PM ONLY]
if (Cmd[0] == "/killmap")
{
if (GC.AuthInfo.Status == "[PM]")
{
foreach (Game.Character Target in Game.World.H_Chars.Values)
{
if (Target.Loc.Map == ushort.Parse(Cmd[1]))
{
Target.Ghost = true;
Target.BlueName = false;
Target.CurHP = 0;
Target.Alive = false;
Target.Equips.Send(Target.MyClient, true);
Target.StatEff.Remove(StatusEffectEn.Cyclone);
Target.StatEff.Remove(StatusEffectEn.FatalStrike);
Target.StatEff.Remove(StatusEffectEn.BlueName);
Target.StatEff.Remove(StatusEffectEn.Flashy);
Target.StatEff.Remove(StatusEffectEn.ShurikenVortex);
Target.BlueName = false;
Target.StatEff.Remove(StatusEffectEn.SuperMan);
Target.StatEff.Remove(StatusEffectEn.XPStart);
Target.StatEff.Remove(StatusEffectEn.Ride);
Target.StatEff.Add(StatusEffectEn.Dead);
Target.DeathHit = DateTime.Now;
Game.World.SendMsgToAll("SYSTEM", "" + GC.MyChar.Name + " has just owned everyone on the map with the ID of " + Cmd[1] + "", 2011, 0);
}
}
}
}
#endregion
#region Revive whole map Command - /revmap mapid [PM ONLY]
if (Cmd[0] == "/revmap")
{
if (GC.AuthInfo.Status == "[PM]")
{
foreach (Game.Character Target in Game.World.H_Chars.Values)
{
if (Target.Loc.Map == ushort.Parse(Cmd[1]))
{
Target.Ghost = false;
Target.BlueName = false;
Target.CurHP = (ushort)Target.MaxHP;
Target.Alive = true;
Target.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.Dead);
Target.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.BlueName);
Target.Body = Target.Body;
Target.Hair = Target.Hair;
Target.Equips.Send(Target.MyClient, false);
Game.World.SendMsgToAll("SYSTEM", "" + GC.MyChar.Name + " has just revived everyone on the map with the ID of " + Cmd[1] + "", 2011, 0);
}
}
}
}
#endregion
#region Revive yourself Command - /rev [PM ONLY]
if (Cmd[0] == "/rev")
{
if (GC.AuthInfo.Status == "[PM]")
{
GC.MyChar.Ghost = false;
GC.MyChar.BlueName = false;
GC.MyChar.CurHP = (ushort)GC.MyChar.MaxHP;
GC.MyChar.Alive = true;
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.Dead);
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.BlueName);
GC.MyChar.Body = GC.MyChar.Body;
GC.MyChar.Hair = GC.MyChar.Hair;
GC.MyChar.Equips.Send(GC, false);
}
}
#endregion
#region Kill a player Command - /pwn playername [PM AND GM ONLY]
if (Cmd[0] == "/pwn")
{
if (GC.AuthInfo.Status == "[PM]" || GC.AuthInfo.Status == "[GM]")
{
Game.Character Target = Game.World.CharacterFromName(Cmd[1]);
if (Target != null)
{
Target.Ghost = true;
Target.BlueName = false;
Target.CurHP = 0;
Target.Alive = false;
Target.Equips.Send(Target.MyClient, true);
Target.StatEff.Remove(StatusEffectEn.Cyclone);
Target.StatEff.Remove(StatusEffectEn.FatalStrike);
Target.StatEff.Remove(StatusEffectEn.BlueName);
Target.StatEff.Remove(StatusEffectEn.Flashy);
Target.StatEff.Remove(StatusEffectEn.ShurikenVortex);
Target.BlueName = false;
Target.StatEff.Remove(StatusEffectEn.SuperMan);
Target.StatEff.Remove(StatusEffectEn.XPStart);
Target.StatEff.Remove(StatusEffectEn.Ride);
Target.StatEff.Add(StatusEffectEn.Dead);
Target.DeathHit = DateTime.Now;
}
}
}
#endregion
#region Kill yourself Command - /sucide OR /die
if (Cmd[0] == "/sucide" || Cmd[0] == "/die")
{
if (GC.MyChar.BlueName == false)
{
GC.MyChar.Ghost = true;
GC.MyChar.CurHP = 0;
GC.MyChar.Alive = false;
GC.MyChar.Equips.Send(GC.MyChar.MyClient, true);
GC.MyChar.StatEff.Remove(StatusEffectEn.Cyclone);
GC.MyChar.StatEff.Remove(StatusEffectEn.FatalStrike);
GC.MyChar.StatEff.Remove(StatusEffectEn.BlueName);
GC.MyChar.StatEff.Remove(StatusEffectEn.Flashy);
GC.MyChar.StatEff.Remove(StatusEffectEn.ShurikenVortex);
GC.MyChar.BlueName = false;
GC.MyChar.StatEff.Remove(StatusEffectEn.SuperMan);
GC.MyChar.StatEff.Remove(StatusEffectEn.XPStart);
GC.MyChar.StatEff.Remove(StatusEffectEn.Ride);
GC.MyChar.StatEff.Add(StatusEffectEn.Dead);
GC.MyChar.DeathHit = DateTime.Now;
}
else if (GC.MyChar.Loc.Map == 1950 || GC.MyChar.PKPoints >= 30)
{
return;
}
else
{
return;
}
}
#endregion
#region Special effect Command - /seffect effect [PM ONLY]
if (Cmd[0] == "/seffect")
{
if (GC.AuthInfo.Status == "[PM]")
{
if (Cmd[1] == "pm")
{
GC.MyChar.StatEff.Add(ProjectToxicCo.Game.StatusEffectEn.TopWaterTaoist);
}
if (Cmd[1] == "rpm")
{
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.TopWaterTaoist);
}
if (Cmd[1] == "gm")
{
GC.MyChar.StatEff.Add(ProjectToxicCo.Game.StatusEffectEn.TopWarrior);
}
if (Cmd[1] == "rgm")
{
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.TopWarrior);
}
if (Cmd[1] == "blueflag")
{
GC.MyChar.StatEff.Add(ProjectToxicCo.Game.StatusEffectEn.TopArcher);
}
if (Cmd[1] == "rblueflag")
{
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.TopArcher);
}
if (Cmd[1] == "redflag")
{
GC.MyChar.StatEff.Add(ProjectToxicCo.Game.StatusEffectEn.TopFireTaoist);
}
if (Cmd[1] == "rredflag")
{
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.TopFireTaoist);
}
if (Cmd[1] == "redteam")
{
GC.MyChar.StatEff.Add(ProjectToxicCo.Game.StatusEffectEn.TopNinja);
}
if (Cmd[1] == "rredteam")
{
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.TopNinja);
}
if (Cmd[1] == "blueteam")
{
GC.MyChar.StatEff.Add(ProjectToxicCo.Game.StatusEffectEn.TopDeputyLeader);
}
if (Cmd[1] == "rblueteam")
{
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.TopDeputyLeader);
}
}
}
#endregion
#region Alert all players Command - /al message [PM ONLY]
if (Cmd[0] == "/al")
{
if (GC.AuthInfo.Status == "[PM]")
{
Game.World.SendMsgToAll(GC.MyChar.Name, Message.Remove(0, 4), 2500, 0);
Game.World.SendMsgToAll(GC.MyChar.Name, Message.Remove(0, 3), 2010, 0);
Game.World.SendMsgToAll(GC.MyChar.Name, Message.Remove(0, 3), 2011, 0);
Game.World.SendMsgToAll(GC.MyChar.Name, Message.Remove(0, 3), 2012, 0);
}
}
#endregion
#region End Guildwar Command - /endgw [PM ONLY]
if (Cmd[0] == "/endgw")
{
if (GC.AuthInfo.Status == "[PM]")
Features.GuildWars.EndWar();
}
#endregion
#region Change body (apperance) Command - /body body [PM ONLY]
if (Cmd[0] == "/body")
{
if (GC.AuthInfo.Status == "[PM]" || GC.AuthInfo.Status == "[PM]")
{
if (Cmd[1] == "whitetiger")
{
GC.MyChar.Body = 384;
}
if (Cmd[1] == "yellowtiger")
{
GC.MyChar.Body = 385;
}
if (Cmd[1] == "redtiger")
{
GC.MyChar.Body = 386;
}
if (Cmd[1] == "smale")
{
GC.MyChar.Body = 1003;
}
if (Cmd[1] == "lmale")
{
GC.MyChar.Body = 1004;
}
if (Cmd[1] == "sfemale")
{
GC.MyChar.Body = 2001;
}
if (Cmd[1] == "lfemale")
{
GC.MyChar.Body = 2002;
}
if (Cmd[1] == "guard")
{
GC.MyChar.Body = 900;
}
if (Cmd[1] == "guard2")
{
GC.MyChar.Body = 910;
}
if (Cmd[1] == "guard3")
{
GC.MyChar.Body = 920;
}
if (Cmd[1] == "nd")
{
GC.MyChar.Body = 377;
}
if (Cmd[1] == "satan")
{
GC.MyChar.Body = 166;
}
if (Cmd[1] == "vampire")
{
GC.MyChar.Body = 111;
}
if (Cmd[1] == "bunny")
{
GC.MyChar.Body = 222;
}
if (Cmd[1] == "bunny2")
{
GC.MyChar.Body = 224;
}
if (Cmd[1] == "bunny3")
{
GC.MyChar.Body = 225;
}
if (Cmd[1] == "fairy")
{
GC.MyChar.Body = 130;
}
if (Cmd[1] == "pig")
{
GC.MyChar.Body = 215;
}
if (Cmd[1] == "titan")
{
GC.MyChar.Body = 153;
}
if (Cmd[1] == "pluto")
{
GC.MyChar.Body = 168;
}
if (Cmd[1] == "revenant")
{
GC.MyChar.Body = 265;
}
if (Cmd[1] == "eidolon")
{
GC.MyChar.Body = 266;
}
if (Cmd[1] == "troll")
{
GC.MyChar.Body = 353;
}
if (Cmd[1] == "soldier")
{
GC.MyChar.Body = 263;
}
if (Cmd[1] == "phantom")
{
GC.MyChar.Body = 363;
}
if (Cmd[1] == "spearman")
{
GC.MyChar.Body = 165;
}
if (Cmd[1] == "titan")
{
GC.MyChar.Body = 153;
}
if (Cmd[1] == "gano")
{
GC.MyChar.Body = 133;
}
if (Cmd[1] == "phe")
{
GC.MyChar.Body = 104;
}
if (Cmd[1] == "ghost")
{
GC.MyChar.Body = 1098;
}
}
}
#endregion
#region Unlimited xp skill Command - /xp xpskillname [PM ONLY]
if (Cmd[0] == "/xp")
{
if (GC.AuthInfo.Status == "[PM]")
{
if (Cmd[1] == "smon")
{
GC.MyChar.StatEff.Add(ProjectToxicCo.Game.StatusEffectEn.SuperMan);
}
else if (Cmd[1] == "smoff")
{
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.SuperMan);
}
else if (Cmd[1] == "fatalon")
{
GC.MyChar.StatEff.Add(ProjectToxicCo.Game.StatusEffectEn.FatalStrike);
}
else if (Cmd[1] == "fataloff")
{
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.FatalStrike);
}
else if (Cmd[1] == "flyon")
{
GC.MyChar.StatEff.Add(ProjectToxicCo.Game.StatusEffectEn.Fly);
}
else if (Cmd[1] == "flyoff")
{
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.Fly);
}
else if (Cmd[1] == "ivon")
{
GC.MyChar.StatEff.Add(ProjectToxicCo.Game.StatusEffectEn.Invisible);
}
else if (Cmd[1] == "ivoff")
{
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.Invisible);
}
else if (Cmd[1] == "accon")
{
GC.MyChar.StatEff.Add(ProjectToxicCo.Game.StatusEffectEn.Accuracy);
}
else if (Cmd[1] == "accoff")
{
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.Accuracy);
}
if (Cmd[1] == "speedon")
{
GC.MyChar.StatEff.Add(ProjectToxicCo.Game.StatusEffectEn.Cyclone);
}
else if (Cmd[1] == "speedoff")
{
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.Cyclone);
}
if (Cmd[1] == "alloff")
{
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.SuperMan);
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.FatalStrike);
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.Fly);
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.Invisible);
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.Accuracy);
GC.MyChar.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.Cyclone);
GC.AddSend(Packets.ChatMessage(0, "SYSTEM", GC.MyChar.Name, "All XP skills have been turned off", 2001, 0));
}
if (Cmd[1] == "help")
{
GC.AddSend(Packets.ChatMessage(0, "SYSTEM", GC.MyChar.Name, "/xp skills.", 2001, 0));
GC.AddSend(Packets.ChatMessage(0, "SYSTEM", GC.MyChar.Name, "SuperMan: /xp smon / /xp smoff", 2001, 0));
GC.AddSend(Packets.ChatMessage(0, "SYSTEM", GC.MyChar.Name, "Fatal Strike: /xp fatalon / /xp fataloff", 2001, 0));
GC.AddSend(Packets.ChatMessage(0, "SYSTEM", GC.MyChar.Name, "Fly: /xp flyon / /xp flyoff", 2001, 0));
GC.AddSend(Packets.ChatMessage(0, "SYSTEM", GC.MyChar.Name, "Invisible: /xp ivon / /xp ivoff", 2001, 0));
GC.AddSend(Packets.ChatMessage(0, "SYSTEM", GC.MyChar.Name, "Accuracy: /xp accon / /xp accoff", 2001, 0));
GC.AddSend(Packets.ChatMessage(0, "SYSTEM", GC.MyChar.Name, "Cyclone: /xp speedon / /xp speedoff)", 2001, 0));
GC.AddSend(Packets.ChatMessage(0, "SYSTEM", GC.MyChar.Name, "Turn off all xp skills: /xp alloff", 2001, 0));
}
}
}
#endregion
#region How many people online Command - /playercount
if (Cmd[0] == "/playercount")
{
GC.LocalMessage(2011, "Players Online: " + Game.World.H_Chars.Count);
}
#endregion
#region Day and Night Commands - /day, /night, /night2 [PM ONLY]
if (Cmd[0] == "/day")
{
if (GC.AuthInfo.Status == "[PM]")
{
Game.World.ScreenColor = 0;
foreach (Game.Character Target in Game.World.H_Chars.Values)
try
{
Target.MyClient.AddSend(Packets.GeneralData(Target.EntityID, Game.World.ScreenColor, 0, 0, 104));
}
catch { }
}
}
if (Cmd[0] == "/night")
{
if (GC.AuthInfo.Status == "[PM]")
{
Game.World.ScreenColor = 5855577;
foreach (Game.Character Target in Game.World.H_Chars.Values)
try
{
Target.MyClient.AddSend(Packets.GeneralData(Target.EntityID, Game.World.ScreenColor, 0, 0, 104));
}
catch { }
}
}
if (Cmd[0] == "/night1")
{
if (GC.AuthInfo.Status == "[PM]")
{
Game.World.ScreenColor = 5355577;
foreach (Game.Character Target in Game.World.H_Chars.Values)
try
{
Target.MyClient.AddSend(Packets.GeneralData(Target.EntityID, Game.World.ScreenColor, 0, 0, 104));
}
catch { }
}
}
if (Cmd[0] == "/night2")
{
if (GC.AuthInfo.Status == "[PM]")
{
Game.World.ScreenColor = 6908265;
foreach (Game.Character Target in Game.World.H_Chars.Values)
try
{
Target.MyClient.AddSend(Packets.GeneralData(Target.EntityID, Game.World.ScreenColor, 0, 0, 104));
}
catch { }
}
}
#endregion
#region Ban a player Command - /ban playername [PM ONLY]
if (Cmd[0] == "/ban")
{
if (GC.AuthInfo.Status == "[PM]")
{
Game.Character C = Game.World.CharacterFromName(Cmd[1]);
if (C != null)
Database.AddBan(C.AccountName);
C.MyClient.Disconnect();
}
}
#endregion
#region Give CPs to player - /acps playername [PM ONLY]
if (Cmd[0] == "/acps")
{
if (GC.AuthInfo.Status == "[PM]")
{
Game.Character C = Game.World.CharacterFromName(Cmd[1]);
if (C != null)
C.CPs += uint.Parse(Cmd[2]);
}
}
#endregion
#region Remove CPs from player Command - /rcps playername [PM ONLY]
if (Cmd[0] == "/rcps")
{
if (GC.AuthInfo.Status == "[PM]")
{
Game.Character C = Game.World.CharacterFromName(Cmd[1]);
if (C != null)
C.CPs -= uint.Parse(Cmd[2]);
}
}
#endregion
#region Twincity monsters drop certian Item Command - /dropevent itemname[PM ONLY]
if (Cmd[0] == "/dropevent")
{
if (GC.AuthInfo.Status == "[PM]")
{
try
{
if (Program.DropEventTimer == null)
{
bool start = true;
if (Cmd[1].ToLower() == "dragonball")
{
Program.DropEventType = "dragonball";
Program.SaveOldRate = DropRates.DragonBall;
DropRates.DragonBall = (DropRates.DragonBall * int.Parse(Cmd[3]));
}
else if (Cmd[1].ToLower() == "meteor")
{
Program.DropEventType = "meteor";
Program.SaveOldRate = DropRates.Meteor;
DropRates.Meteor = (DropRates.Meteor * int.Parse(Cmd[3]));
}
else if (Cmd[1].ToLower() == "minicpbag")
{
Program.DropEventType = "minicpbag";
Program.SaveOldRate = DropRates.CPMiniBag;
DropRates.CPMiniBag = (DropRates.CPMiniBag == 0 ? 1 : DropRates.CPMiniBag * int.Parse(Cmd[3]));
}
else if (Cmd[1].ToLower() == "cpbag")
{
Program.DropEventType = "cpbag";
Program.SaveOldRate = DropRates.CPBag;
DropRates.CPBag = (DropRates.CPBag == 0 ? 1 : DropRates.CPBag * int.Parse(Cmd[3]));
}
else
start = false;
if (start)
{
Program.DropEventTimer = new System.Timers.Timer();
Program.DropEventTimer.Interval = (int.Parse(Cmd[2]) * 60000);
Program.DropEventTimer.Elapsed += new System.Timers.ElapsedEventHandler(Program.QuestDropDone);
Program.DropEventTimer.Start();
Game.World.SendMsgToAll("SYSTEM", "Monsters in TwinCity will drop " + Cmd[1] + "s " + Cmd[3] + "x for " + Cmd[2] + " minute(s).", 2011, 0);
}
else
GC.LocalMessage(2001, "Item name is not a dropevent!");
}
else
GC.LocalMessage(2001, "There is a running event, you must wait it end to start a new!");
}
catch { GC.LocalMessage(2001, "Wrongs values!"); GC.LocalMessage(2001, "Format: /dropevent ItemName Minutes Timers"); GC.LocalMessage(2001, "Example: /dropevent dragonball 15 1000 its in up the rates to 1000x in 15 minutes."); }
}
}
#endregion
#region Revive a player Command - /revive playername [PM OR GM ONLY]
if (Cmd[0] == "/revive")
{
if (GC.AuthInfo.Status == "[PM]")
{
Game.Character Target = Game.World.CharacterFromName(Cmd[1]);
if (Target != null && Target != GC.MyChar)
Target.Ghost = false;
Target.BlueName = false;
Target.CurHP = (ushort)GC.MyChar.MaxHP;
Target.CurMP = (ushort)GC.MyChar.MaxMP;
Target.Alive = true;
Target.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.Dead);
Target.StatEff.Remove(ProjectToxicCo.Game.StatusEffectEn.BlueName);
Target.Body = GC.MyChar.Body;
Target.Hair = GC.MyChar.Hair;
Target.Equips.Send(GC, false);
}
}
#endregion
#region Arrest a player Command - /arrest playername [PM ONLY]
if (Cmd[0] == "/arrest")
{
if (GC.AuthInfo.Status == "[PM]")
{
Game.Character Target = Game.World.CharacterFromName(Cmd[1]);
if (Target != null && Target != GC.MyChar)
Target.Teleport(6000, 032, 072);
Target.PKPoints = 150;
Target.Trading = false;
Target.CurHP = 1;
Target.Stamina = 0;
Game.World.SendMsgToAll(" + C.Name + ", "I'm a Biggest Idiot and I win 130kp And im send to jail. " + GC.MyChar.Name + "[GM] Thanks.", 2011, 0);
}
}
#endregion
#region Set Str,Vit,Agi,Spi Command - /setstats statforall [PM ONLY]
if (Cmd[0] == "/setstats")
{
if (GC.AuthInfo.Status == "[PM]" || GC.AuthInfo.Status == "[GM]")
{
GC.MyChar.Str = byte.Parse(Cmd[1]);
GC.MyChar.Vit = byte.Parse(Cmd[1]);
GC.MyChar.Agi = byte.Parse(Cmd[1]);
GC.MyChar.Spi = byte.Parse(Cmd[1]);
}
}
#endregion
#region Clear inv Command - /clearinv
if (Cmd[0] == "/clearinv")
{
foreach (Game.Item Item in GC.MyChar.Inventory)
GC.AddSend(Packets.ItemPacket(Item.UID, 0, 3));
GC.MyChar.Inventory = new ArrayList(40);
}
#endregion
#region Get mana and HP Command - /life [PM AND GM ONLY]
if (Cmd[0] == "/life")
{
if (GC.AuthInfo.Status == "[PM]" || GC.AuthInfo.Status == "[GM]")
{
if (GC.MyChar.BlessingLasts == 0)
{
GC.MyChar.CurHP = /*(ushort)*/GC.MyChar.MaxHP;
GC.MyChar.CurMP = /*(ushort)*/GC.MyChar.MaxMP;
GC.MyChar.Stamina = 150;
}
else
{
GC.MyChar.CurHP = /*(ushort)*/GC.MyChar.MaxHP;
GC.MyChar.CurMP = /*(ushort)*/GC.MyChar.MaxMP;
GC.MyChar.Stamina = 150;
}
}
}
#endregion
#region Bring a player to you Command - /bring playername [GM AND PM]
if (Cmd[0] == "/bring")
{
if (GC.AuthInfo.Status == "[PM]" || GC.AuthInfo.Status == "[GM]")
{
Game.Character Target = Game.World.CharacterFromName(Cmd[1]);
if (Target != null)
Target.Teleport(GC.MyChar.Loc.Map, GC.MyChar.Loc.X += 3, GC.MyChar.Loc.Y += 3);
}
}
#endregion
#region Drop an item Command - /drop itemname [PM ONLY]
if (Cmd[0] == "/drop")
{
if (GC.AuthInfo.Status == "[PM]")
{
uint DropID = 0;
Random Rnd = new Random();
string DropWhat = Cmd[1].ToLower();
byte HowMany = (byte)Math.Min(ushort.Parse(Cmd[2]), (ushort)255);
switch (DropWhat)
{
case "dragonball": DropID = 1088000; break;
case "meteor": DropID = 1088001; break;
case "pointcard": DropID = 780000; break;
case "moonbox": DropID = 721080; break;
case "bag": DropID = 729910; break;
case "ball": DropID = 723834; break;
}
Game.DroppedItem DI = new Game.DroppedItem();
DI.DropTime = DateTime.Now;
DI.UID = (uint)Rnd.Next(10000000);
DI.Loc = new Game.Location();
DI.Loc.Map = GC.MyChar.Loc.Map;
DI.Info = new Game.Item();
DI.Info.ID = DropID;
DI.Info.UID = (uint)Rnd.Next(10000000);
for (int x = 0; x < HowMany; x++)
{
DI.Loc.X = (ushort)(GC.MyChar.Loc.X + Rnd.Next(15) - Rnd.Next(15));
DI.Loc.Y = (ushort)(GC.MyChar.Loc.Y + Rnd.Next(15) - Rnd.Next(15));
if (!DI.FindPlace((Hashtable)Game.World.H_Items[GC.MyChar.Loc.Map])) continue;
DI.Drop();
}
}
}
#endregion
#region Start guildwar Command - /gw [PM AND GM ONLY]
if (Cmd[0] == "/gw" && !Features.GuildWars.War)
{
if (GC.AuthInfo.Status == "[PM]" || GC.AuthInfo.Status == "[GM]")
{
Features.GuildWars.StartWar();
}
}
#endregion
#region EVERYONE take 1's off you Command - /invinsable [PM AND GM ONLY]
if (Cmd[0] == "/invinsable")
{
if (GC.AuthInfo.Status == "[PM]" || GC.AuthInfo.Status == "[GM]")
{
GC.MyChar.Protection = !GC.MyChar.Protection;
}
}
#endregion
#region Make an effect happen Command - /effect effectname [PM ONLY]
if (Cmd[0] == "/effect")
{
if (GC.AuthInfo.Status == "[PM]")
{
GC.AddSend(Packets.String(GC.MyChar.EntityID, 10, Cmd[1]));
}
}
#endregion
#region PKPoints remove/add Command - /pkp totalpkp [PM AND GM ONLY]
if (Cmd[0] == "/pkp")
{
if (GC.AuthInfo.Status == "[PM]" || GC.AuthInfo.Status == "[GM]")
{
GC.MyChar.PKPoints = ushort.Parse(Cmd[1]);
}
}
#endregion
#region 2011 Message Command - /c message [PM ONLY]
if (Cmd[0] == "/c")
{
if (GC.AuthInfo.Status == "[PM]")
{
}
}
#endregion
#region 2012 Message Command - /cc [PM ONLY]
if (Cmd[0] == "/cc")
{
if (GC.AuthInfo.Status == "[PM]")
Game.World.SendMsgToAll(GC.MyChar.Name, GC.MyChar.Name + ": " + Message.Remove(0, 3), 2012, 0);
}
#endregion
#region Steed Command - /steed steedid [GM OR PM ONLY]
if (Cmd[0] == "/steed")
{
if (GC.AuthInfo.Status == "[PM]" || GC.AuthInfo.Status == "[GM]")
{
Game.Item I = new ProjectToxicCo.Game.Item();
I.ID = 300000;
I.Plus = byte.Parse(Cmd[1]);
I.MaxDur = I.DBInfo.Durability;
I.CurDur = I.MaxDur;
I.Effect = ProjectToxicCo.Game.Item.RebornEffect.Horsie;
I.TalismanProgress = BitConverter.ToUInt32(new byte[4] { byte.Parse(Cmd[4]), byte.Parse(Cmd[3]), byte.Parse(Cmd[2]), 0 }, 0);
I.UID = (uint)Program.Rnd.Next(10000000);
GC.MyChar.AddItem(I);
}
}
#endregion
#region Mountsteed Command - /ridesteed [GM AND PM ONLY]
if (Cmd[0] == "/ridesteed")
{
if (GC.AuthInfo.Status == "[PM]" || GC.AuthInfo.Status == "[GM]")
{
GC.MyChar.StatEff.Add(ProjectToxicCo.Game.StatusEffectEn.Ride);
}
}
#endregion
#region Goto a player Command - /goto playername [PM AND GM ONLY]
if (Cmd[0] == "/goto")
{
if (GC.AuthInfo.Status == "[PM]" || GC.AuthInfo.Status == "[GM]")
{
Game.Character Target = Game.World.CharacterFromName(Cmd[1]);
if (Target != null)
GC.MyChar.Teleport(Target.Loc.Map, Target.Loc.X += 3, Target.Loc.Y += 3);
}
}
#endregion
#region Give away VIP Command - /awardvip playername viplevel [PM ONLY]
if (Cmd[0] == "/awardvip")
{
if (GC.AuthInfo.Status == "[PM]")
{
Game.Character Target = Game.World.CharacterFromName(Cmd[1]);
if (Target != null)
{
Target.VipLevel = byte.Parse(Cmd[2]);
Target.SendScreen(Packets.ChatMessage(0, "SYSTEM", Target.Name, "Congratulations! Your vip level is " + Target.VipLevel + " Thanks for donating, ToxicCo.", 2001, 0));
}
}
}
#endregion
#region Give yourself VIP Command - /vip level
if (Cmd[0] == "/vip")
{
if (GC.AuthInfo.Status == "[PM]")
{
GC.MyChar.VipLevel = byte.Parse(Cmd[1]);
GC.AddSend(Packets.ChatMessage(0, "SYSTEM", GC.MyChar.Name, "Congratulations! Your vip level is " + GC.MyChar.VipLevel + " Thanks for donating, ToxicCo", 2001, 0));
}
}
#endregion
#region Quiz show (start) Command - /eventquiz [PM ONLY]
if (Cmd[0] == "/eventquiz")
{
if (GC.AuthInfo.Status == "[PM]")
{
if (!Features.QuizShow.QuizON)
Features.QuizShow.Start();
}
}
#endregion
#region Give yourself moonbox Command - /mb [PM AND GM ONLY]
if (Cmd[0] == "/mb")
{
if (GC.AuthInfo.Status == "[PM]")
{
GC.MyChar.AddItem(721080);
}
}
#endregion
#region Make XP full Command - /xp [PM AND GM ONLY]
if (Cmd[0] == "/xp")
{
if (GC.AuthInfo.Status == "[PM]" || GC.AuthInfo.Status == "[GM]")
{
GC.MyChar.StatEff.Add(ProjectToxicCo.Game.StatusEffectEn.XPStart);
GC.MyChar.Buffs.Add(new Game.Buff() { StEff = ProjectToxicCo.Game.StatusEffectEn.XPStart, Lasts = 20, Started = DateTime.Now, Eff = ProjectToxicCo.Features.SkillsClass.ExtraEffect.None });
}
}
#endregion
#region Give full mana Command - /mana [GM AND PM ONLY]
if (Cmd[0] == "/mana")
{
if (GC.AuthInfo.Status == "[PM]" || GC.AuthInfo.Status == "[GM]")
{
GC.MyChar.CurMP = (ushort)GC.MyChar.MaxMP;
}
}
#endregion
#region Give full hp Command - /hp [GM AND PM ONLY]
if (Cmd[0] == "/hp")
{
if (GC.AuthInfo.Status == "[PM]" || GC.AuthInfo.Status == "[GM]")
{
GC.MyChar.CurHP = (ushort)GC.MyChar.MaxHP;
}
}
#endregion
#region Give full stamina Command - /stamina [GM AND PM ONLY]
if (Cmd[0] == "/stamina")
{
if (GC.AuthInfo.Status == "[PM]")
{
GC.MyChar.Stamina = 255;
}
}
#endregion
#region Skill Command - /skill skillid
if (Cmd[0] == "/skill")
{
GC.MyChar.RWSkill(new Game.Skill() { ID = ushort.Parse(Cmd[1]), Lvl = byte.Parse(Cmd[2]), Exp = 0 });
}
#endregion
#region Prof Command - /prof profid
if (Cmd[0] == "/prof")
{
GC.MyChar.RWProf(new Game.Prof() { ID = ushort.Parse(Cmd[1]), Lvl = byte.Parse(Cmd[2]), Exp = 0 });
}
#endregion
#region Make you bluenamed or removes it Command - /blue [GM AND PM ONLY]
if (Cmd[0] == "/blue")
{
if (GC.AuthInfo.Status == "[PM]" || GC.AuthInfo.Status == "[GM]")
{
if (GC.MyChar.BlueName == true)
{
GC.MyChar.BlueName = false;
}
else
{
GC.MyChar.BlueName = true;
}
}
}
#endregion
#region Level's you up Command - /level 130
if (Cmd[0] == "/level")
{
if (Cmd[1] == "130")
{
GC.MyChar.Level = 130;
GC.MyChar.Experience = 0;
}
else if (GC.AuthInfo.Status == "[PM]")
{
GC.MyChar.Level = byte.Parse(Cmd[1]);
GC.MyChar.Experience = 0;
}
}
#endregion
#region Kick a player Command - /kick playername [PM ONLY]
if (Cmd[0] == "/kick")
{
if (GC.AuthInfo.Status == "[PM]")
{
Game.Character Target = Game.World.CharacterFromName(Cmd[1]);
if (Target != null)
{
Target.MyClient.Disconnect();
}
}
}
#endregion
#region Virute points show - /vp
if (Cmd[0] == "/vp")
{
GC.LocalMessage(2000, "You have " + GC.MyChar.VP + " virtue points.");
}
#endregion
#region Map id Command - /map [GM AND PM ONLY]
if (Cmd[0] == "/map")
{
if (GC.AuthInfo.Status == "[PM]" || GC.AuthInfo.Status == "[GM]")
{
GC.LocalMessage(2000, "The ID of the map you are on is " + GC.MyChar.Loc.Map);
}
}
#endregion
#region Change job Command - /job jobid
if (Cmd[0] == "/job")
{
GC.MyChar.Job = byte.Parse(Cmd[1]);
}
#endregion
#region Gives silvers to you Command - /silvers amount [GM AND PM ONLY]
if (Cmd[0] == "/silvers")
{
if (GC.AuthInfo.Status == "[PM]" || GC.AuthInfo.Status == "[GM]")
{
GC.MyChar.Silvers = uint.Parse(Cmd[1]);
}
}
#endregion
#region Gives CPs to you Command - /cps amount [GM AND PM ONLY]
if (Cmd[0] == "/cps")
{
if (GC.AuthInfo.Status == "[PM]" || GC.AuthInfo.Status == "[GM]")
{
GC.MyChar.CPs = uint.Parse(Cmd[1]);
}
}
#endregion
#region teleport Command - /mm cityID X Y
if (Cmd[0] == "/mm")
{
if (GC.MyChar.Loc.Map == 1950 || GC.MyChar.Loc.Map == 1080 || GC.MyChar.Loc.Map == 2020 || GC.MyChar.Loc.Map == 1038 || GC.MyChar.Loc.Map == 1047 || GC.MyChar.Loc.Map == 1037)
{
return;
}
else if (GC.AuthInfo.Status == "[PM]")
{
GC.MyChar.Teleport(ushort.Parse(Cmd[1]), ushort.Parse(Cmd[2]), ushort.Parse(Cmd[3]));
}
else
{
GC.MyChar.Teleport(ushort.Parse(Cmd[1]), ushort.Parse(Cmd[2]), ushort.Parse(Cmd[3]));
}
}
#endregion
#region Teleport a player to a city Command - /teleplayer tc [PM ONLY]
if (Cmd[0] == "/teleplayer")
{
if (GC.AuthInfo.Status == "[PM]")
{
Game.Character Target = World.CharacterFromName(Cmd[1]);
if (Target != null)
{
if (Cmd[2] == "tc")
{
Target.Teleport(1002, 430, 380);
}
}
else
{
return;
}
}
}
#endregion
#region Item Command - /item itemname etc etc etc 13 13 13
if (Cmd[0] == "/item")
{
uint ID = 0;
foreach (DatabaseItem DI in Database.DatabaseItems.Values)
if (DI.Name == Cmd[1])
{
ID = DI.ID;
Game.ItemIDManipulation e = new Game.ItemIDManipulation(ID);
Game.Item.ItemQuality Quality = e.Quality;
if (Cmd[2].ToLower() == "refined") Quality = Game.Item.ItemQuality.Refined;
else if (Cmd[2].ToLower() == "unique") Quality = Game.Item.ItemQuality.Unique;
else if (Cmd[2].ToLower() == "elite") Quality = Game.Item.ItemQuality.Elite;
else if (Cmd[2].ToLower() == "super") Quality = Game.Item.ItemQuality.Super;
else if (Cmd[2].ToLower() == "simple") Quality = Game.Item.ItemQuality.Simple;
else if (Cmd[2].ToLower() == "fixed") Quality = Game.Item.ItemQuality.Fixed;
else if (Cmd[2].ToLower() == "poor") Quality = Game.Item.ItemQuality.Poor;
else if (Cmd[2].ToLower() == "normal") Quality = Game.Item.ItemQuality.Normal;
if (e.Quality == Quality)
break;
}
if (ID != 0 && GC.MyChar.Inventory.Count < 40)
{
Game.ItemIDManipulation e = new Game.ItemIDManipulation(ID);
Game.Item.ItemQuality Quality = e.Quality;
bool change = true;
if (Cmd[2].ToLower() == "refined") Quality = Game.Item.ItemQuality.Refined;
else if (Cmd[2].ToLower() == "unique") Quality = Game.Item.ItemQuality.Unique;
else if (Cmd[2].ToLower() == "elite") Quality = Game.Item.ItemQuality.Elite;
else if (Cmd[2].ToLower() == "super") Quality = Game.Item.ItemQuality.Super;
else if (Cmd[2].ToLower() == "simple") Quality = Game.Item.ItemQuality.Simple;
else if (Cmd[2].ToLower() == "fixed") Quality = Game.Item.ItemQuality.Fixed;
else if (Cmd[2].ToLower() == "poor") Quality = Game.Item.ItemQuality.Poor;
else if (Cmd[2].ToLower() == "normal") Quality = Game.Item.ItemQuality.Normal;
else change = false;
if (change)
e.QualityChange(Quality);
ID = e.ToID();
if (!Database.DatabaseItems.ContainsKey(ID))
{
return;
}
Game.Item I = new ProjectToxicCo.Game.Item();
if (e.Part(0, 2) == 11 || e.Part(0, 2) == 13 || e.Part(0, 3) == 123 || e.Part(0, 3) == 141 || e.Part(0, 3) == 142)
I.Color = ProjectToxicCo.Game.Item.ArmorColor.Orange;
//I.FreeItem = true;
I.ID = ID;
I.UID = (uint)Program.Rnd.Next(10000000);
try
{
I.MaxDur = I.DBInfo.Durability;
I.CurDur = I.MaxDur;
}
catch (Exception Exc) { Program.WriteLine(Exc); }
try
{
I.Plus = byte.Parse(Cmd[3]);
}
catch { }
try
{
I.Bless = byte.Parse(Cmd[4]);
}
catch { }
try
{
I.Enchant = byte.Parse(Cmd[5]);
}
catch { }
try
{
I.Soc1 = (Game.Item.Gem)byte.Parse(Cmd[6]);
}
catch { }
try
{
I.Soc2 = (Game.Item.Gem)byte.Parse(Cmd[7]);
}
catch { }
I.Effect = ProjectToxicCo.Game.Item.RebornEffect.None;
GC.MyChar.AddItem(I);
}
}
#endregion
#region Summon pet - /pet [PM and GM only NOT WORKING]
if (Cmd[0] == "/pet")
{
// /pet HP atk name mech lvl
uint MinAttack = 0;
uint MaxAttack = 0;
short Level = 0;
uint SkillUses = 0;
uint CurHP = 0;
uint MaxHP = 0;
int Mesh = 0;
MinAttack = (uint.Parse(Cmd[1]));
MaxAttack = (uint.Parse(Cmd[2]));
Level = (short.Parse(Cmd[3]));
SkillUses = (uint.Parse(Cmd[4]));
CurHP = (uint.Parse(Cmd[5]));
MaxHP = (uint.Parse(Cmd[6]));
Mesh = (int.Parse(Cmd[7]));
string Name = (Cmd[8]);
// Game.Companion.Pet(Convert.ToInt16(GC.MyChar.Loc.X), Convert.ToInt16(GC.MyChar.Loc.Y), Convert.ToInt16(GC.MyChar.Loc.Map), MinAttack, MaxAttack, Level, SkillUses, CurHP, MaxHP, Mesh, Name, GC.MyChar.EntityID);
}
#endregion
#region FreezeSkill test Command - /freeze [PM ONLY]
if (Cmd[0] == "/freeze")
{
if (GC.AuthInfo.Status == "[PM]" || GC.AuthInfo.Status == "[GM]")
{
Game.Character Target = World.CharacterFromName(Cmd[1]);
{
Target.AtkMem.Attacking = false;
Target.Frozen = true;
Target.FrozenSeconds = int.Parse(Cmd[2] += 0);
Target.Frozentime = DateTime.Now;
Game.World.Spawns(Target, true);
}
}
}
#endregion
why it doesn't work 4 me ? 
|
What errors are you getting?
|
|
|
Similar Threads
|
IDs and Commands List
07/14/2011 - MapleStory - 11 Replies
IDs and Commands List posted by Raketenjagd
Press CTRL+F and enter the value (such as Item name, monster name, etc) you want to get.
GM Commands:(They in all Packs different)
!map
!summon ()
!notice
!item ()
|
Looking for a list of PM/GM commands
02/16/2010 - CO2 Private Server - 9 Replies
Stuff like /find
and all them commands
Thanks Lum
|
Massive List of Funny/Cool Poems
04/12/2008 - Off Topic - 9 Replies
I Thought The Community Could Use A Good Laugh So I Put This Together, I Hope EveryOne Enjoys This And It Enlightens Your Day.
-Might Add More If I Have Time-
-And Yes, This Is An Extremely Long Post :D
Shakespearean Insult
Thou art an artless, base-court apple-john,
|
All times are GMT +1. The time now is 16:53.
|
|