Exemplo n.º 1
0
        public static FinishBarber read(BinaryReader binaryReader)
        {
            FinishBarber newObj = new FinishBarber();

            newObj.i_base_palette          = binaryReader.ReadUInt32();
            newObj.i_head_object           = binaryReader.ReadUInt32();
            newObj.i_head_texture          = binaryReader.ReadUInt32();
            newObj.i_default_head_texture  = binaryReader.ReadUInt32();
            newObj.i_eyes_texture          = binaryReader.ReadUInt32();
            newObj.i_default_eyes_texture  = binaryReader.ReadUInt32();
            newObj.i_nose_texture          = binaryReader.ReadUInt32();
            newObj.i_default_nose_texture  = binaryReader.ReadUInt32();
            newObj.i_mouth_texture         = binaryReader.ReadUInt32();
            newObj.i_default_mouth_texture = binaryReader.ReadUInt32();
            newObj.i_skin_palette          = binaryReader.ReadUInt32();
            newObj.i_hair_palette          = binaryReader.ReadUInt32();
            newObj.i_eyes_palette          = binaryReader.ReadUInt32();
            newObj.i_setup_id = binaryReader.ReadUInt32();
            newObj.i_option1  = binaryReader.ReadUInt32();
            newObj.i_option2  = binaryReader.ReadUInt32();
            return(newObj);
        }
Exemplo n.º 2
0
    public override bool acceptMessageData(BinaryReader messageDataReader, TreeView outputTreeView)
    {
        bool handled = true;

        PacketOpcode opcode = Util.readOpcode(messageDataReader);

        switch (opcode)
        {
        case PacketOpcode.Evt_Character__TeleToPKLArena_ID:
        case PacketOpcode.Evt_Character__TeleToPKArena_ID:
        case PacketOpcode.Evt_Character__TeleToLifestone_ID:
        case PacketOpcode.Evt_Character__LoginCompleteNotification_ID:
        case PacketOpcode.Evt_Character__RequestPing_ID:
        case PacketOpcode.Evt_Character__ReturnPing_ID:
        case PacketOpcode.Evt_Character__ClearPlayerConsentList_ID:
        case PacketOpcode.Evt_Character__DisplayPlayerConsentList_ID:
        case PacketOpcode.Evt_Character__Suicide_ID:
        case PacketOpcode.Evt_Character__TeleToMarketplace_ID:
        case PacketOpcode.Evt_Character__EnterPKLite_ID:
        case PacketOpcode.Evt_Character__EnterGame_ServerReady_ID: {
            EmptyMessage message = new EmptyMessage(opcode);
            message.contributeToTreeView(outputTreeView);
            break;
        }

        case PacketOpcode.Evt_Character__PlayerOptionChangedEvent_ID: {
            PlayerOptionChangedEvent message = PlayerOptionChangedEvent.read(messageDataReader);
            message.contributeToTreeView(outputTreeView);
            break;
        }

        case PacketOpcode.Evt_Character__StartBarber_ID: {
            StartBarber message = StartBarber.read(messageDataReader);
            message.contributeToTreeView(outputTreeView);
            break;
        }

        case PacketOpcode.Evt_Character__AbuseLogRequest_ID: {
            AbuseLogRequest message = AbuseLogRequest.read(messageDataReader);
            message.contributeToTreeView(outputTreeView);
            break;
        }

        case PacketOpcode.Evt_Character__AddShortCut_ID: {
            AddShortCut message = AddShortCut.read(messageDataReader);
            message.contributeToTreeView(outputTreeView);
            break;
        }

        case PacketOpcode.Evt_Character__RemoveShortCut_ID: {
            RemoveShortCut message = RemoveShortCut.read(messageDataReader);
            message.contributeToTreeView(outputTreeView);
            break;
        }

        case PacketOpcode.Evt_Character__CharacterOptionsEvent_ID: {
            CharacterOptionsEvent message = CharacterOptionsEvent.read(messageDataReader);
            message.contributeToTreeView(outputTreeView);
            break;
        }

        case PacketOpcode.Evt_Character__QueryAge_ID: {
            QueryAge message = QueryAge.read(messageDataReader);
            message.contributeToTreeView(outputTreeView);
            break;
        }

        case PacketOpcode.Evt_Character__QueryAgeResponse_ID: {
            QueryAgeResponse message = QueryAgeResponse.read(messageDataReader);
            message.contributeToTreeView(outputTreeView);
            break;
        }

        case PacketOpcode.Evt_Character__QueryBirth_ID: {
            QueryBirth message = QueryBirth.read(messageDataReader);
            message.contributeToTreeView(outputTreeView);
            break;
        }

        case PacketOpcode.Evt_Character__AddSpellFavorite_ID: {
            AddSpellFavorite message = AddSpellFavorite.read(messageDataReader);
            message.contributeToTreeView(outputTreeView);
            break;
        }

        case PacketOpcode.Evt_Character__RemoveSpellFavorite_ID: {
            RemoveSpellFavorite message = RemoveSpellFavorite.read(messageDataReader);
            message.contributeToTreeView(outputTreeView);
            break;
        }

        case PacketOpcode.Evt_Character__RemoveFromPlayerConsentList_ID: {
            RemoveFromPlayerConsentList message = RemoveFromPlayerConsentList.read(messageDataReader);
            message.contributeToTreeView(outputTreeView);
            break;
        }

        case PacketOpcode.Evt_Character__AddPlayerPermission_ID: {
            AddPlayerPermission message = AddPlayerPermission.read(messageDataReader);
            message.contributeToTreeView(outputTreeView);
            break;
        }

        case PacketOpcode.Evt_Character__RemovePlayerPermission_ID: {
            RemovePlayerPermission message = RemovePlayerPermission.read(messageDataReader);
            message.contributeToTreeView(outputTreeView);
            break;
        }

        case PacketOpcode.Evt_Character__SetDesiredComponentLevel_ID: {
            SetDesiredComponentLevel message = SetDesiredComponentLevel.read(messageDataReader);
            message.contributeToTreeView(outputTreeView);
            break;
        }

        case PacketOpcode.Evt_Character__ConfirmationRequest_ID: {
            ConfirmationRequest message = ConfirmationRequest.read(messageDataReader);
            message.contributeToTreeView(outputTreeView);
            break;
        }

        case PacketOpcode.Evt_Character__ConfirmationResponse_ID: {
            ConfirmationResponse message = ConfirmationResponse.read(messageDataReader);
            message.contributeToTreeView(outputTreeView);
            break;
        }

        case PacketOpcode.Evt_Character__ConfirmationDone_ID: {
            ConfirmationDone message = ConfirmationDone.read(messageDataReader);
            message.contributeToTreeView(outputTreeView);
            break;
        }

        case PacketOpcode.Evt_Character__SpellbookFilterEvent_ID: {
            SpellbookFilterEvent message = SpellbookFilterEvent.read(messageDataReader);
            message.contributeToTreeView(outputTreeView);
            break;
        }

        // TODO: Missing Evt_Character__Rename_ID
        case PacketOpcode.Evt_Character__FinishBarber_ID: {
            FinishBarber message = FinishBarber.read(messageDataReader);
            message.contributeToTreeView(outputTreeView);
            break;
        }

        default: {
            handled = false;
            break;
        }
        }

        return(handled);
    }