Beispiel #1
0
	public void SaveCurCharStatTotal( body_SC_ATTR_TOTAL _result)
	{
		AsUserEntity player = AsUserInfo.Instance.GetCurrentUserEntity();

		if( player != null)
		{
			player.SetProperty( eComponentProperty.HP_CUR, _result.fHpCur);
			player.SetProperty( eComponentProperty.HP_MAX, _result.sFinalSatus.fHPMax);
			player.SetProperty( eComponentProperty.MP_CUR, _result.fMpCur);
			player.SetProperty( eComponentProperty.MP_MAX, _result.sFinalSatus.fMPMax);
			
			savedCharStat.sFinalStatus = _result.sFinalSatus;
			
			player.HandleMessage( new Msg_MoveSpeedRefresh( _result.sFinalSatus.nMoveSpeed / 100));
			player.HandleMessage( new Msg_AttackSpeedRefresh( _result.sFinalSatus.nAtkSpeed * AsProperty.s_BaseAttackSpeedRatio));
			savedCharStat.hpCur_ = _result.fHpCur;
			savedCharStat.mpCur_ = _result.fMpCur;
		}
	}
Beispiel #2
0
	private void ReciveAttrTotal(byte[] _packet)
	{
		Debug.Log("ReciveAttrTotal");

        body_SC_ATTR_TOTAL data = new body_SC_ATTR_TOTAL();
        data.PacketBytesToClass(_packet);

		AsUserInfo.Instance.SaveCurCharStatTotal( data );
	}