Esempio n. 1
0
 //public static void SendUpdateArrowToAll(int itemnum) {
 //   TcpPacket packet = new TcpPacket("updatearrow");
 //   packet.AppendParameters(itemnum.ToString(), ArrowManagerBase.Arrows[itemnum].Name.Trim(), ArrowManagerBase.Arrows[itemnum].Pic.ToString(), ArrowManagerBase.Arrows[itemnum].Range.ToString(), ArrowManagerBase.Arrows[itemnum].Amount.ToString());
 //   packet.FinalizePacket();
 //   SendDataToAll(packet);
 //}
 public static void SendUpdateEmoticonToAll(int EmoteNum)
 {
     TcpPacket packet = new TcpPacket("updateemoticon");
     packet.AppendParameter(EmoteNum);
     packet.AppendClass(EmoticonManagerBase.Emoticons[EmoteNum]);
     packet.FinalizePacket();
     SendDataToAll(packet);
 }
Esempio n. 2
0
 //public static void WarpToInstancedMap(ConnectedClient client, InstancedMap map, int x, int y) {
 //    if (client.Player.Map != -2) {
 //        int oldMap = client.Player.Map;
 //        Messenger.SendLeaveMap(client, oldMap);
 //        // Now we check if there were any players left on the map the player just left, and if not stop processing npcs
 //        if (MapManager.Maps[oldMap].GetTotalPlayers() == 0) {
 //            MapManager.Maps[oldMap].PlayersOnMap = false;
 //        }
 //    }
 //    client.Player.Map = -2;
 //    client.Player.DungeonIndex = -1;
 //    client.Player.DungeonFloor = -1;
 //    if (map.StartX != 0) {
 //        client.Player.X = map.StartX;
 //    } else {
 //        client.Player.X = x;
 //    }
 //    if (map.StartY != 0) {
 //        client.Player.Y = map.StartY;
 //    } else {
 //        client.Player.Y = y;
 //    }
 //    client.Player.mInstancedMapManager.ActiveMap = map;
 //    //client.Player.mInstancedMapManager.ActiveMap.SpawnNpcs();
 //    //client.Player.mInstancedMapManager.ActiveMap.Items();
 //    SendMap(client, map);
 //    SendMapNpcsTo(client);
 //    SendMapItemsTo(client);
 //    SendPlayerData(client);
 //    SendMapDone(client);
 //    SendPlayerXY(client);
 //}
 //public static void SendEditArrowTo(Client client, int ArrowNum) {
 //    TcpPacket packet = new TcpPacket("editarrow");
 //    packet.AppendParameters(ArrowNum.ToString(), ArrowManagerBase.Arrows[ArrowNum].Name.Trim(),
 //        ArrowManagerBase.Arrows[ArrowNum].Pic.ToString(), ArrowManagerBase.Arrows[ArrowNum].Amount.ToString(),
 //       ArrowManagerBase.Arrows[ArrowNum].Range.ToString());
 //    packet.FinalizePacket();
 //   SendDataTo(client, packet);
 //}
 public static void SendEditEmotionTo(Client client, int EmoNum)
 {
     TcpPacket packet = new TcpPacket("editemoticon");
     packet.AppendParameter(EmoNum);
     packet.AppendClass(EmoticonManagerBase.Emoticons[EmoNum]);
     packet.FinalizePacket();
     //string packet = "EDITEMOTICON" + TcpManager.SEP_CHAR + EmoNum.ToString() + TcpManager.SEP_CHAR +
     //    EmoticonManagerBase.Emoticons[EmoNum].Command.Trim() + TcpManager.SEP_CHAR +
     //    EmoticonManagerBase.Emoticons[EmoNum].Pic + TcpManager.SEP_CHAR + TcpManager.END_CHAR;
     SendDataTo(client, packet);
 }