public override void onUpdatePropertys(Property prop, MemoryStream stream)
        {
            switch (prop.properUtype)
            {
            case 40001:
                Vector3 oldval_direction = direction;
                direction = stream.readVector3();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onDirectionChanged(oldval_direction);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onDirectionChanged(oldval_direction);
                    }
                }

                break;

            case 40000:
                Vector3 oldval_position = position;
                position = stream.readVector3();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onPositionChanged(oldval_position);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onPositionChanged(oldval_position);
                    }
                }

                break;

            case 40002:
                stream.readUint32();
                break;

            default:
                break;
            }
            ;
        }
Beispiel #2
0
        public override void onRemoteMethodCall(Method method, MemoryStream stream)
        {
            switch (method.methodUtype)
            {
            case 34:
                UInt32 ArriveDefeat_arg1 = stream.readUint32();
                ArriveDefeat(ArriveDefeat_arg1);
                break;

            case 33:
                ArriveSuccess();
                break;

            case 36:
                Vector3 jumpToPosition_arg1 = stream.readVector3();
                jumpToPosition(jumpToPosition_arg1);
                break;

            case 32:
                Byte startGameSecond_arg1 = stream.readUint8();
                startGameSecond(startGameSecond_arg1);
                break;

            default:
                break;
            }
            ;
        }
Beispiel #3
0
        public AVATAR_INFO createFromStreamEx(MemoryStream stream)
        {
            AVATAR_INFO datas = new AVATAR_INFO();

            datas.entity_id     = stream.readInt32();
            datas.born_position = stream.readVector3();
            datas.born_yaw      = stream.readUint8();
            return(datas);
        }
        public override void onUpdatePropertys(MemoryStream stream)
        {
            ScriptModule sm = EntityDef.moduledefs["Avatar"];
            Dictionary <UInt16, Property> pdatas = sm.idpropertys;

            while (stream.length() > 0)
            {
                UInt16 _t_utype       = 0;
                UInt16 _t_child_utype = 0;

                {
                    if (sm.usePropertyDescrAlias)
                    {
                        _t_utype       = stream.readUint8();
                        _t_child_utype = stream.readUint8();
                    }
                    else
                    {
                        _t_utype       = stream.readUint16();
                        _t_child_utype = stream.readUint16();
                    }
                }

                Property prop = null;

                if (_t_utype == 0)
                {
                    prop = pdatas[_t_child_utype];
                }
                else
                {
                    Property pComponentPropertyDescription = pdatas[_t_utype];
                    switch (pComponentPropertyDescription.properUtype)
                    {
                    case 17:
                        componentFrameSync.onUpdatePropertys(_t_child_utype, stream, -1);
                        break;

                    default:
                        break;
                    }

                    return;
                }

                switch (prop.properUtype)
                {
                case 17:
                    componentFrameSync.createFromStream(stream);
                    break;

                case 40001:
                    Vector3 oldval_direction = direction;
                    direction = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }

                    break;

                case 13:
                    SByte oldval_gameStateC = gameStateC;
                    gameStateC = stream.readInt8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onGameStateCChanged(oldval_gameStateC);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onGameStateCChanged(oldval_gameStateC);
                        }
                    }

                    break;

                case 5:
                    Int32 oldval_heroId = heroId;
                    heroId = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onHeroIdChanged(oldval_heroId);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onHeroIdChanged(oldval_heroId);
                        }
                    }

                    break;

                case 15:
                    SByte oldval_level = level;
                    level = stream.readInt8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onLevelChanged(oldval_level);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onLevelChanged(oldval_level);
                        }
                    }

                    break;

                case 3:
                    string oldval_name = name;
                    name = stream.readUnicode();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onNameChanged(oldval_name);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onNameChanged(oldval_name);
                        }
                    }

                    break;

                case 40000:
                    Vector3 oldval_position = position;
                    position = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }

                    break;

                case 12:
                    SByte oldval_roundCount = roundCount;
                    roundCount = stream.readInt8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onRoundCountChanged(oldval_roundCount);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onRoundCountChanged(oldval_roundCount);
                        }
                    }

                    break;

                case 14:
                    SByte oldval_seatNo = seatNo;
                    seatNo = stream.readInt8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onSeatNoChanged(oldval_seatNo);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onSeatNoChanged(oldval_seatNo);
                        }
                    }

                    break;

                case 40002:
                    stream.readUint32();
                    break;

                case 9:
                    Int32 oldval_teamId = teamId;
                    teamId = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onTeamIdChanged(oldval_teamId);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onTeamIdChanged(oldval_teamId);
                        }
                    }

                    break;

                case 11:
                    SByte oldval_winRate = winRate;
                    winRate = stream.readInt8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onWinRateChanged(oldval_winRate);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onWinRateChanged(oldval_winRate);
                        }
                    }

                    break;

                default:
                    break;
                }
                ;
            }
        }
        public override void onUpdatePropertys(MemoryStream stream)
        {
            ScriptModule sm = EntityDef.moduledefs["SpaceDuplicate"];
            Dictionary <UInt16, Property> pdatas = sm.idpropertys;

            while (stream.length() > 0)
            {
                UInt16 _t_utype       = 0;
                UInt16 _t_child_utype = 0;

                {
                    if (sm.usePropertyDescrAlias)
                    {
                        _t_utype       = stream.readUint8();
                        _t_child_utype = stream.readUint8();
                    }
                    else
                    {
                        _t_utype       = stream.readUint16();
                        _t_child_utype = stream.readUint16();
                    }
                }

                Property prop = null;

                if (_t_utype == 0)
                {
                    prop = pdatas[_t_child_utype];
                }
                else
                {
                    Property pComponentPropertyDescription = pdatas[_t_utype];
                    switch (pComponentPropertyDescription.properUtype)
                    {
                    default:
                        break;
                    }

                    return;
                }

                switch (prop.properUtype)
                {
                case 40001:
                    Vector3 oldval_direction = direction;
                    direction = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }

                    break;

                case 41006:
                    UInt32 oldval_modelID = modelID;
                    modelID = stream.readUint32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onModelIDChanged(oldval_modelID);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onModelIDChanged(oldval_modelID);
                        }
                    }

                    break;

                case 41007:
                    Byte oldval_modelScale = modelScale;
                    modelScale = stream.readUint8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onModelScaleChanged(oldval_modelScale);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onModelScaleChanged(oldval_modelScale);
                        }
                    }

                    break;

                case 41003:
                    string oldval_name = name;
                    name = stream.readUnicode();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onNameChanged(oldval_name);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onNameChanged(oldval_name);
                        }
                    }

                    break;

                case 40000:
                    Vector3 oldval_position = position;
                    position = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }

                    break;

                case 40002:
                    stream.readUint32();
                    break;

                case 41004:
                    UInt32 oldval_uid = uid;
                    uid = stream.readUint32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onUidChanged(oldval_uid);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onUidChanged(oldval_uid);
                        }
                    }

                    break;

                case 41005:
                    UInt32 oldval_utype = utype;
                    utype = stream.readUint32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onUtypeChanged(oldval_utype);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onUtypeChanged(oldval_utype);
                        }
                    }

                    break;

                default:
                    break;
                }
                ;
            }
        }
        public override void onUpdatePropertys(MemoryStream stream)
        {
            ScriptModule sm = EntityDef.moduledefs["Room"];
            Dictionary <UInt16, Property> pdatas = sm.idpropertys;

            while (stream.length() > 0)
            {
                UInt16 _t_utype       = 0;
                UInt16 _t_child_utype = 0;

                {
                    if (sm.usePropertyDescrAlias)
                    {
                        _t_utype       = stream.readUint8();
                        _t_child_utype = stream.readUint8();
                    }
                    else
                    {
                        _t_utype       = stream.readUint16();
                        _t_child_utype = stream.readUint16();
                    }
                }

                Property prop = null;

                if (_t_utype == 0)
                {
                    prop = pdatas[_t_child_utype];
                }
                else
                {
                    Property pComponentPropertyDescription = pdatas[_t_utype];
                    switch (pComponentPropertyDescription.properUtype)
                    {
                    default:
                        break;
                    }

                    return;
                }

                switch (prop.properUtype)
                {
                case 19:
                    Byte oldval_RoomType = RoomType;
                    RoomType = stream.readUint8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onRoomTypeChanged(oldval_RoomType);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onRoomTypeChanged(oldval_RoomType);
                        }
                    }

                    break;

                case 24:
                    Byte oldval_cur_turn = cur_turn;
                    cur_turn = stream.readUint8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onCur_turnChanged(oldval_cur_turn);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onCur_turnChanged(oldval_cur_turn);
                        }
                    }

                    break;

                case 40001:
                    Vector3 oldval_direction = direction;
                    direction = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }

                    break;

                case 22:
                    Byte oldval_numOfMJ = numOfMJ;
                    numOfMJ = stream.readUint8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onNumOfMJChanged(oldval_numOfMJ);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onNumOfMJChanged(oldval_numOfMJ);
                        }
                    }

                    break;

                case 21:
                    Byte oldval_playerMaxCount = playerMaxCount;
                    playerMaxCount = stream.readUint8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPlayerMaxCountChanged(oldval_playerMaxCount);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPlayerMaxCountChanged(oldval_playerMaxCount);
                        }
                    }

                    break;

                case 40000:
                    Vector3 oldval_position = position;
                    position = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }

                    break;

                case 23:
                    ROOM_PUBLIC_INFO oldval_public_roomInfo = public_roomInfo;
                    public_roomInfo = ((DATATYPE_ROOM_PUBLIC_INFO)EntityDef.id2datatypes[31]).createFromStreamEx(stream);

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPublic_roomInfoChanged(oldval_public_roomInfo);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPublic_roomInfoChanged(oldval_public_roomInfo);
                        }
                    }

                    break;

                case 18:
                    UInt64 oldval_roomKey = roomKey;
                    roomKey = stream.readUint64();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onRoomKeyChanged(oldval_roomKey);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onRoomKeyChanged(oldval_roomKey);
                        }
                    }

                    break;

                case 40002:
                    stream.readUint32();
                    break;

                default:
                    break;
                }
                ;
            }
        }
Beispiel #7
0
        public override void onUpdatePropertys(Property prop, MemoryStream stream)
        {
            switch (prop.properUtype)
            {
            case 40001:
                Vector3 oldval_direction = direction;
                direction = stream.readVector3();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onDirectionChanged(oldval_direction);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onDirectionChanged(oldval_direction);
                    }
                }

                break;

            case 40000:
                Vector3 oldval_position = position;
                position = stream.readVector3();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onPositionChanged(oldval_position);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onPositionChanged(oldval_position);
                    }
                }

                break;

            case 4:
                string oldval_roleName = roleName;
                roleName = stream.readUnicode();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onRoleNameChanged(oldval_roleName);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onRoleNameChanged(oldval_roleName);
                    }
                }

                break;

            case 5:
                UInt16 oldval_roleType = roleType;
                roleType = stream.readUint16();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onRoleTypeChanged(oldval_roleType);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onRoleTypeChanged(oldval_roleType);
                    }
                }

                break;

            case 40002:
                UInt32 spaceID = stream.readUint32();
                spaceID = 0;
                break;

            default:
                break;
            }
            ;
        }
Beispiel #8
0
        public override void onUpdatePropertys(MemoryStream stream)
        {
            ScriptModule sm = EntityDef.moduledefs["Account"];
            Dictionary <UInt16, Property> pdatas = sm.idpropertys;

            while (stream.length() > 0)
            {
                UInt16 _t_utype       = 0;
                UInt16 _t_child_utype = 0;

                {
                    if (sm.usePropertyDescrAlias)
                    {
                        _t_utype       = stream.readUint8();
                        _t_child_utype = stream.readUint8();
                    }
                    else
                    {
                        _t_utype       = stream.readUint16();
                        _t_child_utype = stream.readUint16();
                    }
                }

                Property prop = null;

                if (_t_utype == 0)
                {
                    prop = pdatas[_t_child_utype];
                }
                else
                {
                    Property pComponentPropertyDescription = pdatas[_t_utype];
                    switch (pComponentPropertyDescription.properUtype)
                    {
                    default:
                        break;
                    }

                    return;
                }

                switch (prop.properUtype)
                {
                case 5:
                    Int16 oldval_CampType = CampType;
                    CampType = stream.readInt16();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onCampTypeChanged(oldval_CampType);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onCampTypeChanged(oldval_CampType);
                        }
                    }

                    break;

                case 3:
                    CHESS_INFO_LIST oldval_MineChess = MineChess;
                    MineChess = ((DATATYPE_CHESS_INFO_LIST)EntityDef.id2datatypes[23]).createFromStreamEx(stream);

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onMineChessChanged(oldval_MineChess);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onMineChessChanged(oldval_MineChess);
                        }
                    }

                    break;

                case 2:
                    string oldval_RoleName = RoleName;
                    RoleName = stream.readUnicode();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onRoleNameChanged(oldval_RoleName);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onRoleNameChanged(oldval_RoleName);
                        }
                    }

                    break;

                case 1:
                    Int16 oldval_RoleType = RoleType;
                    RoleType = stream.readInt16();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onRoleTypeChanged(oldval_RoleType);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onRoleTypeChanged(oldval_RoleType);
                        }
                    }

                    break;

                case 40001:
                    Vector3 oldval_direction = direction;
                    direction = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }

                    break;

                case 40000:
                    Vector3 oldval_position = position;
                    position = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }

                    break;

                case 40002:
                    stream.readUint32();
                    break;

                default:
                    break;
                }
                ;
            }
        }
Beispiel #9
0
        public override void onUpdatePropertys(Property prop, MemoryStream stream)
        {
            switch (prop.properUtype)
            {
            case 40001:
                Vector3 oldval_direction = direction;
                direction = stream.readVector3();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onDirectionChanged(oldval_direction);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onDirectionChanged(oldval_direction);
                    }
                }

                break;

            case 23:
                List <Int32> oldval_hiddenCards = hiddenCards;
                hiddenCards = ((DATATYPE_AnonymousArray_31)EntityDef.id2datatypes[31]).createFromStreamEx(stream);

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onHiddenCardsChanged(oldval_hiddenCards);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onHiddenCardsChanged(oldval_hiddenCards);
                    }
                }

                break;

            case 24:
                List <Int32> oldval_hiddenCardsOpen = hiddenCardsOpen;
                hiddenCardsOpen = ((DATATYPE_AnonymousArray_32)EntityDef.id2datatypes[32]).createFromStreamEx(stream);

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onHiddenCardsOpenChanged(oldval_hiddenCardsOpen);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onHiddenCardsOpenChanged(oldval_hiddenCardsOpen);
                    }
                }

                break;

            case 25:
                Int16 oldval_highestPoint = highestPoint;
                highestPoint = stream.readInt16();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onHighestPointChanged(oldval_highestPoint);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onHighestPointChanged(oldval_highestPoint);
                    }
                }

                break;

            case 18:
                string oldval_intro = intro;
                intro = stream.readUnicode();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onIntroChanged(oldval_intro);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onIntroChanged(oldval_intro);
                    }
                }

                break;

            case 30:
                Int16 oldval_isGameOver = isGameOver;
                isGameOver = stream.readInt16();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onIsGameOverChanged(oldval_isGameOver);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onIsGameOverChanged(oldval_isGameOver);
                    }
                }

                break;

            case 19:
                Int16 oldval_isPlaying = isPlaying;
                isPlaying = stream.readInt16();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onIsPlayingChanged(oldval_isPlaying);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onIsPlayingChanged(oldval_isPlaying);
                    }
                }

                break;

            case 26:
                Int16 oldval_landlordIndex = landlordIndex;
                landlordIndex = stream.readInt16();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onLandlordIndexChanged(oldval_landlordIndex);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onLandlordIndexChanged(oldval_landlordIndex);
                    }
                }

                break;

            case 29:
                List <Int32> oldval_lastPlayCards = lastPlayCards;
                lastPlayCards = ((DATATYPE_AnonymousArray_33)EntityDef.id2datatypes[33]).createFromStreamEx(stream);

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onLastPlayCardsChanged(oldval_lastPlayCards);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onLastPlayCardsChanged(oldval_lastPlayCards);
                    }
                }

                break;

            case 28:
                Int16 oldval_lastPlayIndex = lastPlayIndex;
                lastPlayIndex = stream.readInt16();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onLastPlayIndexChanged(oldval_lastPlayIndex);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onLastPlayIndexChanged(oldval_lastPlayIndex);
                    }
                }

                break;

            case 17:
                string oldval_name = name;
                name = stream.readUnicode();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onNameChanged(oldval_name);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onNameChanged(oldval_name);
                    }
                }

                break;

            case 21:
                Int16 oldval_openCard = openCard;
                openCard = stream.readInt16();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onOpenCardChanged(oldval_openCard);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onOpenCardChanged(oldval_openCard);
                    }
                }

                break;

            case 27:
                Int16 oldval_playIndex = playIndex;
                playIndex = stream.readInt16();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onPlayIndexChanged(oldval_playIndex);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onPlayIndexChanged(oldval_playIndex);
                    }
                }

                break;

            case 40000:
                Vector3 oldval_position = position;
                position = stream.readVector3();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onPositionChanged(oldval_position);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onPositionChanged(oldval_position);
                    }
                }

                break;

            case 22:
                Int32 oldval_raiseIndex = raiseIndex;
                raiseIndex = stream.readInt32();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onRaiseIndexChanged(oldval_raiseIndex);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onRaiseIndexChanged(oldval_raiseIndex);
                    }
                }

                break;

            case 16:
                UInt64 oldval_roomKey = roomKey;
                roomKey = stream.readUint64();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onRoomKeyChanged(oldval_roomKey);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onRoomKeyChanged(oldval_roomKey);
                    }
                }

                break;

            case 20:
                SEATS_INFO oldval_seatsData = seatsData;
                seatsData = ((DATATYPE_SEATS_INFO)EntityDef.id2datatypes[23]).createFromStreamEx(stream);

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onSeatsDataChanged(oldval_seatsData);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onSeatsDataChanged(oldval_seatsData);
                    }
                }

                break;

            case 40002:
                stream.readUint32();
                break;

            default:
                break;
            }
            ;
        }
Beispiel #10
0
        public override void onUpdatePropertys(Property prop, MemoryStream stream)
        {
            switch (prop.properUtype)
            {
            case 21:
                UInt16 oldval_anYeYiYangGold = anYeYiYangGold;
                anYeYiYangGold = stream.readUint16();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onAnYeYiYangGoldChanged(oldval_anYeYiYangGold);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onAnYeYiYangGoldChanged(oldval_anYeYiYangGold);
                    }
                }

                break;

            case 18:
                string oldval_animState = animState;
                animState = stream.readUnicode();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onAnimStateChanged(oldval_animState);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onAnimStateChanged(oldval_animState);
                    }
                }

                break;

            case 40001:
                Vector3 oldval_direction = direction;
                direction = stream.readVector3();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onDirectionChanged(oldval_direction);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onDirectionChanged(oldval_direction);
                    }
                }

                break;

            case 13:
                UInt16 oldval_goldNum = goldNum;
                goldNum = stream.readUint16();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onGoldNumChanged(oldval_goldNum);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onGoldNumChanged(oldval_goldNum);
                    }
                }

                break;

            case 20:
                UInt16 oldval_jiaSuGold = jiaSuGold;
                jiaSuGold = stream.readUint16();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onJiaSuGoldChanged(oldval_jiaSuGold);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onJiaSuGoldChanged(oldval_jiaSuGold);
                    }
                }

                break;

            case 19:
                UInt16 oldval_keepJiaSuTime = keepJiaSuTime;
                keepJiaSuTime = stream.readUint16();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onKeepJiaSuTimeChanged(oldval_keepJiaSuTime);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onKeepJiaSuTimeChanged(oldval_keepJiaSuTime);
                    }
                }

                break;

            case 14:
                float oldval_moveSpeed = moveSpeed;
                moveSpeed = stream.readFloat();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onMoveSpeedChanged(oldval_moveSpeed);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onMoveSpeedChanged(oldval_moveSpeed);
                    }
                }

                break;

            case 16:
                string oldval_name = name;
                name = stream.readUnicode();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onNameChanged(oldval_name);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onNameChanged(oldval_name);
                    }
                }

                break;

            case 23:
                UInt16 oldval_nanShangJiaNanGold = nanShangJiaNanGold;
                nanShangJiaNanGold = stream.readUint16();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onNanShangJiaNanGoldChanged(oldval_nanShangJiaNanGold);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onNanShangJiaNanGoldChanged(oldval_nanShangJiaNanGold);
                    }
                }

                break;

            case 40000:
                Vector3 oldval_position = position;
                position = stream.readVector3();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onPositionChanged(oldval_position);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onPositionChanged(oldval_position);
                    }
                }

                break;

            case 40002:
                stream.readUint32();
                break;

            case 12:
                Byte oldval_track = track;
                track = stream.readUint8();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onTrackChanged(oldval_track);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onTrackChanged(oldval_track);
                    }
                }

                break;

            case 22:
                UInt16 oldval_xiaCiYiDingGold = xiaCiYiDingGold;
                xiaCiYiDingGold = stream.readUint16();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onXiaCiYiDingGoldChanged(oldval_xiaCiYiDingGold);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onXiaCiYiDingGoldChanged(oldval_xiaCiYiDingGold);
                    }
                }

                break;

            default:
                break;
            }
            ;
        }
Beispiel #11
0
        public override void onUpdatePropertys(MemoryStream stream)
        {
            ScriptModule sm = EntityDef.moduledefs["Avatar"];
            Dictionary <UInt16, Property> pdatas = sm.idpropertys;

            while (stream.length() > 0)
            {
                UInt16 _t_utype       = 0;
                UInt16 _t_child_utype = 0;

                {
                    if (sm.usePropertyDescrAlias)
                    {
                        _t_utype       = stream.readUint8();
                        _t_child_utype = stream.readUint8();
                    }
                    else
                    {
                        _t_utype       = stream.readUint16();
                        _t_child_utype = stream.readUint16();
                    }
                }

                Property prop = null;

                if (_t_utype == 0)
                {
                    prop = pdatas[_t_child_utype];
                }
                else
                {
                    Property pComponentPropertyDescription = pdatas[_t_utype];
                    switch (pComponentPropertyDescription.properUtype)
                    {
                    default:
                        break;
                    }

                    return;
                }

                switch (prop.properUtype)
                {
                case 48005:
                    UInt32 oldval_Die_Count = Die_Count;
                    Die_Count = stream.readUint32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onDie_CountChanged(oldval_Die_Count);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onDie_CountChanged(oldval_Die_Count);
                        }
                    }

                    break;

                case 47005:
                    Int32 oldval_EXP = EXP;
                    EXP = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onEXPChanged(oldval_EXP);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onEXPChanged(oldval_EXP);
                        }
                    }

                    break;

                case 47006:
                    Int32 oldval_EXP_Max = EXP_Max;
                    EXP_Max = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onEXP_MaxChanged(oldval_EXP_Max);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onEXP_MaxChanged(oldval_EXP_Max);
                        }
                    }

                    break;

                case 47001:
                    Int32 oldval_HP = HP;
                    HP = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onHPChanged(oldval_HP);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onHPChanged(oldval_HP);
                        }
                    }

                    break;

                case 47002:
                    Int32 oldval_HP_Max = HP_Max;
                    HP_Max = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onHP_MaxChanged(oldval_HP_Max);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onHP_MaxChanged(oldval_HP_Max);
                        }
                    }

                    break;

                case 48006:
                    UInt32 oldval_Kill_Count = Kill_Count;
                    Kill_Count = stream.readUint32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onKill_CountChanged(oldval_Kill_Count);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onKill_CountChanged(oldval_Kill_Count);
                        }
                    }

                    break;

                case 47003:
                    Int32 oldval_MP = MP;
                    MP = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onMPChanged(oldval_MP);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onMPChanged(oldval_MP);
                        }
                    }

                    break;

                case 47004:
                    Int32 oldval_MP_Max = MP_Max;
                    MP_Max = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onMP_MaxChanged(oldval_MP_Max);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onMP_MaxChanged(oldval_MP_Max);
                        }
                    }

                    break;

                case 48003:
                    UInt32 oldval_Rank = Rank;
                    Rank = stream.readUint32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onRankChanged(oldval_Rank);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onRankChanged(oldval_Rank);
                        }
                    }

                    break;

                case 48001:
                    Int32 oldval_Round = Round;
                    Round = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onRoundChanged(oldval_Round);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onRoundChanged(oldval_Round);
                        }
                    }

                    break;

                case 48002:
                    Int32 oldval_Round_Max = Round_Max;
                    Round_Max = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onRound_MaxChanged(oldval_Round_Max);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onRound_MaxChanged(oldval_Round_Max);
                        }
                    }

                    break;

                case 48004:
                    UInt32 oldval_Score = Score;
                    Score = stream.readUint32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onScoreChanged(oldval_Score);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onScoreChanged(oldval_Score);
                        }
                    }

                    break;

                case 12:
                    UInt16 oldval_cruiseSpeed = cruiseSpeed;
                    cruiseSpeed = stream.readUint16();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onCruiseSpeedChanged(oldval_cruiseSpeed);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onCruiseSpeedChanged(oldval_cruiseSpeed);
                        }
                    }

                    break;

                case 40001:
                    Vector3 oldval_direction = direction;
                    direction = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }

                    break;

                case 41002:
                    UInt16 oldval_level = level;
                    level = stream.readUint16();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onLevelChanged(oldval_level);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onLevelChanged(oldval_level);
                        }
                    }

                    break;

                case 42006:
                    UInt32 oldval_modelID = modelID;
                    modelID = stream.readUint32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onModelIDChanged(oldval_modelID);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onModelIDChanged(oldval_modelID);
                        }
                    }

                    break;

                case 42007:
                    Byte oldval_modelScale = modelScale;
                    modelScale = stream.readUint8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onModelScaleChanged(oldval_modelScale);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onModelScaleChanged(oldval_modelScale);
                        }
                    }

                    break;

                case 11:
                    UInt16 oldval_moveSpeed = moveSpeed;
                    moveSpeed = stream.readUint16();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onMoveSpeedChanged(oldval_moveSpeed);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onMoveSpeedChanged(oldval_moveSpeed);
                        }
                    }

                    break;

                case 42003:
                    string oldval_name = name;
                    name = stream.readUnicode();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onNameChanged(oldval_name);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onNameChanged(oldval_name);
                        }
                    }

                    break;

                case 40000:
                    Vector3 oldval_position = position;
                    position = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }

                    break;

                case 40002:
                    stream.readUint32();
                    break;

                case 42008:
                    UInt32 oldval_spaceUType = spaceUType;
                    spaceUType = stream.readUint32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onSpaceUTypeChanged(oldval_spaceUType);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onSpaceUTypeChanged(oldval_spaceUType);
                        }
                    }

                    break;

                case 44006:
                    SByte oldval_state = state;
                    state = stream.readInt8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onStateChanged(oldval_state);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onStateChanged(oldval_state);
                        }
                    }

                    break;

                case 42004:
                    UInt32 oldval_uid = uid;
                    uid = stream.readUint32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onUidChanged(oldval_uid);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onUidChanged(oldval_uid);
                        }
                    }

                    break;

                case 42005:
                    UInt32 oldval_utype = utype;
                    utype = stream.readUint32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onUtypeChanged(oldval_utype);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onUtypeChanged(oldval_utype);
                        }
                    }

                    break;

                default:
                    break;
                }
                ;
            }
        }
Beispiel #12
0
        public override void onUpdatePropertys(MemoryStream stream)
        {
            ScriptModule sm = EntityDef.moduledefs["Account"];
            Dictionary <UInt16, Property> pdatas = sm.idpropertys;

            while (stream.length() > 0)
            {
                UInt16 _t_utype       = 0;
                UInt16 _t_child_utype = 0;

                {
                    if (sm.usePropertyDescrAlias)
                    {
                        _t_utype       = stream.readUint8();
                        _t_child_utype = stream.readUint8();
                    }
                    else
                    {
                        _t_utype       = stream.readUint16();
                        _t_child_utype = stream.readUint16();
                    }
                }

                Property prop = null;

                if (_t_utype == 0)
                {
                    prop = pdatas[_t_child_utype];
                }
                else
                {
                    Property pComponentPropertyDescription = pdatas[_t_utype];
                    switch (pComponentPropertyDescription.properUtype)
                    {
                    default:
                        break;
                    }

                    return;
                }

                switch (prop.properUtype)
                {
                case 6:
                    CARDGROUP_INFO_LIST oldval_CardGroupList = CardGroupList;
                    CardGroupList = ((DATATYPE_CARDGROUP_INFO_LIST)EntityDef.id2datatypes[29]).createFromStreamEx(stream);

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onCardGroupListChanged(oldval_CardGroupList);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onCardGroupListChanged(oldval_CardGroupList);
                        }
                    }

                    break;

                case 5:
                    CARD_LIST oldval_CardList = CardList;
                    CardList = ((DATATYPE_CARD_LIST)EntityDef.id2datatypes[24]).createFromStreamEx(stream);

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onCardListChanged(oldval_CardList);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onCardListChanged(oldval_CardList);
                        }
                    }

                    break;

                case 3:
                    Int32 oldval_Gold = Gold;
                    Gold = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onGoldChanged(oldval_Gold);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onGoldChanged(oldval_Gold);
                        }
                    }

                    break;

                case 4:
                    Int32 oldval_Kabao = Kabao;
                    Kabao = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onKabaoChanged(oldval_Kabao);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onKabaoChanged(oldval_Kabao);
                        }
                    }

                    break;

                case 2:
                    Int16 oldval_Level = Level;
                    Level = stream.readInt16();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onLevelChanged(oldval_Level);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onLevelChanged(oldval_Level);
                        }
                    }

                    break;

                case 1:
                    string oldval_Name = Name;
                    Name = stream.readUnicode();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onNameChanged(oldval_Name);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onNameChanged(oldval_Name);
                        }
                    }

                    break;

                case 40001:
                    Vector3 oldval_direction = direction;
                    direction = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }

                    break;

                case 40000:
                    Vector3 oldval_position = position;
                    position = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }

                    break;

                case 40002:
                    stream.readUint32();
                    break;

                default:
                    break;
                }
                ;
            }
        }
Beispiel #13
0
        public override void onUpdatePropertys(MemoryStream stream)
        {
            ScriptModule sm = EntityDef.moduledefs["Avatar"];
            Dictionary <UInt16, Property> pdatas = sm.idpropertys;

            while (stream.length() > 0)
            {
                UInt16 _t_utype       = 0;
                UInt16 _t_child_utype = 0;

                {
                    if (sm.usePropertyDescrAlias)
                    {
                        _t_utype       = stream.readUint8();
                        _t_child_utype = stream.readUint8();
                    }
                    else
                    {
                        _t_utype       = stream.readUint16();
                        _t_child_utype = stream.readUint16();
                    }
                }

                Property prop = null;

                if (_t_utype == 0)
                {
                    prop = pdatas[_t_child_utype];
                }
                else
                {
                    Property pComponentPropertyDescription = pdatas[_t_utype];
                    switch (pComponentPropertyDescription.properUtype)
                    {
                    case 15:
                        componentFrameSync.onUpdatePropertys(_t_child_utype, stream, -1);
                        break;

                    default:
                        break;
                    }

                    return;
                }

                switch (prop.properUtype)
                {
                case 15:
                    componentFrameSync.createFromStream(stream);
                    break;

                case 40001:
                    Vector3 oldval_direction = direction;
                    direction = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }

                    break;

                case 11:
                    SByte oldval_gameStateC = gameStateC;
                    gameStateC = stream.readInt8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onGameStateCChanged(oldval_gameStateC);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onGameStateCChanged(oldval_gameStateC);
                        }
                    }

                    break;

                case 13:
                    Byte oldval_modelID = modelID;
                    modelID = stream.readUint8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onModelIDChanged(oldval_modelID);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onModelIDChanged(oldval_modelID);
                        }
                    }

                    break;

                case 8:
                    float oldval_moveSpeed = moveSpeed;
                    moveSpeed = stream.readFloat();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onMoveSpeedChanged(oldval_moveSpeed);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onMoveSpeedChanged(oldval_moveSpeed);
                        }
                    }

                    break;

                case 3:
                    string oldval_name = name;
                    name = stream.readUnicode();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onNameChanged(oldval_name);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onNameChanged(oldval_name);
                        }
                    }

                    break;

                case 40000:
                    Vector3 oldval_position = position;
                    position = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }

                    break;

                case 4:
                    Byte oldval_roleType = roleType;
                    roleType = stream.readUint8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onRoleTypeChanged(oldval_roleType);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onRoleTypeChanged(oldval_roleType);
                        }
                    }

                    break;

                case 40002:
                    stream.readUint32();
                    break;

                case 9:
                    SByte oldval_state = state;
                    state = stream.readInt8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onStateChanged(oldval_state);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onStateChanged(oldval_state);
                        }
                    }

                    break;

                case 6:
                    Byte oldval_teamID = teamID;
                    teamID = stream.readUint8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onTeamIDChanged(oldval_teamID);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onTeamIDChanged(oldval_teamID);
                        }
                    }

                    break;

                case 5:
                    Int32 oldval_weaponID = weaponID;
                    weaponID = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onWeaponIDChanged(oldval_weaponID);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onWeaponIDChanged(oldval_weaponID);
                        }
                    }

                    break;

                default:
                    break;
                }
                ;
            }
        }
        public override void onUpdatePropertys(MemoryStream stream)
        {
            ScriptModule sm = EntityDef.moduledefs["Account"];
            Dictionary <UInt16, Property> pdatas = sm.idpropertys;

            while (stream.length() > 0)
            {
                UInt16 _t_utype       = 0;
                UInt16 _t_child_utype = 0;

                {
                    if (sm.usePropertyDescrAlias)
                    {
                        _t_utype       = stream.readUint8();
                        _t_child_utype = stream.readUint8();
                    }
                    else
                    {
                        _t_utype       = stream.readUint16();
                        _t_child_utype = stream.readUint16();
                    }
                }

                Property prop = null;

                if (_t_utype == 0)
                {
                    prop = pdatas[_t_child_utype];
                }
                else
                {
                    Property pComponentPropertyDescription = pdatas[_t_utype];
                    switch (pComponentPropertyDescription.properUtype)
                    {
                    default:
                        break;
                    }

                    return;
                }

                switch (prop.properUtype)
                {
                case 16:
                    ITEM_LIST oldval_bagItemList = bagItemList;
                    bagItemList = ((DATATYPE_ITEM_LIST)EntityDef.id2datatypes[23]).createFromStreamEx(stream);

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onBagItemListChanged(oldval_bagItemList);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onBagItemListChanged(oldval_bagItemList);
                        }
                    }

                    break;

                case 17:
                    EQUIP_DICT oldval_currentItemDict = currentItemDict;
                    currentItemDict = ((DATATYPE_EQUIP_DICT)EntityDef.id2datatypes[24]).createFromStreamEx(stream);

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onCurrentItemDictChanged(oldval_currentItemDict);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onCurrentItemDictChanged(oldval_currentItemDict);
                        }
                    }

                    break;

                case 40001:
                    Vector3 oldval_direction = direction;
                    direction = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }

                    break;

                case 8:
                    Int32 oldval_gold = gold;
                    gold = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onGoldChanged(oldval_gold);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onGoldChanged(oldval_gold);
                        }
                    }

                    break;

                case 3:
                    SByte oldval_lastLoginDate = lastLoginDate;
                    lastLoginDate = stream.readInt8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onLastLoginDateChanged(oldval_lastLoginDate);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onLastLoginDateChanged(oldval_lastLoginDate);
                        }
                    }

                    break;

                case 7:
                    Int16 oldval_lastLoginDayLoginTimes = lastLoginDayLoginTimes;
                    lastLoginDayLoginTimes = stream.readInt16();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onLastLoginDayLoginTimesChanged(oldval_lastLoginDayLoginTimes);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onLastLoginDayLoginTimesChanged(oldval_lastLoginDayLoginTimes);
                        }
                    }

                    break;

                case 5:
                    Int16 oldval_lastLoginDayPlayTime = lastLoginDayPlayTime;
                    lastLoginDayPlayTime = stream.readInt16();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onLastLoginDayPlayTimeChanged(oldval_lastLoginDayPlayTime);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onLastLoginDayPlayTimeChanged(oldval_lastLoginDayPlayTime);
                        }
                    }

                    break;

                case 2:
                    string oldval_nameS = nameS;
                    nameS = stream.readUnicode();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onNameSChanged(oldval_nameS);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onNameSChanged(oldval_nameS);
                        }
                    }

                    break;

                case 40000:
                    Vector3 oldval_position = position;
                    position = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }

                    break;

                case 13:
                    Int32 oldval_progress = progress;
                    progress = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onProgressChanged(oldval_progress);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onProgressChanged(oldval_progress);
                        }
                    }

                    break;

                case 15:
                    Int32 oldval_roomNo = roomNo;
                    roomNo = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onRoomNoChanged(oldval_roomNo);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onRoomNoChanged(oldval_roomNo);
                        }
                    }

                    break;

                case 40002:
                    stream.readUint32();
                    break;

                case 6:
                    Int16 oldval_totalLoginTimes = totalLoginTimes;
                    totalLoginTimes = stream.readInt16();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onTotalLoginTimesChanged(oldval_totalLoginTimes);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onTotalLoginTimesChanged(oldval_totalLoginTimes);
                        }
                    }

                    break;

                case 4:
                    Int16 oldval_totalPlayTime = totalPlayTime;
                    totalPlayTime = stream.readInt16();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onTotalPlayTimeChanged(oldval_totalPlayTime);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onTotalPlayTimeChanged(oldval_totalPlayTime);
                        }
                    }

                    break;

                default:
                    break;
                }
                ;
            }
        }
        public override void onRemoteMethodCall(MemoryStream stream)
        {
            ScriptModule sm = EntityDef.moduledefs["Account"];

            UInt16 methodUtype            = 0;
            UInt16 componentPropertyUType = 0;

            if (sm.usePropertyDescrAlias)
            {
                componentPropertyUType = stream.readUint8();
            }
            else
            {
                componentPropertyUType = stream.readUint16();
            }

            if (sm.useMethodDescrAlias)
            {
                methodUtype = stream.readUint8();
            }
            else
            {
                methodUtype = stream.readUint16();
            }

            Method method = null;

            if (componentPropertyUType == 0)
            {
                method = sm.idmethods[methodUtype];
            }
            else
            {
                Property pComponentPropertyDescription = sm.idpropertys[componentPropertyUType];
                switch (pComponentPropertyDescription.properUtype)
                {
                default:
                    break;
                }

                return;
            }

            switch (method.methodUtype)
            {
            case 20:
                Int32 onBuyEquip_arg1 = stream.readInt32();
                Byte  onBuyEquip_arg2 = stream.readUint8();
                onBuyEquip(onBuyEquip_arg1, onBuyEquip_arg2);
                break;

            case 21:
                Int32 onChangeEquip_arg1 = stream.readInt32();
                Byte  onChangeEquip_arg2 = stream.readUint8();
                onChangeEquip(onChangeEquip_arg1, onChangeEquip_arg2);
                break;

            case 19:
                Int32 onExitRoom_arg1 = stream.readInt32();
                onExitRoom(onExitRoom_arg1);
                break;

            case 22:
                Int32 onGetGold_arg1 = stream.readInt32();
                onGetGold(onGetGold_arg1);
                break;

            case 17:
                Int32  onGetPropsClient_arg1 = stream.readInt32();
                string onGetPropsClient_arg2 = stream.readUnicode();
                Int32  onGetPropsClient_arg3 = stream.readInt32();
                onGetPropsClient(onGetPropsClient_arg1, onGetPropsClient_arg2, onGetPropsClient_arg3);
                break;

            case 14:
                Int32 onLoginState_arg1 = stream.readInt32();
                onLoginState(onLoginState_arg1);
                break;

            case 15:
                Int32 onMapModeChanged_arg1 = stream.readInt32();
                Int32 onMapModeChanged_arg2 = stream.readInt32();
                onMapModeChanged(onMapModeChanged_arg1, onMapModeChanged_arg2);
                break;

            case 16:
                Int32 onMatchingFinish_arg1 = stream.readInt32();
                onMatchingFinish(onMatchingFinish_arg1);
                break;

            case 18:
                Int32   onUseProp_arg1 = stream.readInt32();
                Int32   onUseProp_arg2 = stream.readInt32();
                Int32   onUseProp_arg3 = stream.readInt32();
                Vector3 onUseProp_arg4 = stream.readVector3();
                onUseProp(onUseProp_arg1, onUseProp_arg2, onUseProp_arg3, onUseProp_arg4);
                break;

            default:
                break;
            }
            ;
        }
Beispiel #16
0
        public override void onUpdatePropertys(Property prop, MemoryStream stream)
        {
            switch (prop.properUtype)
            {
            case 4:
                FRIEND_INFO_LIST oldval_Friend_list = Friend_list;
                Friend_list = ((DATATYPE_FRIEND_INFO_LIST)EntityDef.id2datatypes[23]).createFromStreamEx(stream);

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onFriend_listChanged(oldval_Friend_list);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onFriend_listChanged(oldval_Friend_list);
                    }
                }

                break;

            case 3:
                UInt16 oldval_Icon = Icon;
                Icon = stream.readUint16();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onIconChanged(oldval_Icon);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onIconChanged(oldval_Icon);
                    }
                }

                break;

            case 2:
                Byte oldval_Level = Level;
                Level = stream.readUint8();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onLevelChanged(oldval_Level);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onLevelChanged(oldval_Level);
                    }
                }

                break;

            case 1:
                string oldval_Name = Name;
                Name = stream.readUnicode();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onNameChanged(oldval_Name);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onNameChanged(oldval_Name);
                    }
                }

                break;

            case 40001:
                Vector3 oldval_direction = direction;
                direction = stream.readVector3();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onDirectionChanged(oldval_direction);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onDirectionChanged(oldval_direction);
                    }
                }

                break;

            case 40000:
                Vector3 oldval_position = position;
                position = stream.readVector3();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onPositionChanged(oldval_position);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onPositionChanged(oldval_position);
                    }
                }

                break;

            case 40002:
                stream.readUint32();
                break;

            default:
                break;
            }
            ;
        }
Beispiel #17
0
        public override void onUpdatePropertys(Property prop, MemoryStream stream)
        {
            switch (prop.properUtype)
            {
            case 40001:
                Vector3 oldval_direction = direction;
                direction = stream.readVector3();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onDirectionChanged(oldval_direction);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onDirectionChanged(oldval_direction);
                    }
                }

                break;

            case 32:
                UInt32 oldval_launchID = launchID;
                launchID = stream.readUint32();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onLaunchIDChanged(oldval_launchID);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onLaunchIDChanged(oldval_launchID);
                    }
                }

                break;

            case 34:
                string oldval_name = name;
                name = stream.readUnicode();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onNameChanged(oldval_name);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onNameChanged(oldval_name);
                    }
                }

                break;

            case 40000:
                Vector3 oldval_position = position;
                position = stream.readVector3();

                if (prop.isBase())
                {
                    if (inited)
                    {
                        onPositionChanged(oldval_position);
                    }
                }
                else
                {
                    if (inWorld)
                    {
                        onPositionChanged(oldval_position);
                    }
                }

                break;

            case 40002:
                stream.readUint32();
                break;

            default:
                break;
            }
            ;
        }
Beispiel #18
0
        public override void onUpdatePropertys(MemoryStream stream)
        {
            ScriptModule sm = EntityDef.moduledefs["Avatar"];
            Dictionary <UInt16, Property> pdatas = sm.idpropertys;

            while (stream.length() > 0)
            {
                UInt16 _t_utype       = 0;
                UInt16 _t_child_utype = 0;

                {
                    if (sm.usePropertyDescrAlias)
                    {
                        _t_utype       = stream.readUint8();
                        _t_child_utype = stream.readUint8();
                    }
                    else
                    {
                        _t_utype       = stream.readUint16();
                        _t_child_utype = stream.readUint16();
                    }
                }

                Property prop = null;

                if (_t_utype == 0)
                {
                    prop = pdatas[_t_child_utype];
                }
                else
                {
                    Property pComponentPropertyDescription = pdatas[_t_utype];
                    switch (pComponentPropertyDescription.properUtype)
                    {
                    default:
                        break;
                    }

                    return;
                }

                switch (prop.properUtype)
                {
                case 17:
                    Byte oldval_CrystalAvaliable = CrystalAvaliable;
                    CrystalAvaliable = stream.readUint8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onCrystalAvaliableChanged(oldval_CrystalAvaliable);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onCrystalAvaliableChanged(oldval_CrystalAvaliable);
                        }
                    }

                    break;

                case 16:
                    Byte oldval_CrystalSum = CrystalSum;
                    CrystalSum = stream.readUint8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onCrystalSumChanged(oldval_CrystalSum);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onCrystalSumChanged(oldval_CrystalSum);
                        }
                    }

                    break;

                case 21:
                    Int16 oldval_HP = HP;
                    HP = stream.readInt16();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onHPChanged(oldval_HP);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onHPChanged(oldval_HP);
                        }
                    }

                    break;

                case 11:
                    string oldval_NameA = NameA;
                    NameA = stream.readUnicode();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onNameAChanged(oldval_NameA);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onNameAChanged(oldval_NameA);
                        }
                    }

                    break;

                case 12:
                    Byte oldval_RoleType = RoleType;
                    RoleType = stream.readUint8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onRoleTypeChanged(oldval_RoleType);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onRoleTypeChanged(oldval_RoleType);
                        }
                    }

                    break;

                case 13:
                    Byte oldval_Situation = Situation;
                    Situation = stream.readUint8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onSituationChanged(oldval_Situation);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onSituationChanged(oldval_Situation);
                        }
                    }

                    break;

                case 23:
                    UInt16 oldval_armor = armor;
                    armor = stream.readUint16();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onArmorChanged(oldval_armor);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onArmorChanged(oldval_armor);
                        }
                    }

                    break;

                case 22:
                    UInt16 oldval_att = att;
                    att = stream.readUint16();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onAttChanged(oldval_att);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onAttChanged(oldval_att);
                        }
                    }

                    break;

                case 24:
                    UInt16 oldval_attSum = attSum;
                    attSum = stream.readUint16();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onAttSumChanged(oldval_attSum);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onAttSumChanged(oldval_attSum);
                        }
                    }

                    break;

                case 20:
                    UInt32 oldval_cardID = cardID;
                    cardID = stream.readUint32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onCardIDChanged(oldval_cardID);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onCardIDChanged(oldval_cardID);
                        }
                    }

                    break;

                case 25:
                    UInt16 oldval_cost = cost;
                    cost = stream.readUint16();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onCostChanged(oldval_cost);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onCostChanged(oldval_cost);
                        }
                    }

                    break;

                case 40001:
                    Vector3 oldval_direction = direction;
                    direction = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }

                    break;

                case 36:
                    Byte oldval_frozen = frozen;
                    frozen = stream.readUint8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onFrozenChanged(oldval_frozen);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onFrozenChanged(oldval_frozen);
                        }
                    }

                    break;

                case 37:
                    Byte oldval_immune = immune;
                    immune = stream.readUint8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onImmuneChanged(oldval_immune);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onImmuneChanged(oldval_immune);
                        }
                    }

                    break;

                case 34:
                    Byte oldval_isAbled = isAbled;
                    isAbled = stream.readUint8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onIsAbledChanged(oldval_isAbled);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onIsAbledChanged(oldval_isAbled);
                        }
                    }

                    break;

                case 33:
                    Byte oldval_isDivineShield = isDivineShield;
                    isDivineShield = stream.readUint8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onIsDivineShieldChanged(oldval_isDivineShield);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onIsDivineShieldChanged(oldval_isDivineShield);
                        }
                    }

                    break;

                case 31:
                    Byte oldval_isRush = isRush;
                    isRush = stream.readUint8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onIsRushChanged(oldval_isRush);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onIsRushChanged(oldval_isRush);
                        }
                    }

                    break;

                case 35:
                    Byte oldval_isStealth = isStealth;
                    isStealth = stream.readUint8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onIsStealthChanged(oldval_isStealth);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onIsStealthChanged(oldval_isStealth);
                        }
                    }

                    break;

                case 30:
                    Byte oldval_isTaunt = isTaunt;
                    isTaunt = stream.readUint8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onIsTauntChanged(oldval_isTaunt);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onIsTauntChanged(oldval_isTaunt);
                        }
                    }

                    break;

                case 32:
                    Byte oldval_isWindfury = isWindfury;
                    isWindfury = stream.readUint8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onIsWindfuryChanged(oldval_isWindfury);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onIsWindfuryChanged(oldval_isWindfury);
                        }
                    }

                    break;

                case 29:
                    Byte oldval_maxHP = maxHP;
                    maxHP = stream.readUint8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onMaxHPChanged(oldval_maxHP);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onMaxHPChanged(oldval_maxHP);
                        }
                    }

                    break;

                case 27:
                    Byte oldval_playerID = playerID;
                    playerID = stream.readUint8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPlayerIDChanged(oldval_playerID);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPlayerIDChanged(oldval_playerID);
                        }
                    }

                    break;

                case 28:
                    string oldval_pos = pos;
                    pos = stream.readUnicode();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPosChanged(oldval_pos);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPosChanged(oldval_pos);
                        }
                    }

                    break;

                case 40000:
                    Vector3 oldval_position = position;
                    position = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }

                    break;

                case 40002:
                    stream.readUint32();
                    break;

                case 26:
                    UInt16 oldval_type = type;
                    type = stream.readUint16();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onTypeChanged(oldval_type);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onTypeChanged(oldval_type);
                        }
                    }

                    break;

                default:
                    break;
                }
                ;
            }
        }
Beispiel #19
0
        public override void onUpdatePropertys(MemoryStream stream)
        {
            ScriptModule sm = EntityDef.moduledefs["Account"];
            Dictionary <UInt16, Property> pdatas = sm.idpropertys;

            while (stream.length() > 0)
            {
                UInt16 _t_utype       = 0;
                UInt16 _t_child_utype = 0;

                {
                    if (sm.usePropertyDescrAlias)
                    {
                        _t_utype       = stream.readUint8();
                        _t_child_utype = stream.readUint8();
                    }
                    else
                    {
                        _t_utype       = stream.readUint16();
                        _t_child_utype = stream.readUint16();
                    }
                }

                Property prop = null;

                if (_t_utype == 0)
                {
                    prop = pdatas[_t_child_utype];
                }
                else
                {
                    Property pComponentPropertyDescription = pdatas[_t_utype];
                    switch (pComponentPropertyDescription.properUtype)
                    {
                    default:
                        break;
                    }

                    return;
                }

                switch (prop.properUtype)
                {
                case 40001:
                    Vector3 oldval_direction = direction;
                    direction = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }

                    break;

                case 8:
                    FRIENDLIST oldval_friendList = friendList;
                    friendList = ((DATATYPE_FRIENDLIST)EntityDef.id2datatypes[24]).createFromStreamEx(stream);

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onFriendListChanged(oldval_friendList);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onFriendListChanged(oldval_friendList);
                        }
                    }

                    break;

                case 3:
                    Int32 oldval_playerBean = playerBean;
                    playerBean = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPlayerBeanChanged(oldval_playerBean);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPlayerBeanChanged(oldval_playerBean);
                        }
                    }

                    break;

                case 6:
                    ENTITYDATA oldval_playerData = playerData;
                    playerData = ((DATATYPE_ENTITYDATA)EntityDef.id2datatypes[25]).createFromStreamEx(stream);

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPlayerDataChanged(oldval_playerData);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPlayerDataChanged(oldval_playerData);
                        }
                    }

                    break;

                case 2:
                    UInt16 oldval_playerId = playerId;
                    playerId = stream.readUint16();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPlayerIdChanged(oldval_playerId);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPlayerIdChanged(oldval_playerId);
                        }
                    }

                    break;

                case 1:
                    string oldval_playerName = playerName;
                    playerName = stream.readUnicode();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPlayerNameChanged(oldval_playerName);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPlayerNameChanged(oldval_playerName);
                        }
                    }

                    break;

                case 4:
                    Byte oldval_playerNew = playerNew;
                    playerNew = stream.readUint8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPlayerNewChanged(oldval_playerNew);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPlayerNewChanged(oldval_playerNew);
                        }
                    }

                    break;

                case 7:
                    POKERLIST oldval_playerPoker = playerPoker;
                    playerPoker = ((DATATYPE_POKERLIST)EntityDef.id2datatypes[23]).createFromStreamEx(stream);

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPlayerPokerChanged(oldval_playerPoker);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPlayerPokerChanged(oldval_playerPoker);
                        }
                    }

                    break;

                case 40000:
                    Vector3 oldval_position = position;
                    position = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }

                    break;

                case 5:
                    Byte oldval_roomIndex = roomIndex;
                    roomIndex = stream.readUint8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onRoomIndexChanged(oldval_roomIndex);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onRoomIndexChanged(oldval_roomIndex);
                        }
                    }

                    break;

                case 40002:
                    stream.readUint32();
                    break;

                default:
                    break;
                }
                ;
            }
        }
        public override void onUpdatePropertys(MemoryStream stream)
        {
            ScriptModule sm = EntityDef.moduledefs["Avatar"];
            Dictionary <UInt16, Property> pdatas = sm.idpropertys;

            while (stream.length() > 0)
            {
                UInt16 _t_utype       = 0;
                UInt16 _t_child_utype = 0;

                {
                    if (sm.usePropertyDescrAlias)
                    {
                        _t_utype       = stream.readUint8();
                        _t_child_utype = stream.readUint8();
                    }
                    else
                    {
                        _t_utype       = stream.readUint16();
                        _t_child_utype = stream.readUint16();
                    }
                }

                Property prop = null;

                if (_t_utype == 0)
                {
                    prop = pdatas[_t_child_utype];
                }
                else
                {
                    Property pComponentPropertyDescription = pdatas[_t_utype];
                    switch (pComponentPropertyDescription.properUtype)
                    {
                    case 6:
                        component1.onUpdatePropertys(_t_child_utype, stream, -1);
                        break;

                    default:
                        break;
                    }

                    return;
                }

                switch (prop.properUtype)
                {
                case 6:
                    component1.createFromStream(stream);
                    break;

                case 40001:
                    Vector3 oldval_direction = direction;
                    direction = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }

                    break;

                case 41002:
                    UInt16 oldval_level = level;
                    level = stream.readUint16();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onLevelChanged(oldval_level);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onLevelChanged(oldval_level);
                        }
                    }

                    break;

                case 41003:
                    string oldval_name = name;
                    name = stream.readUnicode();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onNameChanged(oldval_name);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onNameChanged(oldval_name);
                        }
                    }

                    break;

                case 40000:
                    Vector3 oldval_position = position;
                    position = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }

                    break;

                case 40002:
                    stream.readUint32();
                    break;

                default:
                    break;
                }
                ;
            }
        }
Beispiel #21
0
        public override void onUpdatePropertys(MemoryStream stream)
        {
            ScriptModule sm = EntityDef.moduledefs["Weapon"];
            Dictionary <UInt16, Property> pdatas = sm.idpropertys;

            while (stream.length() > 0)
            {
                UInt16 _t_utype       = 0;
                UInt16 _t_child_utype = 0;

                {
                    if (sm.usePropertyDescrAlias)
                    {
                        _t_utype       = stream.readUint8();
                        _t_child_utype = stream.readUint8();
                    }
                    else
                    {
                        _t_utype       = stream.readUint16();
                        _t_child_utype = stream.readUint16();
                    }
                }

                Property prop = null;

                if (_t_utype == 0)
                {
                    prop = pdatas[_t_child_utype];
                }
                else
                {
                    Property pComponentPropertyDescription = pdatas[_t_utype];
                    switch (pComponentPropertyDescription.properUtype)
                    {
                    default:
                        break;
                    }

                    return;
                }

                switch (prop.properUtype)
                {
                case 51003:
                    UInt16 oldval_CD = CD;
                    CD = stream.readUint16();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onCDChanged(oldval_CD);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onCDChanged(oldval_CD);
                        }
                    }

                    break;

                case 51001:
                    UInt16 oldval_attackerID = attackerID;
                    attackerID = stream.readUint16();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onAttackerIDChanged(oldval_attackerID);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onAttackerIDChanged(oldval_attackerID);
                        }
                    }

                    break;

                case 23:
                    UInt16 oldval_cruiseSpeed = cruiseSpeed;
                    cruiseSpeed = stream.readUint16();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onCruiseSpeedChanged(oldval_cruiseSpeed);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onCruiseSpeedChanged(oldval_cruiseSpeed);
                        }
                    }

                    break;

                case 51004:
                    Vector3 oldval_destForward = destForward;
                    destForward = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onDestForwardChanged(oldval_destForward);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onDestForwardChanged(oldval_destForward);
                        }
                    }

                    break;

                case 40001:
                    Vector3 oldval_direction = direction;
                    direction = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }

                    break;

                case 42006:
                    UInt32 oldval_modelID = modelID;
                    modelID = stream.readUint32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onModelIDChanged(oldval_modelID);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onModelIDChanged(oldval_modelID);
                        }
                    }

                    break;

                case 42007:
                    Byte oldval_modelScale = modelScale;
                    modelScale = stream.readUint8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onModelScaleChanged(oldval_modelScale);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onModelScaleChanged(oldval_modelScale);
                        }
                    }

                    break;

                case 22:
                    UInt16 oldval_moveSpeed = moveSpeed;
                    moveSpeed = stream.readUint16();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onMoveSpeedChanged(oldval_moveSpeed);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onMoveSpeedChanged(oldval_moveSpeed);
                        }
                    }

                    break;

                case 42003:
                    string oldval_name = name;
                    name = stream.readUnicode();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onNameChanged(oldval_name);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onNameChanged(oldval_name);
                        }
                    }

                    break;

                case 51002:
                    UInt16 oldval_ownerID = ownerID;
                    ownerID = stream.readUint16();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onOwnerIDChanged(oldval_ownerID);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onOwnerIDChanged(oldval_ownerID);
                        }
                    }

                    break;

                case 40000:
                    Vector3 oldval_position = position;
                    position = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }

                    break;

                case 40002:
                    stream.readUint32();
                    break;

                case 42008:
                    UInt32 oldval_spaceUType = spaceUType;
                    spaceUType = stream.readUint32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onSpaceUTypeChanged(oldval_spaceUType);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onSpaceUTypeChanged(oldval_spaceUType);
                        }
                    }

                    break;

                case 44006:
                    SByte oldval_state = state;
                    state = stream.readInt8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onStateChanged(oldval_state);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onStateChanged(oldval_state);
                        }
                    }

                    break;

                case 42004:
                    UInt32 oldval_uid = uid;
                    uid = stream.readUint32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onUidChanged(oldval_uid);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onUidChanged(oldval_uid);
                        }
                    }

                    break;

                case 42005:
                    UInt32 oldval_utype = utype;
                    utype = stream.readUint32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onUtypeChanged(oldval_utype);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onUtypeChanged(oldval_utype);
                        }
                    }

                    break;

                default:
                    break;
                }
                ;
            }
        }
Beispiel #22
0
        public override void onUpdatePropertys(MemoryStream stream)
        {
            ScriptModule sm = EntityDef.moduledefs["Chess"];
            Dictionary <UInt16, Property> pdatas = sm.idpropertys;

            while (stream.length() > 0)
            {
                UInt16 _t_utype       = 0;
                UInt16 _t_child_utype = 0;

                {
                    if (sm.usePropertyDescrAlias)
                    {
                        _t_utype       = stream.readUint8();
                        _t_child_utype = stream.readUint8();
                    }
                    else
                    {
                        _t_utype       = stream.readUint16();
                        _t_child_utype = stream.readUint16();
                    }
                }

                Property prop = null;

                if (_t_utype == 0)
                {
                    prop = pdatas[_t_child_utype];
                }
                else
                {
                    Property pComponentPropertyDescription = pdatas[_t_utype];
                    switch (pComponentPropertyDescription.properUtype)
                    {
                    default:
                        break;
                    }

                    return;
                }

                switch (prop.properUtype)
                {
                case 11:
                    UInt64 oldval_chess_attack = chess_attack;
                    chess_attack = stream.readUint64();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onChess_attackChanged(oldval_chess_attack);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onChess_attackChanged(oldval_chess_attack);
                        }
                    }

                    break;

                case 12:
                    UInt64 oldval_chess_defense = chess_defense;
                    chess_defense = stream.readUint64();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onChess_defenseChanged(oldval_chess_defense);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onChess_defenseChanged(oldval_chess_defense);
                        }
                    }

                    break;

                case 6:
                    UInt64 oldval_chess_id = chess_id;
                    chess_id = stream.readUint64();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onChess_idChanged(oldval_chess_id);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onChess_idChanged(oldval_chess_id);
                        }
                    }

                    break;

                case 9:
                    UInt64 oldval_chess_index_x = chess_index_x;
                    chess_index_x = stream.readUint64();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onChess_index_xChanged(oldval_chess_index_x);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onChess_index_xChanged(oldval_chess_index_x);
                        }
                    }

                    break;

                case 10:
                    UInt64 oldval_chess_index_z = chess_index_z;
                    chess_index_z = stream.readUint64();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onChess_index_zChanged(oldval_chess_index_z);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onChess_index_zChanged(oldval_chess_index_z);
                        }
                    }

                    break;

                case 7:
                    UInt64 oldval_chess_level = chess_level;
                    chess_level = stream.readUint64();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onChess_levelChanged(oldval_chess_level);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onChess_levelChanged(oldval_chess_level);
                        }
                    }

                    break;

                case 8:
                    string oldval_chess_name = chess_name;
                    chess_name = stream.readUnicode();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onChess_nameChanged(oldval_chess_name);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onChess_nameChanged(oldval_chess_name);
                        }
                    }

                    break;

                case 13:
                    UInt64 oldval_chess_owner_player = chess_owner_player;
                    chess_owner_player = stream.readUint64();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onChess_owner_playerChanged(oldval_chess_owner_player);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onChess_owner_playerChanged(oldval_chess_owner_player);
                        }
                    }

                    break;

                case 40001:
                    Vector3 oldval_direction = direction;
                    direction = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }

                    break;

                case 14:
                    UInt64 oldval_max_hp = max_hp;
                    max_hp = stream.readUint64();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onMax_hpChanged(oldval_max_hp);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onMax_hpChanged(oldval_max_hp);
                        }
                    }

                    break;

                case 40000:
                    Vector3 oldval_position = position;
                    position = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }

                    break;

                case 40002:
                    stream.readUint32();
                    break;

                default:
                    break;
                }
                ;
            }
        }
        public override void onUpdatePropertys(MemoryStream stream)
        {
            ScriptModule sm = EntityDef.moduledefs["Monster"];
            Dictionary <UInt16, Property> pdatas = sm.idpropertys;

            while (stream.length() > 0)
            {
                UInt16 _t_utype       = 0;
                UInt16 _t_child_utype = 0;

                {
                    if (sm.usePropertyDescrAlias)
                    {
                        _t_utype       = stream.readUint8();
                        _t_child_utype = stream.readUint8();
                    }
                    else
                    {
                        _t_utype       = stream.readUint16();
                        _t_child_utype = stream.readUint16();
                    }
                }

                Property prop = null;

                if (_t_utype == 0)
                {
                    prop = pdatas[_t_child_utype];
                }
                else
                {
                    Property pComponentPropertyDescription = pdatas[_t_utype];
                    switch (pComponentPropertyDescription.properUtype)
                    {
                    default:
                        break;
                    }

                    return;
                }

                switch (prop.properUtype)
                {
                case 47001:
                    Int32 oldval_HP = HP;
                    HP = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onHPChanged(oldval_HP);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onHPChanged(oldval_HP);
                        }
                    }

                    break;

                case 47002:
                    Int32 oldval_HP_Max = HP_Max;
                    HP_Max = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onHP_MaxChanged(oldval_HP_Max);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onHP_MaxChanged(oldval_HP_Max);
                        }
                    }

                    break;

                case 47003:
                    Int32 oldval_MP = MP;
                    MP = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onMPChanged(oldval_MP);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onMPChanged(oldval_MP);
                        }
                    }

                    break;

                case 47004:
                    Int32 oldval_MP_Max = MP_Max;
                    MP_Max = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onMP_MaxChanged(oldval_MP_Max);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onMP_MaxChanged(oldval_MP_Max);
                        }
                    }

                    break;

                case 40001:
                    Vector3 oldval_direction = direction;
                    direction = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }

                    break;

                case 51007:
                    UInt32 oldval_entityNO = entityNO;
                    entityNO = stream.readUint32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onEntityNOChanged(oldval_entityNO);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onEntityNOChanged(oldval_entityNO);
                        }
                    }

                    break;

                case 47005:
                    Int32 oldval_forbids = forbids;
                    forbids = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onForbidsChanged(oldval_forbids);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onForbidsChanged(oldval_forbids);
                        }
                    }

                    break;

                case 41006:
                    UInt32 oldval_modelID = modelID;
                    modelID = stream.readUint32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onModelIDChanged(oldval_modelID);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onModelIDChanged(oldval_modelID);
                        }
                    }

                    break;

                case 41007:
                    Byte oldval_modelScale = modelScale;
                    modelScale = stream.readUint8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onModelScaleChanged(oldval_modelScale);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onModelScaleChanged(oldval_modelScale);
                        }
                    }

                    break;

                case 32:
                    Byte oldval_moveSpeed = moveSpeed;
                    moveSpeed = stream.readUint8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onMoveSpeedChanged(oldval_moveSpeed);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onMoveSpeedChanged(oldval_moveSpeed);
                        }
                    }

                    break;

                case 41003:
                    string oldval_name = name;
                    name = stream.readUnicode();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onNameChanged(oldval_name);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onNameChanged(oldval_name);
                        }
                    }

                    break;

                case 40000:
                    Vector3 oldval_position = position;
                    position = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }

                    break;

                case 40002:
                    stream.readUint32();
                    break;

                case 47006:
                    SByte oldval_state = state;
                    state = stream.readInt8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onStateChanged(oldval_state);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onStateChanged(oldval_state);
                        }
                    }

                    break;

                case 47007:
                    Byte oldval_subState = subState;
                    subState = stream.readUint8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onSubStateChanged(oldval_subState);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onSubStateChanged(oldval_subState);
                        }
                    }

                    break;

                case 41004:
                    UInt32 oldval_uid = uid;
                    uid = stream.readUint32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onUidChanged(oldval_uid);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onUidChanged(oldval_uid);
                        }
                    }

                    break;

                case 41005:
                    UInt32 oldval_utype = utype;
                    utype = stream.readUint32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onUtypeChanged(oldval_utype);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onUtypeChanged(oldval_utype);
                        }
                    }

                    break;

                default:
                    break;
                }
                ;
            }
        }
Beispiel #24
0
        public override void onUpdatePropertys(MemoryStream stream)
        {
            ScriptModule sm = EntityDef.moduledefs["Avatar"];
            Dictionary <UInt16, Property> pdatas = sm.idpropertys;

            while (stream.length() > 0)
            {
                UInt16 _t_utype       = 0;
                UInt16 _t_child_utype = 0;

                {
                    if (sm.usePropertyDescrAlias)
                    {
                        _t_utype       = stream.readUint8();
                        _t_child_utype = stream.readUint8();
                    }
                    else
                    {
                        _t_utype       = stream.readUint16();
                        _t_child_utype = stream.readUint16();
                    }
                }

                Property prop = null;

                if (_t_utype == 0)
                {
                    prop = pdatas[_t_child_utype];
                }
                else
                {
                    Property pComponentPropertyDescription = pdatas[_t_utype];
                    switch (pComponentPropertyDescription.properUtype)
                    {
                    default:
                        break;
                    }

                    return;
                }

                switch (prop.properUtype)
                {
                case 40001:
                    Vector3 oldval_direction = direction;
                    direction = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }

                    break;

                case 5:
                    Byte oldval_level = level;
                    level = stream.readUint8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onLevelChanged(oldval_level);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onLevelChanged(oldval_level);
                        }
                    }

                    break;

                case 4:
                    Int32 oldval_mass = mass;
                    mass = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onMassChanged(oldval_mass);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onMassChanged(oldval_mass);
                        }
                    }

                    break;

                case 9:
                    Byte oldval_modelID = modelID;
                    modelID = stream.readUint8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onModelIDChanged(oldval_modelID);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onModelIDChanged(oldval_modelID);
                        }
                    }

                    break;

                case 7:
                    float oldval_modelScale = modelScale;
                    modelScale = stream.readFloat();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onModelScaleChanged(oldval_modelScale);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onModelScaleChanged(oldval_modelScale);
                        }
                    }

                    break;

                case 6:
                    float oldval_moveSpeed = moveSpeed;
                    moveSpeed = stream.readFloat();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onMoveSpeedChanged(oldval_moveSpeed);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onMoveSpeedChanged(oldval_moveSpeed);
                        }
                    }

                    break;

                case 2:
                    string oldval_name = name;
                    name = stream.readUnicode();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onNameChanged(oldval_name);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onNameChanged(oldval_name);
                        }
                    }

                    break;

                case 40000:
                    Vector3 oldval_position = position;
                    position = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }

                    break;

                case 40002:
                    stream.readUint32();
                    break;

                case 8:
                    SByte oldval_state = state;
                    state = stream.readInt8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onStateChanged(oldval_state);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onStateChanged(oldval_state);
                        }
                    }

                    break;

                default:
                    break;
                }
                ;
            }
        }
        public override void onUpdatePropertys(MemoryStream stream)
        {
            ScriptModule sm = EntityDef.moduledefs["Account"];
            Dictionary <UInt16, Property> pdatas = sm.idpropertys;

            while (stream.length() > 0)
            {
                UInt16 _t_utype       = 0;
                UInt16 _t_child_utype = 0;

                {
                    if (sm.usePropertyDescrAlias)
                    {
                        _t_utype       = stream.readUint8();
                        _t_child_utype = stream.readUint8();
                    }
                    else
                    {
                        _t_utype       = stream.readUint16();
                        _t_child_utype = stream.readUint16();
                    }
                }

                Property prop = null;

                if (_t_utype == 0)
                {
                    prop = pdatas[_t_child_utype];
                }
                else
                {
                    Property pComponentPropertyDescription = pdatas[_t_utype];
                    switch (pComponentPropertyDescription.properUtype)
                    {
                    default:
                        break;
                    }

                    return;
                }

                switch (prop.properUtype)
                {
                case 40001:
                    Vector3 oldval_direction = direction;
                    direction = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }

                    break;

                case 5:
                    Byte oldval_isNewPlayer = isNewPlayer;
                    isNewPlayer = stream.readUint8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onIsNewPlayerChanged(oldval_isNewPlayer);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onIsNewPlayerChanged(oldval_isNewPlayer);
                        }
                    }

                    break;

                case 4:
                    UInt16 oldval_playerID = playerID;
                    playerID = stream.readUint16();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPlayerIDChanged(oldval_playerID);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPlayerIDChanged(oldval_playerID);
                        }
                    }

                    break;

                case 2:
                    UInt16 oldval_playerID_base = playerID_base;
                    playerID_base = stream.readUint16();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPlayerID_baseChanged(oldval_playerID_base);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPlayerID_baseChanged(oldval_playerID_base);
                        }
                    }

                    break;

                case 3:
                    string oldval_playerName = playerName;
                    playerName = stream.readUnicode();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPlayerNameChanged(oldval_playerName);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPlayerNameChanged(oldval_playerName);
                        }
                    }

                    break;

                case 1:
                    string oldval_playerName_base = playerName_base;
                    playerName_base = stream.readUnicode();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPlayerName_baseChanged(oldval_playerName_base);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPlayerName_baseChanged(oldval_playerName_base);
                        }
                    }

                    break;

                case 40000:
                    Vector3 oldval_position = position;
                    position = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }

                    break;

                case 40002:
                    stream.readUint32();
                    break;

                default:
                    break;
                }
                ;
            }
        }
Beispiel #26
0
		public override void onUpdatePropertys(MemoryStream stream)
		{
			ScriptModule sm = EntityDef.moduledefs["City"];
			Dictionary<UInt16, Property> pdatas = sm.idpropertys;

			while(stream.length() > 0)
			{
				UInt16 _t_utype = 0;
				UInt16 _t_child_utype = 0;

				{
					if(sm.usePropertyDescrAlias)
					{
						_t_utype = stream.readUint8();
						_t_child_utype = stream.readUint8();
					}
					else
					{
						_t_utype = stream.readUint16();
						_t_child_utype = stream.readUint16();
					}
				}

				Property prop = null;

				if(_t_utype == 0)
				{
					prop = pdatas[_t_child_utype];
				}
				else
				{
					Property pComponentPropertyDescription = pdatas[_t_utype];
					switch(pComponentPropertyDescription.properUtype)
					{
						default:
							break;
					}

					return;
				}

				switch(prop.properUtype)
				{
					case 7:
						Int64 oldval_BusinessDvelopment = BusinessDvelopment;
						BusinessDvelopment = stream.readInt64();

						if(prop.isBase())
						{
							if(inited)
								onBusinessDvelopmentChanged(oldval_BusinessDvelopment);
						}
						else
						{
							if(inWorld)
								onBusinessDvelopmentChanged(oldval_BusinessDvelopment);
						}

						break;
					case 6:
						Byte oldval_CityCountry = CityCountry;
						CityCountry = stream.readUint8();

						if(prop.isBase())
						{
							if(inited)
								onCityCountryChanged(oldval_CityCountry);
						}
						else
						{
							if(inWorld)
								onCityCountryChanged(oldval_CityCountry);
						}

						break;
					case 3:
						UInt32 oldval_CityID = CityID;
						CityID = stream.readUint32();

						if(prop.isBase())
						{
							if(inited)
								onCityIDChanged(oldval_CityID);
						}
						else
						{
							if(inWorld)
								onCityIDChanged(oldval_CityID);
						}

						break;
					case 4:
						string oldval_CityName = CityName;
						CityName = stream.readUnicode();

						if(prop.isBase())
						{
							if(inited)
								onCityNameChanged(oldval_CityName);
						}
						else
						{
							if(inWorld)
								onCityNameChanged(oldval_CityName);
						}

						break;
					case 5:
						Byte oldval_CityType = CityType;
						CityType = stream.readUint8();

						if(prop.isBase())
						{
							if(inited)
								onCityTypeChanged(oldval_CityType);
						}
						else
						{
							if(inWorld)
								onCityTypeChanged(oldval_CityType);
						}

						break;
					case 8:
						Int64 oldval_MilitaryDvelopment = MilitaryDvelopment;
						MilitaryDvelopment = stream.readInt64();

						if(prop.isBase())
						{
							if(inited)
								onMilitaryDvelopmentChanged(oldval_MilitaryDvelopment);
						}
						else
						{
							if(inWorld)
								onMilitaryDvelopmentChanged(oldval_MilitaryDvelopment);
						}

						break;
					case 9:
						CITY_SELL_GOODS_LIST oldval_SellGoodsList = SellGoodsList;
						SellGoodsList = ((DATATYPE_CITY_SELL_GOODS_LIST)EntityDef.id2datatypes[23]).createFromStreamEx(stream);

						if(prop.isBase())
						{
							if(inited)
								onSellGoodsListChanged(oldval_SellGoodsList);
						}
						else
						{
							if(inWorld)
								onSellGoodsListChanged(oldval_SellGoodsList);
						}

						break;
					case 40001:
						Vector3 oldval_direction = direction;
						direction = stream.readVector3();

						if(prop.isBase())
						{
							if(inited)
								onDirectionChanged(oldval_direction);
						}
						else
						{
							if(inWorld)
								onDirectionChanged(oldval_direction);
						}

						break;
					case 40000:
						Vector3 oldval_position = position;
						position = stream.readVector3();

						if(prop.isBase())
						{
							if(inited)
								onPositionChanged(oldval_position);
						}
						else
						{
							if(inWorld)
								onPositionChanged(oldval_position);
						}

						break;
					case 40002:
						stream.readUint32();
						break;
					default:
						break;
				};
			}
		}
Beispiel #27
0
        public override void onUpdatePropertys(MemoryStream stream)
        {
            ScriptModule sm = EntityDef.moduledefs["Account"];
            Dictionary <UInt16, Property> pdatas = sm.idpropertys;

            while (stream.length() > 0)
            {
                UInt16 _t_utype       = 0;
                UInt16 _t_child_utype = 0;

                {
                    if (sm.usePropertyDescrAlias)
                    {
                        _t_utype       = stream.readUint8();
                        _t_child_utype = stream.readUint8();
                    }
                    else
                    {
                        _t_utype       = stream.readUint16();
                        _t_child_utype = stream.readUint16();
                    }
                }

                Property prop = null;

                if (_t_utype == 0)
                {
                    prop = pdatas[_t_child_utype];
                }
                else
                {
                    Property pComponentPropertyDescription = pdatas[_t_utype];
                    switch (pComponentPropertyDescription.properUtype)
                    {
                    default:
                        break;
                    }

                    return;
                }

                switch (prop.properUtype)
                {
                case 40001:
                    Vector3 oldval_direction = direction;
                    direction = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }

                    break;

                case 2:
                    UInt64 oldval_lastSelCharacter = lastSelCharacter;
                    lastSelCharacter = stream.readUint64();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onLastSelCharacterChanged(oldval_lastSelCharacter);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onLastSelCharacterChanged(oldval_lastSelCharacter);
                        }
                    }

                    break;

                case 40000:
                    Vector3 oldval_position = position;
                    position = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }

                    break;

                case 40002:
                    stream.readUint32();
                    break;

                default:
                    break;
                }
                ;
            }
        }
Beispiel #28
0
        public override void onUpdatePropertys(MemoryStream stream)
        {
            ScriptModule sm = EntityDef.moduledefs["Avatar"];
            Dictionary <UInt16, Property> pdatas = sm.idpropertys;

            while (stream.length() > 0)
            {
                UInt16 _t_utype       = 0;
                UInt16 _t_child_utype = 0;

                {
                    if (sm.usePropertyDescrAlias)
                    {
                        _t_utype       = stream.readUint8();
                        _t_child_utype = stream.readUint8();
                    }
                    else
                    {
                        _t_utype       = stream.readUint16();
                        _t_child_utype = stream.readUint16();
                    }
                }

                Property prop = null;

                if (_t_utype == 0)
                {
                    prop = pdatas[_t_child_utype];
                }
                else
                {
                    Property pComponentPropertyDescription = pdatas[_t_utype];
                    switch (pComponentPropertyDescription.properUtype)
                    {
                    default:
                        break;
                    }

                    return;
                }

                switch (prop.properUtype)
                {
                case 47001:
                    Int32 oldval_HP = HP;
                    HP = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onHPChanged(oldval_HP);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onHPChanged(oldval_HP);
                        }
                    }

                    break;

                case 47002:
                    Int32 oldval_HP_Max = HP_Max;
                    HP_Max = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onHP_MaxChanged(oldval_HP_Max);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onHP_MaxChanged(oldval_HP_Max);
                        }
                    }

                    break;

                case 47003:
                    Int32 oldval_MP = MP;
                    MP = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onMPChanged(oldval_MP);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onMPChanged(oldval_MP);
                        }
                    }

                    break;

                case 47004:
                    Int32 oldval_MP_Max = MP_Max;
                    MP_Max = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onMP_MaxChanged(oldval_MP_Max);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onMP_MaxChanged(oldval_MP_Max);
                        }
                    }

                    break;

                case 17:
                    Int32 oldval_attack_Max = attack_Max;
                    attack_Max = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onAttack_MaxChanged(oldval_attack_Max);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onAttack_MaxChanged(oldval_attack_Max);
                        }
                    }

                    break;

                case 18:
                    Int32 oldval_attack_Min = attack_Min;
                    attack_Min = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onAttack_MinChanged(oldval_attack_Min);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onAttack_MinChanged(oldval_attack_Min);
                        }
                    }

                    break;

                case 19:
                    Int32 oldval_defence = defence;
                    defence = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onDefenceChanged(oldval_defence);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onDefenceChanged(oldval_defence);
                        }
                    }

                    break;

                case 25:
                    Int32 oldval_dexterity = dexterity;
                    dexterity = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onDexterityChanged(oldval_dexterity);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onDexterityChanged(oldval_dexterity);
                        }
                    }

                    break;

                case 40001:
                    Vector3 oldval_direction = direction;
                    direction = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }

                    break;

                case 21:
                    Int32 oldval_dodge = dodge;
                    dodge = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onDodgeChanged(oldval_dodge);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onDodgeChanged(oldval_dodge);
                        }
                    }

                    break;

                case 7:
                    ITEM_INFO_LIST oldval_equipItemList = equipItemList;
                    equipItemList = ((DATATYPE_ITEM_INFO_LIST)EntityDef.id2datatypes[28]).createFromStreamEx(stream);

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onEquipItemListChanged(oldval_equipItemList);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onEquipItemListChanged(oldval_equipItemList);
                        }
                    }

                    break;

                case 8:
                    Int32 oldval_equipWeapon = equipWeapon;
                    equipWeapon = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onEquipWeaponChanged(oldval_equipWeapon);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onEquipWeaponChanged(oldval_equipWeapon);
                        }
                    }

                    break;

                case 23:
                    UInt64 oldval_exp = exp;
                    exp = stream.readUint64();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onExpChanged(oldval_exp);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onExpChanged(oldval_exp);
                        }
                    }

                    break;

                case 47005:
                    Int32 oldval_forbids = forbids;
                    forbids = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onForbidsChanged(oldval_forbids);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onForbidsChanged(oldval_forbids);
                        }
                    }

                    break;

                case 6:
                    ITEM_INFO_LIST oldval_itemList = itemList;
                    itemList = ((DATATYPE_ITEM_INFO_LIST)EntityDef.id2datatypes[28]).createFromStreamEx(stream);

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onItemListChanged(oldval_itemList);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onItemListChanged(oldval_itemList);
                        }
                    }

                    break;

                case 5:
                    UInt16 oldval_level = level;
                    level = stream.readUint16();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onLevelChanged(oldval_level);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onLevelChanged(oldval_level);
                        }
                    }

                    break;

                case 41006:
                    UInt32 oldval_modelID = modelID;
                    modelID = stream.readUint32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onModelIDChanged(oldval_modelID);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onModelIDChanged(oldval_modelID);
                        }
                    }

                    break;

                case 41007:
                    Byte oldval_modelScale = modelScale;
                    modelScale = stream.readUint8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onModelScaleChanged(oldval_modelScale);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onModelScaleChanged(oldval_modelScale);
                        }
                    }

                    break;

                case 22:
                    UInt64 oldval_money = money;
                    money = stream.readUint64();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onMoneyChanged(oldval_money);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onMoneyChanged(oldval_money);
                        }
                    }

                    break;

                case 12:
                    Byte oldval_moveSpeed = moveSpeed;
                    moveSpeed = stream.readUint8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onMoveSpeedChanged(oldval_moveSpeed);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onMoveSpeedChanged(oldval_moveSpeed);
                        }
                    }

                    break;

                case 41003:
                    string oldval_name = name;
                    name = stream.readUnicode();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onNameChanged(oldval_name);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onNameChanged(oldval_name);
                        }
                    }

                    break;

                case 40000:
                    Vector3 oldval_position = position;
                    position = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }

                    break;

                case 20:
                    Int32 oldval_rating = rating;
                    rating = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onRatingChanged(oldval_rating);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onRatingChanged(oldval_rating);
                        }
                    }

                    break;

                case 4:
                    Byte oldval_roleTypeCell = roleTypeCell;
                    roleTypeCell = stream.readUint8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onRoleTypeCellChanged(oldval_roleTypeCell);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onRoleTypeCellChanged(oldval_roleTypeCell);
                        }
                    }

                    break;

                case 40002:
                    stream.readUint32();
                    break;

                case 41001:
                    UInt32 oldval_spaceUType = spaceUType;
                    spaceUType = stream.readUint32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onSpaceUTypeChanged(oldval_spaceUType);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onSpaceUTypeChanged(oldval_spaceUType);
                        }
                    }

                    break;

                case 26:
                    Int32 oldval_stamina = stamina;
                    stamina = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onStaminaChanged(oldval_stamina);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onStaminaChanged(oldval_stamina);
                        }
                    }

                    break;

                case 47006:
                    SByte oldval_state = state;
                    state = stream.readInt8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onStateChanged(oldval_state);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onStateChanged(oldval_state);
                        }
                    }

                    break;

                case 24:
                    Int32 oldval_strength = strength;
                    strength = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onStrengthChanged(oldval_strength);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onStrengthChanged(oldval_strength);
                        }
                    }

                    break;

                case 47007:
                    Byte oldval_subState = subState;
                    subState = stream.readUint8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onSubStateChanged(oldval_subState);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onSubStateChanged(oldval_subState);
                        }
                    }

                    break;

                case 41004:
                    UInt32 oldval_uid = uid;
                    uid = stream.readUint32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onUidChanged(oldval_uid);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onUidChanged(oldval_uid);
                        }
                    }

                    break;

                case 41005:
                    UInt32 oldval_utype = utype;
                    utype = stream.readUint32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onUtypeChanged(oldval_utype);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onUtypeChanged(oldval_utype);
                        }
                    }

                    break;

                default:
                    break;
                }
                ;
            }
        }
Beispiel #29
0
        public override void onUpdatePropertys(MemoryStream stream)
        {
            ScriptModule sm = EntityDef.moduledefs["Room"];
            Dictionary <UInt16, Property> pdatas = sm.idpropertys;

            while (stream.length() > 0)
            {
                UInt16 _t_utype       = 0;
                UInt16 _t_child_utype = 0;

                {
                    if (sm.usePropertyDescrAlias)
                    {
                        _t_utype       = stream.readUint8();
                        _t_child_utype = stream.readUint8();
                    }
                    else
                    {
                        _t_utype       = stream.readUint16();
                        _t_child_utype = stream.readUint16();
                    }
                }

                Property prop = null;

                if (_t_utype == 0)
                {
                    prop = pdatas[_t_child_utype];
                }
                else
                {
                    Property pComponentPropertyDescription = pdatas[_t_utype];
                    switch (pComponentPropertyDescription.properUtype)
                    {
                    default:
                        break;
                    }

                    return;
                }

                switch (prop.properUtype)
                {
                case 40001:
                    Vector3 oldval_direction = direction;
                    direction = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }

                    break;

                case 8:
                    Byte oldval_isPrivate = isPrivate;
                    isPrivate = stream.readUint8();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onIsPrivateChanged(oldval_isPrivate);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onIsPrivateChanged(oldval_isPrivate);
                        }
                    }

                    break;

                case 40000:
                    Vector3 oldval_position = position;
                    position = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }

                    break;

                case 7:
                    UInt16 oldval_roomKey = roomKey;
                    roomKey = stream.readUint16();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onRoomKeyChanged(oldval_roomKey);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onRoomKeyChanged(oldval_roomKey);
                        }
                    }

                    break;

                case 40002:
                    stream.readUint32();
                    break;

                default:
                    break;
                }
                ;
            }
        }
Beispiel #30
0
        public override void onUpdatePropertys(MemoryStream stream)
        {
            ScriptModule sm = EntityDef.moduledefs["Account"];
            Dictionary <UInt16, Property> pdatas = sm.idpropertys;

            while (stream.length() > 0)
            {
                UInt16 _t_utype       = 0;
                UInt16 _t_child_utype = 0;

                {
                    if (sm.usePropertyDescrAlias)
                    {
                        _t_utype       = stream.readUint8();
                        _t_child_utype = stream.readUint8();
                    }
                    else
                    {
                        _t_utype       = stream.readUint16();
                        _t_child_utype = stream.readUint16();
                    }
                }

                Property prop = null;

                if (_t_utype == 0)
                {
                    prop = pdatas[_t_child_utype];
                }
                else
                {
                    Property pComponentPropertyDescription = pdatas[_t_utype];
                    switch (pComponentPropertyDescription.properUtype)
                    {
                    default:
                        break;
                    }

                    return;
                }

                switch (prop.properUtype)
                {
                case 40001:
                    Vector3 oldval_direction = direction;
                    direction = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onDirectionChanged(oldval_direction);
                        }
                    }

                    break;

                case 2:
                    Int32 oldval_modelType = modelType;
                    modelType = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onModelTypeChanged(oldval_modelType);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onModelTypeChanged(oldval_modelType);
                        }
                    }

                    break;

                case 6:
                    Int64 oldval_playerExp = playerExp;
                    playerExp = stream.readInt64();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPlayerExpChanged(oldval_playerExp);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPlayerExpChanged(oldval_playerExp);
                        }
                    }

                    break;

                case 5:
                    UInt16 oldval_playerID = playerID;
                    playerID = stream.readUint16();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPlayerIDChanged(oldval_playerID);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPlayerIDChanged(oldval_playerID);
                        }
                    }

                    break;

                case 11:
                    Int32 oldval_playerLayer = playerLayer;
                    playerLayer = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPlayerLayerChanged(oldval_playerLayer);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPlayerLayerChanged(oldval_playerLayer);
                        }
                    }

                    break;

                case 9:
                    Int32 oldval_playerMass = playerMass;
                    playerMass = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPlayerMassChanged(oldval_playerMass);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPlayerMassChanged(oldval_playerMass);
                        }
                    }

                    break;

                case 4:
                    string oldval_playerName = playerName;
                    playerName = stream.readUnicode();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPlayerNameChanged(oldval_playerName);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPlayerNameChanged(oldval_playerName);
                        }
                    }

                    break;

                case 3:
                    string oldval_playerNameBase = playerNameBase;
                    playerNameBase = stream.readUnicode();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPlayerNameBaseChanged(oldval_playerNameBase);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPlayerNameBaseChanged(oldval_playerNameBase);
                        }
                    }

                    break;

                case 8:
                    float oldval_playerScale = playerScale;
                    playerScale = stream.readFloat();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPlayerScaleChanged(oldval_playerScale);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPlayerScaleChanged(oldval_playerScale);
                        }
                    }

                    break;

                case 10:
                    float oldval_playerSpeed = playerSpeed;
                    playerSpeed = stream.readFloat();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPlayerSpeedChanged(oldval_playerSpeed);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPlayerSpeedChanged(oldval_playerSpeed);
                        }
                    }

                    break;

                case 7:
                    Int32 oldval_playerState = playerState;
                    playerState = stream.readInt32();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPlayerStateChanged(oldval_playerState);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPlayerStateChanged(oldval_playerState);
                        }
                    }

                    break;

                case 40000:
                    Vector3 oldval_position = position;
                    position = stream.readVector3();

                    if (prop.isBase())
                    {
                        if (inited)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }
                    else
                    {
                        if (inWorld)
                        {
                            onPositionChanged(oldval_position);
                        }
                    }

                    break;

                case 40002:
                    stream.readUint32();
                    break;

                default:
                    break;
                }
                ;
            }
        }