logoHourGlass
Battle.UseTech

Battle.UseTech

Battle.UseTech(CharIndex, SkillSlot, TechSlot, Target)

函數功能

讓對象執行指定的戰鬥技能釋放,必須在對象Battle.IsWaitingCommand(index)返回值爲1時纔可以有效使用。

參數說明

  • CharIndex數值型 玩家對象index
  • SkillSlot數值型 技能所在技能欄位置
  • TechSlot數值型 指定等級的技能所在位置
  • Target數值型 施法目標對象在戰場中的位置

返回值

0 失敗, 1 成功

範例

if( Battle.IsWaitingCommand(index) == 1) then
    Battle.UseTech(index, 0, 0, 11);
    print("offline player use tech");
end