public void useZaapi(int mapid) { foreach (InteractiveElement e in InteractiveElements.Values) { if (e.TypeId == 106) { MoveToSecureElement((int)e.Id); UseElement((int)e.Id,e.EnabledSkills[0].skillInstanceUid); m_Account.Wait(500, 1000); using (BigEndianWriter writer = new BigEndianWriter()) { TeleportRequestMessage msg = new TeleportRequestMessage(1,mapid); msg.Serialize(writer); MessagePackaging pack = new MessagePackaging(writer); pack.Pack((int)msg.ProtocolID); m_Account.SocketManager.Send(pack.Writer.Content); } } } }
public void useZaapi(int mapid) { InteractiveElement e = m_Account.MapData.InteractiveElements.Keys.ToList().Find(i => i.TypeId == 106); if (e != null) { MoveToSecureElement((int)e.Id); UseElement((int)e.Id, e.EnabledSkills[0].skillInstanceUid); m_Account.Wait(500, 1000); TeleportRequestMessage msg = new TeleportRequestMessage(1, mapid); m_Account.SocketManager.Send(msg); } }
public void useZaap(int mapid) { foreach (InteractiveElement e in InteractiveElements.Values) { if (e.TypeId == 16) { MoveToSecureElement((int)e.Id); UseElement((int)e.Id, e.EnabledSkills[0].skillInstanceUid); m_Account.Wait(500, 1000); TeleportRequestMessage msg = new TeleportRequestMessage(0, mapid); m_Account.SocketManager.Send(msg); } } }