/// <summary> /// 进入温泉 /// </summary> /// <param name="cb"></param> /// <returns></returns> public bool SendMsgPetSystemGM2GCReqPetEnterPool(UInt32 petID, EHotSpringType hotSpringType, CBMsgPetSystemGM2GCAckPetEnterPool cb) { CMsgPetSystemGC2GMReqPetEnterPool req = new CMsgPetSystemGC2GMReqPetEnterPool(petID, hotSpringType); CMsgPetSystemGM2GCAckPetEnterPool.cb = cb; return(CGameClient.Singleton.SendMsg(req)); }
public bool SerializeFrom(UnityUtility.CStream msgStream) { m_petID = msgStream.ReadUInt(); m_petTPID = msgStream.ReadUInt(); m_petFriendlyLevel = msgStream.ReadUInt(); m_petFriendlyValue = msgStream.ReadUInt(); m_maxPetFriendlyValue = msgStream.ReadUInt(); m_petStatus = (EPetStatus)msgStream.ReadUInt(); m_hotSpringType = (EHotSpringType)msgStream.ReadUInt(); m_petTaskType = (EHotSpringTaskStatus)msgStream.ReadUInt(); m_hotSpringTaskType = (EHotSpringTaskType)msgStream.ReadUInt(); m_leftTime = msgStream.ReadUInt(); m_petBattleAttribute.SerializeFrom(msgStream); m_petGrowUpAttribute.SerializeFrom(msgStream); // 战斗力公式 i. 战斗力=攻击力*2 + 防御力 + 生命值/5 + 命中/5 + 闪避/2 + 暴击/2 + 抗暴/5 m_combat = m_petBattleAttribute.Atk * 2 + m_petBattleAttribute.Def + m_petBattleAttribute.MaxHP / 5 + m_petBattleAttribute.AtkCrift / 2 + m_petBattleAttribute.DefCrift / 5 + m_petBattleAttribute.HitRate / 5 + m_petBattleAttribute.MissRate / 2; return(true); }
public CMsgPetSystemGC2GMReqPetEnterPool(UInt32 petID, EHotSpringType hotSpringType) : base(CServerType.SRVTYPE_GAMESERVER, CFuncType.EFUNCTYPE_PETSYSTEM, CPetSystemMsgNumID.EMSGNUMID_PETSYSTEM_GC2GM_REQ_PET_ENTERPOOL) { m_petID = petID; m_hotSpringType = hotSpringType; }