示例#1
0
        private void ReceiveMobileIncoming(IRecvPacket packet)
        {
            MobileIncomingPacket p = (MobileIncomingPacket)packet;
            Mobile mobile          = EntityManager.GetObject <Mobile>(p.Serial, true);

            mobile.BodyID = p.BodyID;
            mobile.Hue    = (int)p.Hue;
            mobile.Move_Instant(p.X, p.Y, p.Z, p.Direction);
            mobile.Flags     = p.Flags;
            mobile.Notoriety = p.Notoriety;
            mobile.Notoriety = p.Notoriety;

            for (int i = 0; i < p.Equipment.Length; i++)
            {
                Item item = add_Item(p.Equipment[i].Serial, p.Equipment[i].GumpId, p.Equipment[i].Hue, p.Serial, 0);
                mobile.WearItem(item, p.Equipment[i].Layer);
                if (item.PropertyList.Hash == 0)
                {
                    World.Engine.Client.Send(new QueryPropertiesPacket(item.Serial));
                }
            }

            if (mobile.Name == string.Empty)
            {
                mobile.Name = "Unknown";
                World.Engine.Client.Send(new RequestNamePacket(p.Serial));
            }
        }
示例#2
0
        private void ReceiveAddSingleItemToContainer(IRecvPacket packet)
        {
            ContainerContentUpdatePacket p = (ContainerContentUpdatePacket)packet;

            // Add the item...
            Item item = add_Item(p.Serial, p.ItemId, p.Hue, p.ContainerSerial, p.Amount);

            item.InContainerPosition = new Point(p.X, p.Y);
            // ... and add it the container contents of the container.
            Container iContainerObject = EntityManager.GetObject <Container>(p.ContainerSerial, true);

            if (iContainerObject != null)
            {
                iContainerObject.AddItem(item);
            }
            else
            {
                // Special case for game boards... the server will sometimes send us game pieces for a game board before it sends
                // the game board! Right now, I am discarding these messages, it might be better to queue them up for when the game
                // board actually exists.
                // Let's throw an exception if anything other than a gameboard is ever sent to us.
                // if (iObject.ItemData.Name != "game piece")
                throw new Exception("Item {" + item.ToString() + "} received before containing object received.");
            }
        }
示例#3
0
        private void ReceiveObjectPropertyList(IRecvPacket packet)
        {
            ObjectPropertyListPacket p = (ObjectPropertyListPacket)packet;

            AEntity entity = EntityManager.GetObject <AEntity>(p.Serial, false);

            if (entity == null)
            {
                return; // received property list for entity that does not exist.
            }
            entity.PropertyList.Hash = p.Hash;
            entity.PropertyList.Clear();

            for (int i = 0; i < p.CliLocs.Count; i++)
            {
                string iCliLoc = UltimaData.StringData.Entry(p.CliLocs[i]);
                if (p.Arguements[i] == string.Empty)
                {
                    entity.PropertyList.AddProperty(iCliLoc);
                }
                else
                {
                    entity.PropertyList.AddProperty(constructCliLoc(iCliLoc, p.Arguements[i]));
                }
            }
        }
示例#4
0
        private void ReceiveRejectMoveItemRequest(IRecvPacket packet)
        {
            LiftRejectionPacket p = (LiftRejectionPacket)packet;

            World.Interaction.ChatMessage("Could not pick up item: " + p.ErrorMessage);
            World.Interaction.ClearHolding();
        }
示例#5
0
        private void ReceivePlayMusic(IRecvPacket packet)
        {
            PlayMusicPacket p = (PlayMusicPacket)packet;

            // System.Console.WriteLine ( "Play music, id={0}", p.MusicID );
            UltimaData.MusicData.PlayMusic(p.MusicID);
        }
示例#6
0
        private void ReceiveLoginRejection(IRecvPacket packet)
        {
            Disconnect();
            LoginRejectionPacket p = (LoginRejectionPacket)packet;

            switch (p.Reason)
            {
            case LoginRejectionReasons.InvalidAccountPassword:
                Status = LoginClientStatus.Error_InvalidUsernamePassword;
                break;

            case LoginRejectionReasons.AccountInUse:
                Status = LoginClientStatus.Error_InUse;
                break;

            case LoginRejectionReasons.AccountBlocked:
                Status = LoginClientStatus.Error_Blocked;
                break;

            case LoginRejectionReasons.BadPassword:
                Status = LoginClientStatus.Error_BadPassword;
                break;

            case LoginRejectionReasons.IdleExceeded:
                Status = LoginClientStatus.Error_Idle;
                break;

            case LoginRejectionReasons.BadCommuncation:
                Status = LoginClientStatus.Error_BadCommunication;
                break;
            }
        }
示例#7
0
        private void ReceiveMoveRej(IRecvPacket packet)
        {
            MovementRejectPacket p = (MovementRejectPacket)packet;
            Mobile player          = (Mobile)EntityManager.GetPlayerObject();

            player.PlayerMobile_MoveEventRej(p.Sequence, p.X, p.Y, p.Z, p.Direction);
        }
示例#8
0
        private void ReceivePopupMessage(IRecvPacket packet)
        {
            PopupMessagePacket p = (PopupMessagePacket)packet;
            MsgBox             g = World.Engine.UserInterface.MsgBox(p.Message, MsgBoxTypes.OkOnly);

            g.OnClose = ReceivePopupMessage_OnClose;
        }
示例#9
0
        private void ReceiveMoveAck(IRecvPacket packet)
        {
            MoveAcknowledgePacket p = (MoveAcknowledgePacket)packet;
            Mobile player           = (Mobile)EntityManager.GetPlayerObject();

            player.PlayerMobile_MoveEventAck(p.Sequence);
            player.Notoriety = p.Notoriety;
        }
示例#10
0
        private void ReceiveSeasonalInformation(IRecvPacket packet)
        {
            // Only partially handled !!! If iSeason2 = 1, then this is a season change.
            // If season change, then iSeason1 = (0=spring, 1=summer, 2=fall, 3=winter, 4 = desolation)
            SeasonChangePacket p = (SeasonChangePacket)packet;

            UltimaVars.EngineVars.Season = p.Season;
        }
示例#11
0
        private void ReceiveCharacterList(IRecvPacket packet)
        {
            CharacterCityListPacket p = (CharacterCityListPacket)packet;

            Characters.SetCharacterList(p.Characters);
            Characters.SetStartingLocations(p.Locations);
            Status = LoginClientStatus.GameServer_CharList;
        }
示例#12
0
        // ======================================================================
        // Chat / messaging handling
        // ======================================================================

        private void ReceiveCLILOCMessage(IRecvPacket packet)
        {
            MessageLocalizedPacket p = (MessageLocalizedPacket)packet;

            string iCliLoc = constructCliLoc(UltimaData.StringData.Entry(p.CliLocNumber), p.Arguements);

            ReceiveTextMessage(p.MessageType, iCliLoc, p.Hue, p.Font, p.Serial, p.SpeakerName);
        }
示例#13
0
        // ======================================================================
        // Gump & Menu handling
        // ======================================================================

        private void ReceiveResurrectionMenu(IRecvPacket packet)
        {
            // int iAction = reader.ReadByte();
            // 0: Server sent
            // 1: Resurrect
            // 2: Ghost
            // The only use on OSI for this packet is now sending "2C02" for the "You Are Dead" screen upon character death.
            announce_UnhandledPacket(packet);
        }
示例#14
0
        //
        // Other packets
        //

        private void ReceiveMessageLocalizedAffix(IRecvPacket packet)
        {
            MessageLocalizedAffixPacket p = (MessageLocalizedAffixPacket)packet;

            string localizedString = string.Format(p.Flag_IsPrefix ? "{1}{0}" : "{0}{1}",
                                                   constructCliLoc(UltimaData.StringData.Entry(p.CliLocNumber), p.Arguements), p.Affix);

            ReceiveTextMessage(p.MessageType, localizedString, p.Hue, p.Font, p.Serial, p.SpeakerName);
        }
示例#15
0
        // ======================================================================
        // Combat handling
        // ======================================================================

        private void ReceiveChangeCombatant(IRecvPacket packet)
        {
            ChangeCombatantPacket p = (ChangeCombatantPacket)packet;

            if (p.Serial > 0x00000000)
            {
                World.Interaction.LastTarget = p.Serial;
            }
        }
示例#16
0
        private void ReceiveOnSwing(IRecvPacket packet)
        {
            SwingPacket p = (SwingPacket)packet;

            // this changes our last target - does this behavior match legacy?
            if (p.Attacker == UltimaVars.EngineVars.PlayerSerial)
            {
                World.Interaction.LastTarget = p.Defender;
            }
        }
示例#17
0
        private void ReceiveServerRelay(IRecvPacket packet)
        {
            ServerRelayPacket p = (ServerRelayPacket)packet;

            m_ServerRelayKey = p.AccountId;
            // On OSI, upon receiving this packet, the client would disconnect and
            // log in to the specified server. Since emulated servers use the same
            // server for both shard selection and world, we don't need to disconnect.
            m_Network.IsDecompressionEnabled = true;
            Status = LoginClientStatus.LoginServer_WaitingForRelay;
        }
示例#18
0
        // ======================================================================
        // Corpse handling
        // ======================================================================

        private void ReceiveCorpseClothing(IRecvPacket packet)
        {
            CorpseClothingPacket p = (CorpseClothingPacket)packet;
            Corpse corpse          = EntityManager.GetObject <Corpse>(p.CorpseSerial, false);

            if (corpse == null)
            {
                return;
            }
            corpse.LoadCorpseClothing(p.Items);
        }
示例#19
0
        private void ReceiveRequestNameResponse(IRecvPacket packet)
        {
            RequestNameResponsePacket p = (RequestNameResponsePacket)packet;
            Mobile mobile = EntityManager.GetObject <Mobile>(p.Serial, false);

            if (mobile == null)
            {
                return;
            }
            mobile.Name = p.MobileName;
        }
示例#20
0
        private void ReceiveCompressedGump(IRecvPacket packet)
        {
            CompressedGumpPacket p = (CompressedGumpPacket)packet;

            if (p.HasData)
            {
                string[] gumpPieces = interpretGumpPieces(p.GumpData);
                Gump     g          = (Gump)World.Engine.UserInterface.AddControl(new Gump(p.Serial, p.GumpID, gumpPieces, p.TextLines), p.X, p.Y);
                g.IsMovable = true;
            }
        }
示例#21
0
        private void ReceiveUpdateHealth(IRecvPacket packet)
        {
            UpdateHealthPacket p      = (UpdateHealthPacket)packet;
            Mobile             entity = EntityManager.GetObject <Mobile>(p.Serial, false);

            if (entity == null)
            {
                return;
            }
            entity.Health.Update(p.Current, p.Max);
        }
示例#22
0
        private void ReceiveDamage(IRecvPacket packet)
        {
            DamagePacket p      = (DamagePacket)packet;
            Mobile       entity = EntityManager.GetObject <Mobile>(p.Serial, false);

            if (entity == null)
            {
                return;
            }

            World.Interaction.ChatMessage(string.Format("{0} takes {1} damage!", entity.Name, p.Damage));
        }
示例#23
0
        private void ReceiveWornItem(IRecvPacket packet)
        {
            WornItemPacket p    = (WornItemPacket)packet;
            Item           item = add_Item(p.Serial, p.ItemId, p.Hue, p.ParentSerial, 0);
            Mobile         m    = EntityManager.GetObject <Mobile>(p.ParentSerial, false);

            m.WearItem(item, p.Layer);
            if (item.PropertyList.Hash == 0)
            {
                World.Engine.Client.Send(new QueryPropertiesPacket(item.Serial));
            }
        }
示例#24
0
        private void ReceiveOpenBuyWindow(IRecvPacket packet)
        {
            VendorBuyListPacket p = (VendorBuyListPacket)packet;
            Item entity           = EntityManager.GetObject <Item>(p.VendorPackSerial, false);

            if (entity == null)
            {
                return;
            }
            // UserInterface.Merchant_Open(iObject, 0);
            // !!!
        }
示例#25
0
        private void ReceiveMobileAnimation(IRecvPacket packet)
        {
            MobileAnimationPacket p = (MobileAnimationPacket)packet;
            Mobile mobile           = EntityManager.GetObject <Mobile>(p.Serial, false);

            if (mobile == null)
            {
                return;
            }

            mobile.Animate(p.Action, p.FrameCount, p.RepeatCount, p.Reverse, p.Repeat, p.Delay);
        }
示例#26
0
        private void ReceiveOverallLightLevel(IRecvPacket packet)
        {
            // byte iLightLevel = reader.ReadByte();
            // 0x00 - day
            // 0x09 - OSI night
            // 0x1F - Black
            // Max normal val = 0x1F

            OverallLightLevelPacket p = (OverallLightLevelPacket)packet;

            ((WorldView)World.GetView()).Isometric.OverallLightning = p.LightLevel;
        }
示例#27
0
        private void ReceivePersonalLightLevel(IRecvPacket packet)
        {
            // int iCreatureID = reader.ReadInt();
            // byte iLightLevel = reader.ReadByte();
            // 0x00 - day
            // 0x09 - OSI night
            // 0x1F - Black
            // Max normal val = 0x1F

            PersonalLightLevelPacket p = (PersonalLightLevelPacket)packet;

            ((WorldView)World.GetView()).Isometric.PersonalLightning = p.LightLevel;
        }
示例#28
0
        private void ReceiveLoginConfirmPacket(IRecvPacket packet)
        {
            m_QueuedLoginConfirmPacket = (LoginConfirmPacket)packet;
            // set the player serial var and create the player entity. Don't need to do anything with it yet.
            UltimaVars.EngineVars.PlayerSerial = m_QueuedLoginConfirmPacket.Serial;
            PlayerMobile player = EntityManager.GetObject <PlayerMobile>(m_QueuedLoginConfirmPacket.Serial, true);

            if (player == null)
            {
                Logger.Fatal("Could not create player object.");
            }
            CheckIfOkayToLogin();
        }
示例#29
0
        private void ReceiveLoginConfirmPacket(IRecvPacket packet)
        {
            m_QueuedLoginConfirmPacket = (LoginConfirmPacket)packet;
            // set the player serial and create the player entity. Don't need to do anything with it yet.
            WorldModel.PlayerSerial = m_QueuedLoginConfirmPacket.Serial;
            Mobile player = WorldModel.Entities.GetObject <Mobile>(m_QueuedLoginConfirmPacket.Serial, true);

            if (player == null)
            {
                Tracer.Critical("Could not create player object.");
            }
            CheckIfOkayToLogin();
        }
示例#30
0
 private void ReceiveSkillsList(IRecvPacket packet)
 {
     foreach (SendSkillsPacket_SkillEntry skill in ((SendSkillsPacket)packet).Skills)
     {
         UltimaVars.SkillEntry entry = UltimaVars.Skills.SkillEntry(skill.SkillID);
         if (entry != null)
         {
             entry.Value           = skill.SkillValue;
             entry.ValueUnmodified = skill.SkillValueUnmodified;
             entry.LockType        = skill.SkillLock;
             entry.Cap             = skill.SkillCap;
         }
     }
 }
示例#31
0
 private static void receive_SkillsList(IRecvPacket packet)
 {
     foreach (SendSkillsPacket_SkillEntry skill in ((SendSkillsPacket)packet).Skills)
     {
         if (skill.SkillID > 55)
             continue;
         ClientVars.SkillEntry entry = ClientVars.Skills.SkillEntry(skill.SkillID);
         entry.Value = skill.SkillValue;
         entry.ValueUnmodified = skill.SkillValueUnmodified;
         entry.LockType = skill.SkillLock;
         entry.Cap = skill.SkillCap;
     }
 }
示例#32
0
 private static void receive_ObjectHelpResponse(IRecvPacket packet)
 {
     announce_UnhandledPacket(packet);
 }
示例#33
0
 private static void receive_MoveRej(IRecvPacket packet)
 {
     MovementRejectPacket p = (MovementRejectPacket)packet;
     Mobile player = (Mobile)EntitiesCollection.GetPlayerObject();
     player.PlayerMobile_MoveEventRej(p.Sequence, p.X, p.Y, p.Z, p.Direction);
 }
示例#34
0
 private static void receive_OpenBuyWindow(IRecvPacket packet)
 {
     VendorBuyListPacket p = (VendorBuyListPacket)packet;
     Item iObject = EntitiesCollection.GetObject<Item>(p.VendorPackSerial, false);
     if (iObject == null)
         return;
     // UserInterface.Merchant_Open(iObject, 0);
     // !!!
 }
示例#35
0
 private static void receive_OnParticleEffect(IRecvPacket packet)
 {
     announce_UnhandledPacket(packet);
 }
示例#36
0
        private static void receive_PersonalLightLevel(IRecvPacket packet)
        {
            // int iCreatureID = reader.ReadInt();
            // byte iLightLevel = reader.ReadByte();
            // 0x00 - day
            // 0x09 - OSI night
            // 0x1F - Black
            // Max normal val = 0x1F

            PersonalLightLevelPacket p = (PersonalLightLevelPacket)packet;
            // Console.WriteLine("PersonalLight: {0}", p.LightLevel);
            _worldService.PersonalLightning = p.LightLevel;
        }
示例#37
0
 private static void receive_OpenWebBrowser(IRecvPacket packet)
 {
     OpenWebBrowserPacket p = (OpenWebBrowserPacket)packet;
     System.Diagnostics.Process.Start("iexplore.exe", p.WebsiteUrl);
 }
示例#38
0
 private static void receive_SellList(IRecvPacket packet)
 {
     announce_UnhandledPacket(packet);
 }
示例#39
0
 private static void receive_SeasonalInformation(IRecvPacket packet)
 {
     // Only partially handled !!! If iSeason2 = 1, then this is a season change.
     // If season change, then iSeason1 = (0=spring, 1=summer, 2=fall, 3=winter, 4 = desolation)
     SeasonChangePacket p = (SeasonChangePacket)packet;
     ClientVars.EngineVars.Season = p.Season;
 }
示例#40
0
 private static void receive_ServerList(IRecvPacket packet)
 {
     ClientVars.Servers.List = ((ServerListPacket)packet).Servers;
     Status = UltimaClientStatus.LoginServer_HasServerList;
 }
示例#41
0
        private static void receive_SendCustomHouse(IRecvPacket packet)
        {
            CustomHousePacket p = (CustomHousePacket)packet;
            Data.CustomHousing.UpdateCustomHouseData(p.HouseSerial, p.RevisionHash, p.PlaneCount, p.Planes);

            Multi e = EntitiesCollection.GetObject<Multi>(p.HouseSerial, false);
            if (e.CustomHouseRevision != p.RevisionHash)
            {
                Data.CustomHouse house = Data.CustomHousing.GetCustomHouseData(p.HouseSerial);
                e.AddCustomHousingTiles(house);
            }
        }
示例#42
0
 private static void receive_TargetCursorMulti(IRecvPacket packet)
 {
     TargetCursorMultiPacket p = (TargetCursorMultiPacket)packet;
     GameState.MouseTargeting(TargetTypes.MultiPlacement, 0);
     _LegacyUI.Cursor.TargetingMulti = p.MultiModel;
 }
示例#43
0
 private static void receive_TargetCursor(IRecvPacket packet)
 {
     TargetCursorPacket p = (TargetCursorPacket)packet;
     GameState.MouseTargeting((TargetTypes)p.CommandType, p.CursorID);
 }
示例#44
0
        private static void receive_StatusInfo(IRecvPacket packet)
        {
            MobileStatusCompactPacket p = (MobileStatusCompactPacket)packet;

            if (p.StatusType >= 6)
            {
                throw (new Exception("KR Status not handled."));
            }

            Mobile u = EntitiesCollection.GetObject<Mobile>(p.Serial, false);
            u.Name = p.PlayerName;
            u.Strength = p.Strength;
            u.Dexterity = p.Dexterity;
            u.Intelligence = p.Intelligence;
            u.Health.Update(p.CurrentHealth, p.MaxHealth);
            u.Stamina.Update(p.CurrentStamina, p.MaxStamina);
            u.Mana.Update(p.CurrentMana, p.MaxMana);
            u.Followers.Update(p.FollowersCurrent, p.FollowersMax);
            u.Weight.Update(p.Weight, p.WeightMax);
            u.StatCap = p.StatCap;
            u.Luck = p.Luck;
            u.Gold = p.GoldInInventory;
            u.ArmorRating = p.ArmorRating;
            u.ResistFire = p.ResistFire;
            u.ResistCold = p.ResistCold;
            u.ResistPoison = p.ResistPoison;
            u.ResistEnergy = p.ResistEnergy;
            u.DamageMin = p.DamageMin;
            u.DamageMax = p.DamageMax;
            //  other stuff unhandled !!!
        }
示例#45
0
 private static void receive_PlayerMove(IRecvPacket packet)
 {
     PlayerMovePacket p = (PlayerMovePacket)packet;
     announce_UnhandledPacket(packet);
 }
示例#46
0
 private static void receive_ResurrectionMenu(IRecvPacket packet)
 {
     // int iAction = reader.ReadByte();
     // 0: Server sent
     // 1: Resurrect
     // 2: Ghost
     // The only use on OSI for this packet is now sending "2C02" for the "You Are Dead" screen upon character death.
     announce_UnhandledPacket(packet);
 }
示例#47
0
        private static void receive_PlayerLocaleAndBody(IRecvPacket packet)
        {
            LoginConfirmPacket p = (LoginConfirmPacket)packet;

            // When loading the player object, we must load the serial before the object.
            EntitiesCollection.MySerial = p.Serial;
            PlayerMobile iPlayer = EntitiesCollection.GetObject<PlayerMobile>(p.Serial, true);
            iPlayer.Move_Instant(p.X, p.Y, p.Z, p.Direction);
            // iPlayer.SetFacing(p.Direction);

            // We want to make sure we have the client object before we load the world...
            if (Status == UltimaClientStatus.WorldServer_LoginComplete)
                Status = UltimaClientStatus.WorldServer_InWorld;
        }
示例#48
0
 private static void receive_RequestNameResponse(IRecvPacket packet)
 {
     RequestNameResponsePacket p = (RequestNameResponsePacket)packet;
     Mobile u = EntitiesCollection.GetObject<Mobile>(p.Serial, false);
     u.Name = p.MobileName;
 }
示例#49
0
        private static void receive_OverallLightLevel(IRecvPacket packet)
        {
            // byte iLightLevel = reader.ReadByte();
            // 0x00 - day
            // 0x09 - OSI night
            // 0x1F - Black
            // Max normal val = 0x1F

            OverallLightLevelPacket p = (OverallLightLevelPacket)packet;
            // Console.WriteLine("OverallLight: {0}", p.LightLevel);
            _worldService.OverallLightning = p.LightLevel;
        }
示例#50
0
 private static void receive_RejectMoveItemRequest(IRecvPacket packet)
 {
     LiftRejectionPacket p = (LiftRejectionPacket)packet;
     _LegacyUI.AddMessage_Chat("Could not pick up item: " + p.ErrorMessage);
     _LegacyUI.Cursor.ClearHolding();
 }
示例#51
0
 private static void receive_OpenPaperdoll(IRecvPacket packet)
 {
     announce_UnhandledPacket(packet);
 }
示例#52
0
 private static void receive_QuestArrow(IRecvPacket packet)
 {
     announce_UnhandledPacket(packet);
 }
示例#53
0
 private static void receive_OnSwing(IRecvPacket packet)
 {
     SwingPacket p = (SwingPacket)packet;
     if (p.Attacker == EntitiesCollection.MySerial)
     {
         ClientVars.EngineVars.LastTarget = p.Defender;
     }
 }
示例#54
0
 private static void receive_PopupMessage(IRecvPacket packet)
 {
     PopupMessagePacket p = (PopupMessagePacket)packet;
     _LegacyUI.MsgBox(p.Message, MsgBoxTypes.OkOnly);
 }
示例#55
0
        private static void receive_ObjectPropertyList(IRecvPacket packet)
        {
            ObjectPropertyListPacket p = (ObjectPropertyListPacket)packet;

            Entity iObject = EntitiesCollection.GetObject<Entity>(p.Serial, false);
            iObject.PropertyList.Hash = p.Hash;
            iObject.PropertyList.Clear();

            for (int i = 0; i < p.CliLocs.Count; i++)
            {
                string iCliLoc = Data.StringList.Entry(p.CliLocs[i]);
                if (p.Arguements[i] == string.Empty)
                {
                    iObject.PropertyList.AddProperty(iCliLoc);
                }
                else
                {
                    iObject.PropertyList.AddProperty(constructCliLoc(iCliLoc, p.Arguements[i]));
                }
            }
        }
示例#56
0
 private static void receive_PlaySoundEffect(IRecvPacket packet)
 {
     PlaySoundEffectPacket p = (PlaySoundEffectPacket)packet;
     Data.Sounds.PlaySound(p.SoundModel);
 }
示例#57
0
 private static void receive_NewSubserver(IRecvPacket packet)
 {
     SubServerPacket p = (SubServerPacket)packet;
     announce_UnhandledPacket(packet);
 }
示例#58
0
 private static void receive_PlayMusic(IRecvPacket packet)
 {
     PlayMusicPacket p = (PlayMusicPacket)packet;
     // System.Console.WriteLine ( "Play music, id={0}", p.MusicID );
     Data.Music.PlayMusic(p.MusicID);
 }
示例#59
0
 private static void receive_SetWeather(IRecvPacket packet)
 {
     announce_UnhandledPacket(packet);
 }
示例#60
0
 private static void receive_ServerRelay(IRecvPacket packet)
 {
     ServerRelayPacket p = (ServerRelayPacket)packet;
     // Normally, upon receiving this packet you would disconnect and
     // log in to the specified server. Since we are using RunUO, we don't
     // actually need to do this.
     _ClientNetwork.IsDecompressionEnabled = true;
     Send(new GameLoginPacket(p.AccountId, _account, _password));
 }