コード例 #1
0
ファイル: Tbl_Skill.cs プロジェクト: ftcaicai/ArkClient
	public Tbl_Skill_Record(BinaryReader br)// : base(_element)
	{
		m_Index = br.ReadInt32();
		m_SkillName_Index = br.ReadInt32();
		m_Description_Index = br.ReadInt32();
		m_SkillName_Print = (eSkillNamePrint)br.ReadInt32();
		m_SkillReset = (eSkillReset)br.ReadInt32();
		m_nSkillResetCost = br.ReadInt32();
		m_SkillAutoTarget = (eSkillAutoTarget)br.ReadInt32();
		m_Skill_Icon = br.ReadString();
		
		m_Class = (eCLASS)br.ReadInt32();
		m_Skill_Type = (eSKILL_TYPE)br.ReadInt32();
		m_Skill_TargetType = (eSkill_TargetType)br.ReadInt32();		
		m_SkillIcon_Enable_Target = (eSkillIcon_Enable_Target)br.ReadInt32();
		m_SkillIcon_Enable_Condition = (eSkillIcon_Enable_Condition)br.ReadInt32();
		m_SkillIcon_Enable_ConditionValue = br.ReadInt32();
		
		m_Command_Type = (eCommand_Type)br.ReadInt32();
		m_CommandPicking_Type = (eCommandPicking_Type)br.ReadInt32();
		m_Attack_Direction = (eATTACK_DIRECTION)br.ReadInt32();
		m_CoolTimeGroup = br.ReadInt32();
		m_DisableInPvP = (eDisableInPvP)br.ReadInt32();
		m_DisableInRaid = (eDisableInRaid)br.ReadInt32();
        m_DisableInField = (eDisableInRaid)br.ReadInt32();
		m_DisableInInDun = (eDisableInInDun)br.ReadInt32();
		
		for(int i=1; i<=AsTableManager.sSkillLevelPotencyCount; ++i)
		{
			ePotency_Enable_Target check_target = (ePotency_Enable_Target)br.ReadInt32();
			ePotency_Enable_Condition check_condition = (ePotency_Enable_Condition)br.ReadInt32();
			float check_conditionValue = br.ReadSingle();
			ePotency_Enable_Target check_target2 = (ePotency_Enable_Target)br.ReadInt32();
			ePotency_Enable_Condition check_condition2 = (ePotency_Enable_Condition)br.ReadInt32();
			float check_conditionValue2 = br.ReadSingle();
			ePotency_Type type = (ePotency_Type)br.ReadInt32();
			ePotency_Target target = (ePotency_Target)br.ReadInt32();
			ePotency_DurationType duration = (ePotency_DurationType)br.ReadInt32();
			ePotency_Attribute attribute = (ePotency_Attribute)br.ReadInt32();
			ePotency_Element element = ePotency_Element.NONE;
			string buff = br.ReadString();
			int buffToolTipIdx = br.ReadInt32();
			
			Tbl_Skill_Potency potency = 
				new Tbl_Skill_Potency(check_target, check_condition, check_conditionValue,
					check_target2, check_condition2, check_conditionValue2,
					type, target, duration, attribute, element, buff, buffToolTipIdx);
			
			m_listSkillPotency.Add(potency);
		}
	}
コード例 #2
0
ファイル: AsPlayerFsm.cs プロジェクト: ftcaicai/ArkClient
	bool IsAvailableDoubleTapSkill( eCLASS _class, eCommandPicking_Type _pickingType)
	{
		float curMP = UserEntity.GetProperty<float>( eComponentProperty.MP_CUR);
//		Tbl_Skill_Record skillRecord = AsTableManager.Instance.GetTbl_Skill_RecordByPickingType( _class, _pickingType);
		Tbl_Skill_Record skillRecord = SkillBook.Instance.GetLearnedDoubleTapSkill( _pickingType);

		if( null == skillRecord)
		{
			Debug.LogError( "AsPlayerFsm:: IsAvailableDoubleTapSkill: character has no [" + _pickingType + "] double tap skill");
			return false;
		}

		SkillView view = null;
		if( SkillBook.Instance.dicCurSkill.ContainsKey( skillRecord.Index) == true)
			view = SkillBook.Instance.dicCurSkill[skillRecord.Index];
		else
			return false;

		if( view == null)
			return false;

		Tbl_SkillLevel_Record skillLevelRecord = AsTableManager.Instance.GetTbl_SkillLevel_Record( view.nSkillLevel, view.nSkillTableIdx);

		if( curMP < ( float)skillLevelRecord.Mp_Decrease)
		{
			AsMyProperty.Instance.AlertMP();
			return false;
		}

		return true;
	}
コード例 #3
0
ファイル: SkillBook.cs プロジェクト: ftcaicai/ArkClient
	public Tbl_Skill_Record GetLearnedDoubleTapSkill(eCommandPicking_Type _pickingType)
	{
		foreach(KeyValuePair<int, SkillView> pair in m_dicFinger)
		{
			Tbl_Skill_Record record = AsTableManager.Instance.GetTbl_Skill_Record(pair.Value.nSkillTableIdx);
			if(record.Command_Type == eCommand_Type.DoubleTab && record.CommandPicking_Type == _pickingType)
			{
				return record;
			}
		}
		
		return null;
	}