bool HandleOtherRoleIsInMonthCardChange(NetCmdBase obj) { LC_Cmd_TableChangeRoleIsInMonthCard ncb = (LC_Cmd_TableChangeRoleIsInMonthCard)obj; if (m_TableRole.ContainsKey(ncb.dwDestUserID)) { m_TableRole[ncb.dwDestUserID].SetIsInMonthCard(ncb.IsInMonthCard); tagTableChangeEvent pEvent = new tagTableChangeEvent(ncb.dwDestUserID); //MsgEventHandle.HandleMsg(pEvent); } return(true); }
bool HandleOtherRoleAchievementPointChange(NetCmdBase obj) { LC_Cmd_TableChangeRoleAchievementPoint ncb = (LC_Cmd_TableChangeRoleAchievementPoint)obj; if (m_TableRole.ContainsKey(ncb.dwDestUserID)) { m_TableRole[ncb.dwDestUserID].SetAchievementPoint(ncb.dwAchievementPoint); tagTableChangeEvent pEvent = new tagTableChangeEvent(ncb.dwDestUserID); //MsgEventHandle.HandleMsg(pEvent); } return(true); }
bool HandleOtherRoleIpAddressChange(NetCmdBase obj) { LC_Cmd_TableChangeRoleIpAddress ncb = (LC_Cmd_TableChangeRoleIpAddress)obj; if (m_TableRole.ContainsKey(ncb.dwDestUserID)) { m_TableRole[ncb.dwDestUserID].SetIPAddress(ncb.IpAddress); tagTableChangeEvent pEvent = new tagTableChangeEvent(ncb.dwDestUserID); //MsgEventHandle.HandleMsg(pEvent); } return(true); }
//bool HandleOtherRoleExpChange(NetCmdBase obj) //{ // LC_Cmd_TableChangeRoleExp ncb = (LC_Cmd_TableChangeRoleExp)obj; // if (m_TableRole.ContainsKey(ncb.dwDestUserID)) // { // m_TableRole[ncb.dwDestUserID].SetExp(ncb.dwExp); // tagTableChangeEvent pEvent = new tagTableChangeEvent(ncb.dwDestUserID); // MsgEventHandle.HandleMsg(pEvent); // } // return true; //} bool HandleOtherRoleTitleIDChange(NetCmdBase obj) { LC_Cmd_TableChangeRoleTitle ncb = (LC_Cmd_TableChangeRoleTitle)obj; if (m_TableRole.ContainsKey(ncb.dwDestUserID)) { m_TableRole[ncb.dwDestUserID].SetTitleID(ncb.TitleID); tagTableChangeEvent pEvent = new tagTableChangeEvent(ncb.dwDestUserID); //MsgEventHandle.HandleMsg(pEvent); } return(true); }
bool HandleOtherRoleVipLevelChange(NetCmdBase obj) { //桌子上玩家VIP变化了 LC_Cmd_TableChangeRoleVipLevel ncb = (LC_Cmd_TableChangeRoleVipLevel)obj; if (m_TableRole.ContainsKey(ncb.dwDestUserID)) { m_TableRole[ncb.dwDestUserID].SetVipLevel(ncb.VipLevel); tagTableChangeEvent pEvent = new tagTableChangeEvent(ncb.dwDestUserID); //MsgEventHandle.HandleMsg(pEvent); } return(true); }
bool HandleResetOtherUser(NetCmdBase obj) { LC_Cmd_ResetOtherUserInfo ncb = (LC_Cmd_ResetOtherUserInfo)obj; TableRole pTableRole = new TableRole(ncb.UserInfo); m_TableRole.Add(pTableRole.GetUserID(), pTableRole); m_TableRoleSeat.Add(pTableRole.GetSeat(), pTableRole); tagTableChangeEvent pEvent = new tagTableChangeEvent(ncb.UserInfo.dwUserID); // MsgEventHandle.HandleMsg(pEvent); return(true); }
bool HandleOtherRoleCharmChanger(NetCmdBase obj) { //修改桌子上玩家的魅力数据 LC_Cmd_TableChangeRoleCharmValue ncb = (LC_Cmd_TableChangeRoleCharmValue)obj; if (m_TableRole.ContainsKey(ncb.dwDestUserID)) { m_TableRole[ncb.dwDestUserID].SetCharmInfo(ncb.CharmArray); tagTableChangeEvent pEvent = new tagTableChangeEvent(ncb.dwDestUserID); //MsgEventHandle.HandleMsg(pEvent); } return(true); }
bool HandleOtherRoleGobleNumChange(NetCmdBase obj) { LC_Cmd_TableChangeRoleGlobe ncb = (LC_Cmd_TableChangeRoleGlobe)obj; //修改远程玩家的等级 if (m_TableRole.ContainsKey(ncb.dwDestUserID)) { m_TableRole[ncb.dwDestUserID].SetGlobel(Convert.ToUInt32(ncb.dwGlobelSum + m_TableRole[ncb.dwDestUserID].GetGlobel())); tagTableChangeEvent pEvent = new tagTableChangeEvent(ncb.dwDestUserID); //MsgEventHandle.HandleMsg(pEvent); } return(true); }
bool HandleOtherRoleNickNameChange(NetCmdBase obj) { LC_Cmd_TableChangeRoleNickName ncb = (LC_Cmd_TableChangeRoleNickName)obj; //修改远程玩家的等级 if (m_TableRole.ContainsKey(ncb.dwDestUserID)) { m_TableRole[ncb.dwDestUserID].SetNickName(ncb.NickName); tagTableChangeEvent pEvent = new tagTableChangeEvent(ncb.dwDestUserID); //MsgEventHandle.HandleMsg(pEvent); } return(true); }
bool HandleOtherRoleLevelChange(NetCmdBase obj) { LC_Cmd_TableChangeRoleLevel ncb = (LC_Cmd_TableChangeRoleLevel)obj; //修改远程玩家的等级 if (m_TableRole.ContainsKey(ncb.dwDestUserID)) { UInt16 OldLevel = m_TableRole[ncb.dwDestUserID].GetLevel(); m_TableRole[ncb.dwDestUserID].SetLevel(ncb.wLevel); tagTableChangeEvent pEvent = new tagTableChangeEvent(ncb.dwDestUserID); //MsgEventHandle.HandleMsg(pEvent); tagTableLevelChangeEvent pLevelEvent = new tagTableLevelChangeEvent(ncb.dwDestUserID, OldLevel, ncb.wLevel); //MsgEventHandle.HandleMsg(pLevelEvent); } return(true); }
public bool OnAddUserGlobelByCatchedData(Byte Seat, int GlobelSum) //修改指定位置上玩家的金币 或者是积分 必须是 与鱼群相关的 { //因为捕获鱼 添加金币 Seat = SceneRuntime.ClientToServerSeat(Seat); bool IsInMonth = (PlayerRole.Instance.RoleInfo.RoleMe.GetMonthID() != 0); if (PlayerRole.Instance.RoleInfo.RoleMe.GetSeat() == Seat) { if (PlayerRole.Instance.RoleInfo.RoleMe == null) { return(false); } if (IsInMonth) { if (GlobelSum >= 0) { PlayerRole.Instance.RoleInfo.RoleMe.SetMonthScore( Convert.ToUInt32(PlayerRole.Instance.RoleInfo.RoleMe.GetMonthScore() + GlobelSum)); } else { if (PlayerRole.Instance.RoleInfo.RoleMe.GetMonthGlobel() < GlobelSum * -1) { return(false); } PlayerRole.Instance.RoleInfo.RoleMe.SetMonthGlobel( Convert.ToUInt32(PlayerRole.Instance.RoleInfo.RoleMe.GetMonthGlobel() + GlobelSum)); } //tagMonthChangeEvent pEvent = new tagMonthChangeEvent(PlayerRole.Instance.RoleInfo.RoleMe.GetUserID()); //MsgEventHandle.HandleMsg(pEvent); tagMatchScoreAddEvent pEvent = new tagMatchScoreAddEvent(PlayerRole.Instance.RoleInfo.RoleMe.GetUserID()); //MsgEventHandle.HandleMsg(pEvent); IEvent evnt = new Event(EventMsg.UPDATE_PLAYSCORE); EventManager.Instance.DispatchEvent(evnt); return(true); } else { if (GlobelSum < 0 && PlayerRole.Instance.RoleInfo.RoleMe.GetGlobel() < -1 * GlobelSum) { return(false); } PlayerRole.Instance.RoleInfo.RoleMe.SetGlobel( Convert.ToUInt32(PlayerRole.Instance.RoleInfo.RoleMe.GetGlobel() + GlobelSum)); tagRoleChangeEvent pEvent = new tagRoleChangeEvent(); //MsgEventHandle.HandleMsg(pEvent); return(true); } } else { if (IsInMonth) { TableRole pTableRole = PlayerRole.Instance.TableManager.GetTableRole(Seat); if (pTableRole == null) { return(false); } if (GlobelSum >= 0) { pTableRole.SetMonthScore(Convert.ToUInt32(pTableRole.GetMonthScore() + GlobelSum)); } else { if (pTableRole.GetMonthGlobel() < GlobelSum * -1) { return(false); } pTableRole.SetMonthGlobel(Convert.ToUInt32(pTableRole.GetMonthGlobel() + GlobelSum)); } tagMonthChangeEvent pEvent = new tagMonthChangeEvent(pTableRole.GetUserID()); //MsgEventHandle.HandleMsg(pEvent); return(true); } else { if (GlobelSum < 0 && PlayerRole.Instance.TableManager.GetTableRole(Seat).GetGlobel() < -1 * GlobelSum) { return(false); } TableRole pTableRole = PlayerRole.Instance.TableManager.GetTableRole(Seat); if (pTableRole == null) { return(false); } pTableRole.SetGlobel(Convert.ToUInt32(pTableRole.GetGlobel() + GlobelSum)); tagTableChangeEvent pEvent = new tagTableChangeEvent(pTableRole.GetUserID()); //MsgEventHandle.HandleMsg(pEvent); return(true); } } return(false); }