Example #1
0
 public FRIEND_UPDATE_PAK(FriendChangeStateEnum type, Friend friend, int index)
 {
     this.type   = type;
     state       = (FriendStateEnum)friend.state;
     this.friend = friend;
     this.index  = index;
 }
Example #2
0
        public static uint GetFriendStatus(Friend friend)
        {
            PlayerInfo info = friend.player;

            if (info == null)
            {
                return(0);
            }
            int             serverId = 0, channelId = 0, roomId = 0;
            FriendStateEnum state = FriendStateEnum.None;

            if (friend.removed)
            {
                state = FriendStateEnum.Offline;
            }
            else if (friend.state > 0)
            {
                state = (FriendStateEnum)friend.state;
            }
            else
            {
                GetPlayerLocation(info.status, info.isOnline, out state, out roomId, out channelId, out serverId);
            }
            return(GetPlayerStatus(roomId, channelId, serverId, (int)state));
        }
Example #3
0
 public CLAN_MEMBER_INFO_CHANGE_PAK(Account player, FriendStateEnum memberState)
 {
     this.player = player;
     if (memberState == 0)
     {
         status = Utilities.GetClanStatus(player.status, player.isOnline);
     }
     else
     {
         status = Utilities.GetClanStatus(memberState);
     }
 }
Example #4
0
 public FriendMemberType(int playerId, byte sex, byte job, short level, FriendStateEnum state, int close_points, byte issf_, string name, string class_name)
 {
     this.playerId     = playerId;
     this.sex          = sex;
     this.job          = job;
     this.level        = level;
     this.state        = state;
     this.close_points = close_points;
     this.issf_        = issf_;
     this.name         = name;
     this.class_name   = class_name;
 }
Example #5
0
 public FriendListType(FriendStateEnum my_state, int favor_value, int flower_count, int[] flowers_ids, int friend_count, FriendMemberType[] friends,
                       int blacklisted_friend_count, BlacklistedFriendMemberType[] blacklist, int murdered_friend_count, FriendMemberType[] murderedlist)
 {
     this.my_state                 = my_state;
     this.favor_value              = favor_value;
     this.flower_count             = flower_count;
     this.flowers_ids              = flowers_ids;
     this.friend_count             = friend_count;
     this.friends                  = friends;
     this.blacklisted_friend_count = blacklisted_friend_count;
     this.blacklist                = blacklist;
     this.murdered_friend_count    = murdered_friend_count;
     this.murderedlist             = murderedlist;
 }
Example #6
0
 public ProtegeType(int playerId, string name, int job, byte sex, int level, int close_points, int close_points_total,
                    int time, byte guide_quest_count, uint[] questids, int last_logout_time, FriendStateEnum state)
 {
     this.playerId           = playerId;
     this.name               = name;
     this.job                = job;
     this.sex                = sex;
     this.level              = level;
     this.close_points       = close_points;
     this.close_points_total = close_points_total;
     this.time               = time;
     this.guide_quest_count  = guide_quest_count;
     this.questids           = questids;
     this.last_logout_time   = last_logout_time;
     this.state              = state;
 }
 public MasterFactionType(int playerId, string name, int job, byte sex, int level, int close_points, int close_points_total,
                          int time, int titleid, byte m_is_faction, string m_faction_name, int last_logout_time, FriendStateEnum state)
 {
     this.playerId           = playerId;
     this.name               = name;
     this.job                = job;
     this.sex                = sex;
     this.level              = level;
     this.close_points       = close_points;
     this.close_points_total = close_points_total;
     this.time               = time;
     this.titleid            = titleid;
     this.m_is_faction       = m_is_faction;
     this.m_faction_name     = m_faction_name;
     this.last_logout_time   = last_logout_time;
     this.state              = state;
 }
Example #8
0
 public static void GetPlayerLocation(AccountStatus status, bool isOnline, out FriendStateEnum state, out int roomId, out int channelId, out int serverId, out int clanFId)
 {
     roomId    = 0;
     channelId = 0;
     serverId  = 0;
     clanFId   = 0;
     if (isOnline)
     {
         if (status.roomId != 255)
         {
             roomId    = status.roomId;
             channelId = status.channelId;
             state     = FriendStateEnum.Room;
         }
         else if ((status.clanFId != 255 || status.roomId == 255) && status.channelId != 255)
         {
             channelId = status.channelId;
             state     = FriendStateEnum.Lobby;
         }
         else if (status.roomId == 255 && status.channelId == 255)
         {
             state = FriendStateEnum.Online;
         }
         else
         {
             state = FriendStateEnum.Offline;
         }
         if (status.serverId != 255)
         {
             serverId = status.serverId;
         }
         if (status.clanFId != 255)
         {
             clanFId = status.clanFId + 1;
         }
     }
     else
     {
         state = FriendStateEnum.Offline;
     }
 }
Example #9
0
 public static ulong GetClanStatus(FriendStateEnum state)
 {
     return(GetPlayerStatus(0, 0, 0, 0, (int)state));
 }
 public BlacklistedFriendMemberType(int blackListerBlackListedPlayerId, string playerName, int playerId, byte sex, byte job, short level, FriendStateEnum state, int close_points, byte issf_, string name, string class_name) : base(playerId, sex, job, level, state, close_points, issf_, name, class_name)
 {
     this.blackListedPlayerId = blackListerBlackListedPlayerId;
     this.playerName          = playerName;
 }