Files
JJBB/Assets/Project/Script/Player/Relation/Relation.cs

117 lines
2.4 KiB
C#
Raw Normal View History

2024-08-23 15:49:34 +08:00
/********************************************************************************
* Relation.cs
* \Script\Player\Relation\Relation.cs
*
* 2014-02-14
*
*
*
*********************************************************************************/
using UnityEngine;
using System;
using System.Collections;
using Games.GlobeDefine;
using Module.Log;
public class Relation
{
//Guid
private UInt64 m_Guid;
public UInt64 Guid
{
get { return m_Guid; }
set { m_Guid = value; }
}
//角色名字
private string m_szName;
public string Name
{
get { return m_szName; }
set { m_szName = value; }
}
//等级
private int m_nLevel;
public int Level
{
get { return m_nLevel; }
set { m_nLevel = value; }
}
//职业
private int m_nProfession;
public int Profession
{
get { return m_nProfession; }
set { m_nProfession = value; }
}
//战斗力
private int m_nCombatNum;
public int CombatNum
{
get { return m_nCombatNum; }
set { m_nCombatNum = value; }
}
//头像框
private int m_HeadType;
public int HeadType
{
get { return m_HeadType; }
set { m_HeadType = value; }
}
//对话框气泡
private int m_ChatPopType;
public int ChatPopType
{
get { return m_ChatPopType; }
set { m_ChatPopType = value; }
}
//状态
private int m_nState = (int)CharacterDefine.RELATION_TYPE.OFFLINE;
public int State
{
get
{
return m_nState;
}
set
{
LogModule.DebugLog("Player :" + Name + ", onlineState:" + (CharacterDefine.RELATION_TYPE)value);
m_nState = value;
}
}
//合法性判断
public bool IsValid()
{
return m_Guid != GlobeVar.INVALID_GUID;
}
//时间信息
private UInt32 m_timeInfotime;
public UInt32 TimeInfo
{
get { return m_timeInfotime; }
set { m_timeInfotime = value; }
}
//friendPont - 好友度
private int _FriendPoint = 1;
public int FriendPoint
{
get
{
return _FriendPoint;
}
set
{
_FriendPoint = Mathf.Max(0, value);
}
}
}