From 7b29e652f52e2361767243b946f02020ebe6bc5a Mon Sep 17 00:00:00 2001 From: Zach Toogood Date: Tue, 28 Jan 2025 20:49:24 +0000 Subject: [PATCH 1/2] Trusts: Migrate all simple gambits to regular gambits Regex 1: Capture: addSimpleGambit\(([^,]+), ([^,]+), ([^,]+), ([^,]+), ([^,]+), ([^,]+)\) Replace: addGambit($1, { $2, $3 }, { $4, $5, $6 }) Regex 2: Capture: addGambit\(([\w\.]+), ([\w\.]+), ([\w\.]+), ([\w\.]+), ([\w\.]+), ([\w\.]+)(?:, ([\w\.]+))?\) Replace: addGambit($1, { $2, $3 }, { $4, $5, $6 }, $7) Cleanup: You might have some trailing commas lurking around. Clean those up by hand - LuaLanguageServer will point things out for you. --- scripts/actions/spells/trust/abquhbah.lua | 6 +-- scripts/actions/spells/trust/adelheid.lua | 22 +++++------ .../actions/spells/trust/ajido-marujido.lua | 12 ++---- scripts/actions/spells/trust/apururu_uc.lua | 36 +++++++++--------- scripts/actions/spells/trust/ayame.lua | 9 ++--- scripts/actions/spells/trust/cherukiki.lua | 26 ++++++------- scripts/actions/spells/trust/curilla.lua | 9 ++--- scripts/actions/spells/trust/excenmille.lua | 9 ++--- scripts/actions/spells/trust/fablinix.lua | 20 +++++----- .../actions/spells/trust/ferreous_coffin.lua | 30 +++++++-------- scripts/actions/spells/trust/gessho.lua | 12 +++--- scripts/actions/spells/trust/iron_eater.lua | 3 +- scripts/actions/spells/trust/joachim.lua | 22 +++++------ scripts/actions/spells/trust/koru-moru.lua | 3 ++ scripts/actions/spells/trust/kupipi.lua | 36 +++++++++--------- .../actions/spells/trust/lehko_habhoka.lua | 6 +-- scripts/actions/spells/trust/lion.lua | 8 ++-- scripts/actions/spells/trust/lion_ii.lua | 2 +- scripts/actions/spells/trust/maat.lua | 3 +- scripts/actions/spells/trust/maat_uc.lua | 6 +-- .../actions/spells/trust/mihli_aliapoh.lua | 37 +++++++++---------- scripts/actions/spells/trust/monberaux.lua | 28 +++++++------- scripts/actions/spells/trust/mumor.lua | 18 ++++----- .../actions/spells/trust/naja_salaheem.lua | 9 ++--- scripts/actions/spells/trust/naji.lua | 3 +- scripts/actions/spells/trust/nanaa_mihgo.lua | 3 +- scripts/actions/spells/trust/nashmeira_ii.lua | 26 ++++++------- scripts/actions/spells/trust/prishe.lua | 2 +- scripts/actions/spells/trust/prishe_ii.lua | 10 ++--- scripts/actions/spells/trust/qultada.lua | 6 +-- scripts/actions/spells/trust/rainemard.lua | 20 +++++----- scripts/actions/spells/trust/rughadjeen.lua | 18 ++++----- .../actions/spells/trust/semih_lafihna.lua | 14 +++---- scripts/actions/spells/trust/shantotto.lua | 4 +- scripts/actions/spells/trust/shantotto_ii.lua | 4 +- scripts/actions/spells/trust/shikaree_z.lua | 36 +++++++++--------- scripts/actions/spells/trust/sylvie_uc.lua | 24 ++++++------ scripts/actions/spells/trust/tenzen.lua | 6 +-- scripts/actions/spells/trust/tenzen_ii.lua | 2 +- scripts/actions/spells/trust/trion.lua | 9 ++--- scripts/actions/spells/trust/uka_totlihn.lua | 22 +++++------ scripts/actions/spells/trust/ulmia.lua | 4 +- scripts/actions/spells/trust/valaineral.lua | 12 ++---- scripts/actions/spells/trust/volker.lua | 14 +++---- .../actions/spells/trust/yoran-oran_uc.lua | 30 +++++++-------- scripts/actions/spells/trust/zeid_ii.lua | 18 +++------ 46 files changed, 310 insertions(+), 349 deletions(-) diff --git a/scripts/actions/spells/trust/abquhbah.lua b/scripts/actions/spells/trust/abquhbah.lua index 42a0d364f68..b3d1148c1f9 100644 --- a/scripts/actions/spells/trust/abquhbah.lua +++ b/scripts/actions/spells/trust/abquhbah.lua @@ -14,9 +14,9 @@ end spellObject.onMobSpawn = function(mob) xi.trust.message(mob, xi.trust.messageOffset.SPAWN) - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_SC_AVAILABLE, 0, ai.r.JA, ai.s.SPECIFIC, xi.ja.BERSERK) - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_SC_AVAILABLE, 0, ai.r.JA, ai.s.SPECIFIC, xi.ja.WARCRY) - mob:addSimpleGambit(ai.t.SELF, ai.c.ALWAYS, 0, ai.r.JA, ai.s.SPECIFIC, xi.ja.RESTRAINT) + mob:addGambit(ai.t.SELF, { ai.c.NOT_SC_AVAILABLE, 0 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.BERSERK }) + mob:addGambit(ai.t.SELF, { ai.c.NOT_SC_AVAILABLE, 0 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.WARCRY }) + mob:addGambit(ai.t.SELF, { ai.c.ALWAYS, 0 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.RESTRAINT }) mob:setTrustTPSkillSettings(ai.tp.CLOSER_UNTIL_TP, ai.s.RANDOM, 1500) end diff --git a/scripts/actions/spells/trust/adelheid.lua b/scripts/actions/spells/trust/adelheid.lua index 7a21ab4c224..94286908126 100644 --- a/scripts/actions/spells/trust/adelheid.lua +++ b/scripts/actions/spells/trust/adelheid.lua @@ -20,26 +20,26 @@ end spellObject.onMobSpawn = function(mob) xi.trust.message(mob, xi.trust.messageOffset.SPAWN) - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_STATUS, xi.effect.ADDENDUM_BLACK, ai.r.JA, ai.s.SPECIFIC, xi.ja.DARK_ARTS) + mob:addGambit(ai.t.SELF, { ai.c.NOT_STATUS, xi.effect.ADDENDUM_BLACK }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.DARK_ARTS }) -- TODO: Restrict Addendum Black to Level 30+ - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_STATUS, xi.effect.ADDENDUM_BLACK, ai.r.JA, ai.s.SPECIFIC, xi.ja.ADDENDUM_BLACK) + mob:addGambit(ai.t.SELF, { ai.c.NOT_STATUS, xi.effect.ADDENDUM_BLACK }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.ADDENDUM_BLACK }) - mob:addSimpleGambit(ai.t.TARGET, ai.c.READYING_WS, 0, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STUN) - mob:addSimpleGambit(ai.t.TARGET, ai.c.READYING_MS, 0, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STUN) - mob:addSimpleGambit(ai.t.TARGET, ai.c.READYING_JA, 0, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STUN) - mob:addSimpleGambit(ai.t.TARGET, ai.c.CASTING_MA, 0, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STUN) + mob:addGambit(ai.t.TARGET, { ai.c.READYING_WS, 0 }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STUN }) + mob:addGambit(ai.t.TARGET, { ai.c.READYING_MS, 0 }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STUN }) + mob:addGambit(ai.t.TARGET, { ai.c.READYING_JA, 0 }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STUN }) + mob:addGambit(ai.t.TARGET, { ai.c.CASTING_MA, 0 }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STUN }) -- TODO: Choose Storms based on Mob Weakness before falling back to matching day - mob:addSimpleGambit(ai.t.SELF, ai.c.NO_STORM, 0, ai.r.MA, ai.s.STORM_DAY, 0, 0) + mob:addGambit(ai.t.SELF, { ai.c.NO_STORM, 0 }, { ai.r.MA, ai.s.STORM_DAY, 0 }, 0) -- TODO: Choose Helix based on Mob Weakness before falling back to matching day - mob:addSimpleGambit(ai.t.TARGET, ai.c.NOT_STATUS, xi.effect.HELIX, ai.r.MA, ai.s.HELIX_DAY, 0, 0) + mob:addGambit(ai.t.TARGET, { ai.c.NOT_STATUS, xi.effect.HELIX }, { ai.r.MA, ai.s.HELIX_DAY, 0 }, 0) - mob:addSimpleGambit(ai.t.TANK, ai.c.HPP_LT, 50, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE) - mob:addSimpleGambit(ai.t.PARTY, ai.c.HPP_LT, 33, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE) + mob:addGambit(ai.t.TANK, { ai.c.HPP_LT, 50 }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE }) + mob:addGambit(ai.t.PARTY, { ai.c.HPP_LT, 33 }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE }) -- TODO: Add Magic Burst Logic to Gambits to MB with Helix corresponding to SC - mob:addSimpleGambit(ai.t.TARGET, ai.c.NOT_SC_AVAILABLE, 0, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.NONE, 75) + mob:addGambit(ai.t.TARGET, { ai.c.NOT_SC_AVAILABLE, 0 }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.NONE }, 75) mob:addListener('WEAPONSKILL_USE', 'ADELHEID_WEAPONSKILL_USE', function(mobArg, target, wsid, tp, action) if wsid == 3469 then -- Twirling Dervish diff --git a/scripts/actions/spells/trust/ajido-marujido.lua b/scripts/actions/spells/trust/ajido-marujido.lua index ec4881ce451..44d95dc94d0 100644 --- a/scripts/actions/spells/trust/ajido-marujido.lua +++ b/scripts/actions/spells/trust/ajido-marujido.lua @@ -21,17 +21,13 @@ spellObject.onMobSpawn = function(mob) [xi.magic.spell.SEMIH_LAFIHNA] = xi.trust.messageOffset.TEAMWORK_5, }) - mob:addSimpleGambit(ai.t.TARGET, ai.c.MB_AVAILABLE, 0, - ai.r.MA, ai.s.MB_ELEMENT, xi.magic.spellFamily.NONE) + mob:addGambit(ai.t.TARGET, { ai.c.MB_AVAILABLE, 0 }, { ai.r.MA, ai.s.MB_ELEMENT, xi.magic.spellFamily.NONE }) - mob:addSimpleGambit(ai.t.PARTY, ai.c.HPP_LT, 25, - ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE) + mob:addGambit(ai.t.PARTY, { ai.c.HPP_LT, 25 }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE }) - mob:addSimpleGambit(ai.t.TARGET, ai.c.NOT_STATUS, xi.effect.SLOW, - ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.SLOW, 60) + mob:addGambit(ai.t.TARGET, { ai.c.NOT_STATUS, xi.effect.SLOW }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.SLOW }, 60) - mob:addSimpleGambit(ai.t.TARGET, ai.c.NOT_SC_AVAILABLE, 0, - ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.NONE, 60) + mob:addGambit(ai.t.TARGET, { ai.c.NOT_SC_AVAILABLE, 0 }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.NONE }, 60) mob:setMobMod(xi.mobMod.TRUST_DISTANCE, xi.trust.movementType.NO_MOVE) end diff --git a/scripts/actions/spells/trust/apururu_uc.lua b/scripts/actions/spells/trust/apururu_uc.lua index 55f70aa4a01..94e500aafb5 100644 --- a/scripts/actions/spells/trust/apururu_uc.lua +++ b/scripts/actions/spells/trust/apururu_uc.lua @@ -32,32 +32,32 @@ spellObject.onMobSpawn = function(mob) -- TODO: Custom spawn messages if Unity ranking is higher. -- TODO: Setup conditional behaviors for Devotion, Martyr - mob:addSimpleGambit(ai.t.SELF, ai.c.MPP_LT, 25, ai.r.JA, ai.s.SPECIFIC, xi.ja.CONVERT) + mob:addGambit(ai.t.SELF, { ai.c.MPP_LT, 25 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.CONVERT }) - mob:addSimpleGambit(ai.t.PARTY, ai.c.HPP_LT, 25, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE) + mob:addGambit(ai.t.PARTY, { ai.c.HPP_LT, 25 }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE }) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.SLEEP_I, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURAGA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.SLEEP_II, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURAGA) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.SLEEP_I }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURAGA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.SLEEP_II }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURAGA }) - mob:addSimpleGambit(ai.t.PARTY, ai.c.HPP_LT, 75, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE) + mob:addGambit(ai.t.PARTY, { ai.c.HPP_LT, 75 }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE }) - mob:addSimpleGambit(ai.t.PARTY, ai.c.NOT_STATUS, xi.effect.PROTECT, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.PROTECTRA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.NOT_STATUS, xi.effect.SHELL, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.SHELLRA) + mob:addGambit(ai.t.PARTY, { ai.c.NOT_STATUS, xi.effect.PROTECT }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.PROTECTRA }) + mob:addGambit(ai.t.PARTY, { ai.c.NOT_STATUS, xi.effect.SHELL }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.SHELLRA }) - mob:addSimpleGambit(ai.t.MELEE, ai.c.NOT_STATUS, xi.effect.HASTE, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.HASTE) + mob:addGambit(ai.t.MELEE, { ai.c.NOT_STATUS, xi.effect.HASTE }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.HASTE }) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.POISON, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.POISONA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.PARALYSIS, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.PARALYNA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.BLINDNESS, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.BLINDNA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.SILENCE, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.SILENA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.PETRIFICATION, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STONA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.DISEASE, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.VIRUNA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.CURSE_I, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURSNA) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.POISON }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.POISONA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.PARALYSIS }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.PARALYNA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.BLINDNESS }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.BLINDNA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.SILENCE }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.SILENA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.PETRIFICATION }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STONA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.DISEASE }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.VIRUNA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.CURSE_I }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURSNA }) - mob:addSimpleGambit(ai.t.SELF, ai.c.STATUS_FLAG, xi.effectFlag.ERASABLE, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.ERASE) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS_FLAG, xi.effectFlag.ERASABLE, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.ERASE) + mob:addGambit(ai.t.SELF, { ai.c.STATUS_FLAG, xi.effectFlag.ERASABLE }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.ERASE }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS_FLAG, xi.effectFlag.ERASABLE }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.ERASE }) - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_STATUS, xi.effect.STONESKIN, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STONESKIN) + mob:addGambit(ai.t.SELF, { ai.c.NOT_STATUS, xi.effect.STONESKIN }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STONESKIN }) -- BGwiki states 75/tick regain. Only used for Nott WS. mob:addMod(xi.mod.REGAIN, 75) diff --git a/scripts/actions/spells/trust/ayame.lua b/scripts/actions/spells/trust/ayame.lua index 0d1e36bb7ed..63b6e5b20db 100644 --- a/scripts/actions/spells/trust/ayame.lua +++ b/scripts/actions/spells/trust/ayame.lua @@ -18,14 +18,11 @@ spellObject.onMobSpawn = function(mob) [xi.magic.spell.GILGAMESH] = xi.trust.messageOffset.TEAMWORK_2, }) - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_STATUS, xi.effect.HASSO, - ai.r.JA, ai.s.SPECIFIC, xi.ja.HASSO) + mob:addGambit(ai.t.SELF, { ai.c.NOT_STATUS, xi.effect.HASSO }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.HASSO }) - mob:addSimpleGambit(ai.t.SELF, ai.c.HAS_TOP_ENMITY, 0, - ai.r.JA, ai.s.SPECIFIC, xi.ja.THIRD_EYE) + mob:addGambit(ai.t.SELF, { ai.c.HAS_TOP_ENMITY, 0 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.THIRD_EYE }) - mob:addSimpleGambit(ai.t.SELF, ai.c.TP_LT, 1000, - ai.r.JA, ai.s.SPECIFIC, xi.ja.MEDITATE) + mob:addGambit(ai.t.SELF, { ai.c.TP_LT, 1000 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.MEDITATE }) mob:setTrustTPSkillSettings(ai.tp.OPENER, ai.s.SPECIAL_AYAME) end diff --git a/scripts/actions/spells/trust/cherukiki.lua b/scripts/actions/spells/trust/cherukiki.lua index 741fb8f8e03..333942f9c1e 100644 --- a/scripts/actions/spells/trust/cherukiki.lua +++ b/scripts/actions/spells/trust/cherukiki.lua @@ -26,25 +26,25 @@ spellObject.onMobSpawn = function(mob) -- TODO: Meteor casting with siblings -- TODO: Any intelligence with casting Silence on mobs? - mob:addSimpleGambit(ai.t.MASTER, ai.c.NOT_STATUS, xi.effect.REGEN, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.REGEN) - mob:addSimpleGambit(ai.t.MELEE, ai.c.NOT_STATUS, xi.effect.REGEN, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.REGEN) + mob:addGambit(ai.t.MASTER, { ai.c.NOT_STATUS, xi.effect.REGEN }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.REGEN }) + mob:addGambit(ai.t.MELEE, { ai.c.NOT_STATUS, xi.effect.REGEN }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.REGEN }) - mob:addSimpleGambit(ai.t.PARTY, ai.c.HPP_LT, 25, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE) + mob:addGambit(ai.t.PARTY, { ai.c.HPP_LT, 25 }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE }) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.SLEEP_I, ai.r.MA, ai.s.SPECIFIC, xi.magic.spellFamily.CURE) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.SLEEP_II, ai.r.MA, ai.s.SPECIFIC, xi.magic.spellFamily.CURE) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.SLEEP_I }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spellFamily.CURE }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.SLEEP_II }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spellFamily.CURE }) - mob:addSimpleGambit(ai.t.PARTY, ai.c.HPP_LT, 75, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE) + mob:addGambit(ai.t.PARTY, { ai.c.HPP_LT, 75 }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE }) - mob:addSimpleGambit(ai.t.PARTY, ai.c.NOT_STATUS, xi.effect.PROTECT, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.PROTECTRA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.NOT_STATUS, xi.effect.SHELL, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.SHELLRA) + mob:addGambit(ai.t.PARTY, { ai.c.NOT_STATUS, xi.effect.PROTECT }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.PROTECTRA }) + mob:addGambit(ai.t.PARTY, { ai.c.NOT_STATUS, xi.effect.SHELL }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.SHELLRA }) - mob:addSimpleGambit(ai.t.MASTER, ai.c.NOT_STATUS, xi.effect.HASTE, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.HASTE) - mob:addSimpleGambit(ai.t.MELEE, ai.c.NOT_STATUS, xi.effect.HASTE, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.HASTE) + mob:addGambit(ai.t.MASTER, { ai.c.NOT_STATUS, xi.effect.HASTE }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.HASTE }) + mob:addGambit(ai.t.MELEE, { ai.c.NOT_STATUS, xi.effect.HASTE }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.HASTE }) - mob:addSimpleGambit(ai.t.TARGET, ai.c.NOT_STATUS, xi.effect.PARALYSIS, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.PARALYZE, 60) - mob:addSimpleGambit(ai.t.TARGET, ai.c.NOT_STATUS, xi.effect.SLOW, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.SLOW, 60) - mob:addSimpleGambit(ai.t.TARGET, ai.c.NOT_STATUS, xi.effect.SILENCE, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.SILENCE, 60) + mob:addGambit(ai.t.TARGET, { ai.c.NOT_STATUS, xi.effect.PARALYSIS }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.PARALYZE }, 60) + mob:addGambit(ai.t.TARGET, { ai.c.NOT_STATUS, xi.effect.SLOW }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.SLOW }, 60) + mob:addGambit(ai.t.TARGET, { ai.c.NOT_STATUS, xi.effect.SILENCE }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.SILENCE }, 60) -- BGwiki states 5/tick regen. mob:addMod(xi.mod.REGEN, 5) diff --git a/scripts/actions/spells/trust/curilla.lua b/scripts/actions/spells/trust/curilla.lua index 257a55161b8..d93df5d5ab6 100644 --- a/scripts/actions/spells/trust/curilla.lua +++ b/scripts/actions/spells/trust/curilla.lua @@ -20,14 +20,11 @@ spellObject.onMobSpawn = function(mob) [xi.magic.spell.HALVER] = xi.trust.messageOffset.TEAMWORK_4, }) - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_STATUS, xi.effect.SENTINEL, - ai.r.JA, ai.s.SPECIFIC, xi.ja.SENTINEL) + mob:addGambit(ai.t.SELF, { ai.c.NOT_STATUS, xi.effect.SENTINEL }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.SENTINEL }) - mob:addSimpleGambit(ai.t.TARGET, ai.c.NOT_STATUS, xi.effect.FLASH, - ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.FLASH) + mob:addGambit(ai.t.TARGET, { ai.c.NOT_STATUS, xi.effect.FLASH }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.FLASH }) - mob:addSimpleGambit(ai.t.PARTY, ai.c.HPP_LT, 75, - ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE) + mob:addGambit(ai.t.PARTY, { ai.c.HPP_LT, 75 }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE }) end spellObject.onMobDespawn = function(mob) diff --git a/scripts/actions/spells/trust/excenmille.lua b/scripts/actions/spells/trust/excenmille.lua index 33d342779e1..9af116c2f5e 100644 --- a/scripts/actions/spells/trust/excenmille.lua +++ b/scripts/actions/spells/trust/excenmille.lua @@ -27,14 +27,11 @@ spellObject.onMobSpawn = function(mob) [xi.magic.spell.RAHAL] = xi.trust.messageOffset.TEAMWORK_1, }) - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_STATUS, xi.effect.SENTINEL, - ai.r.JA, ai.s.SPECIFIC, xi.ja.SENTINEL) + mob:addGambit(ai.t.SELF, { ai.c.NOT_STATUS, xi.effect.SENTINEL }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.SENTINEL }) - mob:addSimpleGambit(ai.t.TARGET, ai.c.NOT_STATUS, xi.effect.FLASH, - ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.FLASH) + mob:addGambit(ai.t.TARGET, { ai.c.NOT_STATUS, xi.effect.FLASH }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.FLASH }) - mob:addSimpleGambit(ai.t.PARTY, ai.c.HPP_LT, 75, - ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE) + mob:addGambit(ai.t.PARTY, { ai.c.HPP_LT, 75 }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE }) mob:addMod(xi.mod.STORETP, 25) end diff --git a/scripts/actions/spells/trust/fablinix.lua b/scripts/actions/spells/trust/fablinix.lua index 969c8797299..43e87b23c97 100644 --- a/scripts/actions/spells/trust/fablinix.lua +++ b/scripts/actions/spells/trust/fablinix.lua @@ -17,19 +17,19 @@ spellObject.onMobSpawn = function(mob) [xi.magic.spell.MOOGLE] = xi.trust.messageOffset.TEAMWORK_1, }) - mob:addSimpleGambit(ai.t.TARGET, ai.c.READYING_WS, 0, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STUN) - mob:addSimpleGambit(ai.t.TARGET, ai.c.READYING_MS, 0, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STUN) - mob:addSimpleGambit(ai.t.TARGET, ai.c.READYING_JA, 0, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STUN) - mob:addSimpleGambit(ai.t.TARGET, ai.c.CASTING_MA, 0, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STUN) + mob:addGambit(ai.t.TARGET, { ai.c.READYING_WS, 0 }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STUN }) + mob:addGambit(ai.t.TARGET, { ai.c.READYING_MS, 0 }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STUN }) + mob:addGambit(ai.t.TARGET, { ai.c.READYING_JA, 0 }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STUN }) + mob:addGambit(ai.t.TARGET, { ai.c.CASTING_MA, 0 }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STUN }) - mob:addSimpleGambit(ai.t.TANK, ai.c.HPP_LT, 75, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE) - mob:addSimpleGambit(ai.t.PARTY, ai.c.HPP_LT, 50, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.SLEEP_I, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURE) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.SLEEP_II, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURE) + mob:addGambit(ai.t.TANK, { ai.c.HPP_LT, 75 }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE }) + mob:addGambit(ai.t.PARTY, { ai.c.HPP_LT, 50 }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.SLEEP_I }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURE }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.SLEEP_II }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURE }) - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_STATUS, xi.effect.ENWATER, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.ENWATER) + mob:addGambit(ai.t.SELF, { ai.c.NOT_STATUS, xi.effect.ENWATER }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.ENWATER }) - mob:addSimpleGambit(ai.t.TARGET, ai.c.RANDOM, 50, ai.r.RATTACK, 0, 0, 30) -- TODO: Verify rate of ranged attacks + mob:addGambit(ai.t.TARGET, { ai.c.RANDOM, 50 }, { ai.r.RATTACK, 0, 0 }, 30) -- TODO: Verify rate of ranged attacks mob:setTrustTPSkillSettings(ai.tp.CLOSER_UNTIL_TP, ai.s.HIGHEST, 1500) end diff --git a/scripts/actions/spells/trust/ferreous_coffin.lua b/scripts/actions/spells/trust/ferreous_coffin.lua index 70cb05f5133..f700510b78a 100644 --- a/scripts/actions/spells/trust/ferreous_coffin.lua +++ b/scripts/actions/spells/trust/ferreous_coffin.lua @@ -26,26 +26,26 @@ spellObject.onMobSpawn = function(mob) mob:addMod(xi.mod.REFRESH, 2) mob:addMod(xi.mod.ENHANCES_CURSNA, 20) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.SLOW, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.ERASE) - mob:addSimpleGambit(ai.t.PARTY, ai.c.NOT_STATUS, xi.effect.HASTE, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.HASTE) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.SLOW }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.ERASE }) + mob:addGambit(ai.t.PARTY, { ai.c.NOT_STATUS, xi.effect.HASTE }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.HASTE }) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.SLEEP_I, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURE) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.SLEEP_II, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURE) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.SLEEP_I }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURE }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.SLEEP_II }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURE }) - mob:addSimpleGambit(ai.t.PARTY, ai.c.HPP_LT, 75, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE) + mob:addGambit(ai.t.PARTY, { ai.c.HPP_LT, 75 }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE }) - mob:addSimpleGambit(ai.t.TOP_ENMITY, ai.c.STATUS, xi.effect.PARALYSIS, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.PARALYNA) - mob:addSimpleGambit(ai.t.TOP_ENMITY, ai.c.STATUS, xi.effect.BLINDNESS, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.BLINDNA) - mob:addSimpleGambit(ai.t.TOP_ENMITY, ai.c.STATUS, xi.effect.SILENCE, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.SILENA) - mob:addSimpleGambit(ai.t.TOP_ENMITY, ai.c.STATUS, xi.effect.PETRIFICATION, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STONA) - mob:addSimpleGambit(ai.t.TOP_ENMITY, ai.c.STATUS, xi.effect.DISEASE, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.VIRUNA) + mob:addGambit(ai.t.TOP_ENMITY, { ai.c.STATUS, xi.effect.PARALYSIS }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.PARALYNA }) + mob:addGambit(ai.t.TOP_ENMITY, { ai.c.STATUS, xi.effect.BLINDNESS }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.BLINDNA }) + mob:addGambit(ai.t.TOP_ENMITY, { ai.c.STATUS, xi.effect.SILENCE }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.SILENA }) + mob:addGambit(ai.t.TOP_ENMITY, { ai.c.STATUS, xi.effect.PETRIFICATION }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STONA }) + mob:addGambit(ai.t.TOP_ENMITY, { ai.c.STATUS, xi.effect.DISEASE }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.VIRUNA }) - mob:addSimpleGambit(ai.t.TOP_ENMITY, ai.c.STATUS, xi.effect.CURSE_I, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURSNA) - mob:addSimpleGambit(ai.t.TOP_ENMITY, ai.c.STATUS, xi.effect.CURSE_II, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURSNA) - mob:addSimpleGambit(ai.t.TOP_ENMITY, ai.c.STATUS, xi.effect.BANE, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURSNA) - mob:addSimpleGambit(ai.t.TOP_ENMITY, ai.c.STATUS, xi.effect.DOOM, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURSNA) + mob:addGambit(ai.t.TOP_ENMITY, { ai.c.STATUS, xi.effect.CURSE_I }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURSNA }) + mob:addGambit(ai.t.TOP_ENMITY, { ai.c.STATUS, xi.effect.CURSE_II }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURSNA }) + mob:addGambit(ai.t.TOP_ENMITY, { ai.c.STATUS, xi.effect.BANE }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURSNA }) + mob:addGambit(ai.t.TOP_ENMITY, { ai.c.STATUS, xi.effect.DOOM }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURSNA }) - mob:addSimpleGambit(ai.t.PARTY_DEAD, ai.c.ALWAYS, 0, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.RAISE) + mob:addGambit(ai.t.PARTY_DEAD, { ai.c.ALWAYS, 0 }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.RAISE }) mob:addListener('WEAPONSKILL_USE', 'FERREOUS_COFFIN_WEAPONSKILL_USE', function(mobArg, target, wsid, tp, action) if wsid == 170 then -- Randgrith diff --git a/scripts/actions/spells/trust/gessho.lua b/scripts/actions/spells/trust/gessho.lua index e94dd4e1a73..539e2e03557 100644 --- a/scripts/actions/spells/trust/gessho.lua +++ b/scripts/actions/spells/trust/gessho.lua @@ -26,16 +26,14 @@ spellObject.onMobSpawn = function(mob) end) -- Shadows are represented by xi.effect.COPY_IMAGE, but with different icons depending on the tier - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_STATUS, xi.effect.COPY_IMAGE, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.UTSUSEMI) + mob:addGambit(ai.t.SELF, { ai.c.NOT_STATUS, xi.effect.COPY_IMAGE }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.UTSUSEMI }) - mob:addSimpleGambit(ai.t.TARGET, ai.c.NOT_STATUS, xi.effect.BLINDNESS, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.KURAYAMI, 60) - mob:addSimpleGambit(ai.t.TARGET, ai.c.NOT_STATUS, xi.effect.SLOW, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.HOJO, 60) + mob:addGambit(ai.t.TARGET, { ai.c.NOT_STATUS, xi.effect.BLINDNESS }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.KURAYAMI }, 60) + mob:addGambit(ai.t.TARGET, { ai.c.NOT_STATUS, xi.effect.SLOW }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.HOJO }, 60) - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_STATUS, xi.effect.YONIN, - ai.r.JA, ai.s.SPECIFIC, xi.ja.YONIN) + mob:addGambit(ai.t.SELF, { ai.c.NOT_STATUS, xi.effect.YONIN }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.YONIN }) - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_HAS_TOP_ENMITY, 0, - ai.r.JA, ai.s.SPECIFIC, xi.ja.PROVOKE) + mob:addGambit(ai.t.SELF, { ai.c.NOT_HAS_TOP_ENMITY, 0 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.PROVOKE }) mob:setTrustTPSkillSettings(ai.tp.ASAP, ai.s.RANDOM) end diff --git a/scripts/actions/spells/trust/iron_eater.lua b/scripts/actions/spells/trust/iron_eater.lua index e27fb2faad5..8d88689427e 100644 --- a/scripts/actions/spells/trust/iron_eater.lua +++ b/scripts/actions/spells/trust/iron_eater.lua @@ -17,8 +17,7 @@ spellObject.onMobSpawn = function(mob) [xi.magic.spell.NAJI] = xi.trust.messageOffset.TEAMWORK_1, }) - mob:addSimpleGambit(ai.t.MASTER, ai.c.HPP_LT, 50, - ai.r.JA, ai.s.SPECIFIC, xi.ja.PROVOKE) + mob:addGambit(ai.t.MASTER, { ai.c.HPP_LT, 50 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.PROVOKE }) end spellObject.onMobDespawn = function(mob) diff --git a/scripts/actions/spells/trust/joachim.lua b/scripts/actions/spells/trust/joachim.lua index 62e1075db9f..c8284e89442 100644 --- a/scripts/actions/spells/trust/joachim.lua +++ b/scripts/actions/spells/trust/joachim.lua @@ -20,22 +20,22 @@ end spellObject.onMobSpawn = function(mob) xi.trust.message(mob, xi.trust.messageOffset.SPAWN) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.POISON, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.POISONA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.PARALYSIS, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.PARALYNA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.BLINDNESS, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.BLINDNA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.SILENCE, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.SILENA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.PETRIFICATION, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STONA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.DISEASE, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.VIRUNA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.CURSE_I, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURSNA) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.POISON }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.POISONA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.PARALYSIS }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.PARALYNA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.BLINDNESS }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.BLINDNA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.SILENCE }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.SILENA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.PETRIFICATION }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STONA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.DISEASE }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.VIRUNA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.CURSE_I }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURSNA }) -- TODO: BRD trusts need better logic and major overhaul, for now they compliment each other - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_STATUS, xi.effect.MARCH, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.MARCH) - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_STATUS, xi.effect.BALLAD, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.MAGES_BALLAD) + mob:addGambit(ai.t.SELF, { ai.c.NOT_STATUS, xi.effect.MARCH }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.MARCH }) + mob:addGambit(ai.t.SELF, { ai.c.NOT_STATUS, xi.effect.BALLAD }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.MAGES_BALLAD }) - mob:addSimpleGambit(ai.t.PARTY, ai.c.HPP_LT, 75, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE) + mob:addGambit(ai.t.PARTY, { ai.c.HPP_LT, 75 }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE }) -- Try and ranged attack every 60s - mob:addSimpleGambit(ai.t.TARGET, ai.c.ALWAYS, 0, ai.r.RATTACK, 0, 0, 60) + mob:addGambit(ai.t.TARGET, { ai.c.ALWAYS, 0 }, { ai.r.RATTACK, 0, 0 }, 60) mob:setAutoAttackEnabled(false) diff --git a/scripts/actions/spells/trust/koru-moru.lua b/scripts/actions/spells/trust/koru-moru.lua index 1767ca92209..7356f859ed4 100644 --- a/scripts/actions/spells/trust/koru-moru.lua +++ b/scripts/actions/spells/trust/koru-moru.lua @@ -24,12 +24,15 @@ spellObject.onMobSpawn = function(mob) mob:addGambit(ai.t.PARTY, { ai.c.HPP_LT, 50 }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE }) mob:addGambit(ai.t.MELEE, { ai.c.NOT_STATUS, xi.effect.HASTE }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.HASTE }) + mob:addGambit(ai.t.CASTER, { { ai.c.NOT_STATUS, xi.effect.REFRESH }, { ai.c.NOT_STATUS, xi.effect.SUBLIMATION_ACTIVATED }, { ai.c.NOT_STATUS, xi.effect.SUBLIMATION_COMPLETE }, }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.REFRESH }) + mob:addGambit(ai.t.TANK, { ai.c.NOT_STATUS, xi.effect.REFRESH }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.REFRESH }) + mob:addGambit(ai.t.RANGED, { { ai.c.NOT_STATUS, xi.effect.FLURRY_II }, -- xi.effect.FLURRY_II is not a typo { ai.c.NOT_STATUS, xi.effect.HASTE }, -- No overwriting Haste diff --git a/scripts/actions/spells/trust/kupipi.lua b/scripts/actions/spells/trust/kupipi.lua index 7c010a7b566..a746caa5a7a 100644 --- a/scripts/actions/spells/trust/kupipi.lua +++ b/scripts/actions/spells/trust/kupipi.lua @@ -28,31 +28,31 @@ spellObject.onMobSpawn = function(mob) [xi.magic.spell.STAR_SIBYL] = xi.trust.messageOffset.TEAMWORK_2, }) - mob:addSimpleGambit(ai.t.PARTY, ai.c.HPP_LT, 25, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE) + mob:addGambit(ai.t.PARTY, { ai.c.HPP_LT, 25 }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE }) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.SLEEP_I, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURE) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.SLEEP_II, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURE) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.SLEEP_I }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURE }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.SLEEP_II }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURE }) - mob:addSimpleGambit(ai.t.PARTY, ai.c.HPP_LT, 75, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE) + mob:addGambit(ai.t.PARTY, { ai.c.HPP_LT, 75 }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE }) - mob:addSimpleGambit(ai.t.PARTY, ai.c.NOT_STATUS, xi.effect.PROTECT, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.PROTECTRA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.NOT_STATUS, xi.effect.SHELL, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.SHELLRA) + mob:addGambit(ai.t.PARTY, { ai.c.NOT_STATUS, xi.effect.PROTECT }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.PROTECTRA }) + mob:addGambit(ai.t.PARTY, { ai.c.NOT_STATUS, xi.effect.SHELL }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.SHELLRA }) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.POISON, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.POISONA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.PARALYSIS, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.PARALYNA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.BLINDNESS, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.BLINDNA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.SILENCE, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.SILENA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.PETRIFICATION, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STONA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.DISEASE, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.VIRUNA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.CURSE_I, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURSNA) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.POISON }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.POISONA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.PARALYSIS }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.PARALYNA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.BLINDNESS }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.BLINDNA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.SILENCE }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.SILENA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.PETRIFICATION }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STONA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.DISEASE }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.VIRUNA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.CURSE_I }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURSNA }) - mob:addSimpleGambit(ai.t.SELF, ai.c.STATUS_FLAG, xi.effectFlag.ERASABLE, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.ERASE) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS_FLAG, xi.effectFlag.ERASABLE, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.ERASE) + mob:addGambit(ai.t.SELF, { ai.c.STATUS_FLAG, xi.effectFlag.ERASABLE }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.ERASE }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS_FLAG, xi.effectFlag.ERASABLE }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.ERASE }) - mob:addSimpleGambit(ai.t.TARGET, ai.c.NOT_STATUS, xi.effect.PARALYSIS, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.PARALYZE, 60) - mob:addSimpleGambit(ai.t.TARGET, ai.c.NOT_STATUS, xi.effect.SLOW, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.SLOW, 60) + mob:addGambit(ai.t.TARGET, { ai.c.NOT_STATUS, xi.effect.PARALYSIS }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.PARALYZE }, 60) + mob:addGambit(ai.t.TARGET, { ai.c.NOT_STATUS, xi.effect.SLOW }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.SLOW }, 60) - mob:addSimpleGambit(ai.t.TARGET, ai.c.NOT_STATUS, xi.effect.FLASH, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.FLASH, 60) + mob:addGambit(ai.t.TARGET, { ai.c.NOT_STATUS, xi.effect.FLASH }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.FLASH }, 60) mob:setMobMod(xi.mobMod.TRUST_DISTANCE, xi.trust.movementType.NO_MOVE) end diff --git a/scripts/actions/spells/trust/lehko_habhoka.lua b/scripts/actions/spells/trust/lehko_habhoka.lua index f1e32a3cd07..494ae66ae98 100644 --- a/scripts/actions/spells/trust/lehko_habhoka.lua +++ b/scripts/actions/spells/trust/lehko_habhoka.lua @@ -18,13 +18,13 @@ spellObject.onMobSpawn = function(mob) [xi.magic.spell.ROBEL_AKBEL] = xi.trust.messageOffset.TEAMWORK_2, }) - mob:addSimpleGambit(ai.t.TARGET, ai.c.MB_AVAILABLE, 0, ai.r.MA, ai.s.MB_ELEMENT, xi.magic.spellFamily.NONE) + mob:addGambit(ai.t.TARGET, { ai.c.MB_AVAILABLE, 0 }, { ai.r.MA, ai.s.MB_ELEMENT, xi.magic.spellFamily.NONE }) - mob:addSimpleGambit(ai.t.TARGET, ai.c.NOT_SC_AVAILABLE, 0, ai.r.MA, ai.s.BEST_AGAINST_TARGET, 0, 60) + mob:addGambit(ai.t.TARGET, { ai.c.NOT_SC_AVAILABLE, 0 }, { ai.r.MA, ai.s.BEST_AGAINST_TARGET, 0 }, 60) ---- Uses Ranged Attacks very frequently. Always runs to stay in melee range. [Verification Needed] ---- Try and ranged attack every 10s - mob:addSimpleGambit(ai.t.TARGET, ai.c.ALWAYS, 0, ai.r.RATTACK, 0, 0, 10) + mob:addGambit(ai.t.TARGET, { ai.c.ALWAYS, 0 }, { ai.r.RATTACK, 0, 0 }, 10) mob:setTrustTPSkillSettings(ai.tp.ASAP, ai.s.RANDOM) diff --git a/scripts/actions/spells/trust/lion.lua b/scripts/actions/spells/trust/lion.lua index 32366c85476..a70d745bd6a 100644 --- a/scripts/actions/spells/trust/lion.lua +++ b/scripts/actions/spells/trust/lion.lua @@ -25,10 +25,10 @@ spellObject.onMobSpawn = function(mob) }) -- Stun all the things! - mob:addSimpleGambit(ai.t.TARGET, ai.c.READYING_WS, 0, ai.r.WS, ai.s.SPECIFIC, kGrapeshot) - mob:addSimpleGambit(ai.t.TARGET, ai.c.READYING_MS, 0, ai.r.WS, ai.s.SPECIFIC, kGrapeshot) - mob:addSimpleGambit(ai.t.TARGET, ai.c.READYING_JA, 0, ai.r.WS, ai.s.SPECIFIC, kGrapeshot) - mob:addSimpleGambit(ai.t.TARGET, ai.c.CASTING_MA, 0, ai.r.WS, ai.s.SPECIFIC, kGrapeshot) + mob:addGambit(ai.t.TARGET, { ai.c.READYING_WS, 0 }, { ai.r.WS, ai.s.SPECIFIC, kGrapeshot }) + mob:addGambit(ai.t.TARGET, { ai.c.READYING_MS, 0 }, { ai.r.WS, ai.s.SPECIFIC, kGrapeshot }) + mob:addGambit(ai.t.TARGET, { ai.c.READYING_JA, 0 }, { ai.r.WS, ai.s.SPECIFIC, kGrapeshot }) + mob:addGambit(ai.t.TARGET, { ai.c.CASTING_MA, 0 }, { ai.r.WS, ai.s.SPECIFIC, kGrapeshot }) mob:setTrustTPSkillSettings(ai.tp.ASAP, ai.s.RANDOM) end diff --git a/scripts/actions/spells/trust/lion_ii.lua b/scripts/actions/spells/trust/lion_ii.lua index d35b15b9c27..ac46566a64e 100644 --- a/scripts/actions/spells/trust/lion_ii.lua +++ b/scripts/actions/spells/trust/lion_ii.lua @@ -27,7 +27,7 @@ spellObject.onMobSpawn = function(mob) end end) - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_STATUS, xi.effect.COPY_IMAGE, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.UTSUSEMI) + mob:addGambit(ai.t.SELF, { ai.c.NOT_STATUS, xi.effect.COPY_IMAGE }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.UTSUSEMI }) mob:setTrustTPSkillSettings(ai.tp.CLOSER_UNTIL_TP, ai.s.RANDOM, 3000) end diff --git a/scripts/actions/spells/trust/maat.lua b/scripts/actions/spells/trust/maat.lua index d5218827263..9bddcee410f 100644 --- a/scripts/actions/spells/trust/maat.lua +++ b/scripts/actions/spells/trust/maat.lua @@ -16,8 +16,7 @@ spellObject.onMobSpawn = function(mob) xi.trust.message(mob, xi.trust.messageOffset.SPAWN) -- On cooldown - mob:addSimpleGambit(ai.t.SELF, ai.c.ALWAYS, 0, - ai.r.JA, ai.s.SPECIFIC, xi.ja.MANTRA) + mob:addGambit(ai.t.SELF, { ai.c.ALWAYS, 0 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.MANTRA }) mob:addListener('WEAPONSKILL_USE', 'MAAT_WEAPONSKILL_USE', function(mobArg, target, wsid, tp, action) if wsid == 3263 then -- Bear Killer diff --git a/scripts/actions/spells/trust/maat_uc.lua b/scripts/actions/spells/trust/maat_uc.lua index c8ff0ec8455..2247a5bceee 100644 --- a/scripts/actions/spells/trust/maat_uc.lua +++ b/scripts/actions/spells/trust/maat_uc.lua @@ -15,9 +15,9 @@ end spellObject.onMobSpawn = function(mob) xi.trust.message(mob, xi.trust.messageOffset.SPAWN) -- TODO test and incorporate (possesses increased kick attacks rate) - mob:addSimpleGambit(ai.t.SELF, ai.c.HPP_LT, 50, ai.r.JA, ai.s.SPECIFIC, xi.ja.CHAKRA) - mob:addSimpleGambit(ai.t.SELF, ai.c.HAS_TOP_ENMITY, 0, ai.r.JA, ai.s.SPECIFIC, xi.ja.COUNTERSTANCE) - mob:addSimpleGambit(ai.t.SELF, ai.c.ALWAYS, 0, ai.r.JA, ai.s.SPECIFIC, xi.ja.IMPETUS) + mob:addGambit(ai.t.SELF, { ai.c.HPP_LT, 50 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.CHAKRA }) + mob:addGambit(ai.t.SELF, { ai.c.HAS_TOP_ENMITY, 0 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.COUNTERSTANCE }) + mob:addGambit(ai.t.SELF, { ai.c.ALWAYS, 0 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.IMPETUS }) if mob:getMaster():getMainLvl() >= 50 then -- TODO no current implementation to have multiple criterias on setTrustTOSkillSetting to allow opening a skill chain and closing a skill chain diff --git a/scripts/actions/spells/trust/mihli_aliapoh.lua b/scripts/actions/spells/trust/mihli_aliapoh.lua index 614dc1d0725..e72de60465f 100644 --- a/scripts/actions/spells/trust/mihli_aliapoh.lua +++ b/scripts/actions/spells/trust/mihli_aliapoh.lua @@ -25,32 +25,31 @@ spellObject.onMobSpawn = function(mob) [xi.magic.spell.ZAZARG] = xi.trust.messageOffset.TEAMWORK_4, }) - mob:addSimpleGambit(ai.t.PARTY, ai.c.HPP_LT, 25, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE) + mob:addGambit(ai.t.PARTY, { ai.c.HPP_LT, 25 }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE }) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.SLEEP_I, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURE) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.SLEEP_II, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURE) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.SLEEP_I }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURE }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.SLEEP_II }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURE }) - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_STATUS, xi.effect.AFFLATUS_SOLACE, - ai.r.JA, ai.s.SPECIFIC, xi.ja.AFFLATUS_SOLACE) + mob:addGambit(ai.t.SELF, { ai.c.NOT_STATUS, xi.effect.AFFLATUS_SOLACE }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.AFFLATUS_SOLACE }) - mob:addSimpleGambit(ai.t.PARTY, ai.c.HPP_LT, 75, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE) + mob:addGambit(ai.t.PARTY, { ai.c.HPP_LT, 75 }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE }) - mob:addSimpleGambit(ai.t.PARTY, ai.c.NOT_STATUS, xi.effect.PROTECT, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.PROTECTRA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.NOT_STATUS, xi.effect.SHELL, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.SHELLRA) + mob:addGambit(ai.t.PARTY, { ai.c.NOT_STATUS, xi.effect.PROTECT }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.PROTECTRA }) + mob:addGambit(ai.t.PARTY, { ai.c.NOT_STATUS, xi.effect.SHELL }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.SHELLRA }) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.POISON, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.POISONA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.PARALYSIS, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.PARALYNA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.BLINDNESS, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.BLINDNA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.SILENCE, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.SILENA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.PETRIFICATION, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STONA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.DISEASE, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.VIRUNA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.CURSE_I, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURSNA) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.POISON }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.POISONA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.PARALYSIS }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.PARALYNA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.BLINDNESS }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.BLINDNA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.SILENCE }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.SILENA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.PETRIFICATION }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STONA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.DISEASE }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.VIRUNA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.CURSE_I }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURSNA }) - mob:addSimpleGambit(ai.t.SELF, ai.c.STATUS_FLAG, xi.effectFlag.ERASABLE, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.ERASE) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS_FLAG, xi.effectFlag.ERASABLE, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.ERASE) + mob:addGambit(ai.t.SELF, { ai.c.STATUS_FLAG, xi.effectFlag.ERASABLE }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.ERASE }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS_FLAG, xi.effectFlag.ERASABLE }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.ERASE }) - mob:addSimpleGambit(ai.t.TARGET, ai.c.NOT_STATUS, xi.effect.PARALYSIS, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.PARALYZE, 60) - mob:addSimpleGambit(ai.t.TARGET, ai.c.NOT_STATUS, xi.effect.SLOW, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.SLOW, 60) + mob:addGambit(ai.t.TARGET, { ai.c.NOT_STATUS, xi.effect.PARALYSIS }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.PARALYZE }, 60) + mob:addGambit(ai.t.TARGET, { ai.c.NOT_STATUS, xi.effect.SLOW }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.SLOW }, 60) mob:addListener('WEAPONSKILL_USE', 'MIHLI_ALIAPOH_WEAPONSKILL_USE', function(mobArg, target, wsid, tp, action) if wsid == 3203 then -- Scouring Bubbles diff --git a/scripts/actions/spells/trust/monberaux.lua b/scripts/actions/spells/trust/monberaux.lua index bb2e7c5230a..2c9ef4407e0 100644 --- a/scripts/actions/spells/trust/monberaux.lua +++ b/scripts/actions/spells/trust/monberaux.lua @@ -29,20 +29,20 @@ spellObject.onMobSpawn = function(mob) -- Tends to be particular about which potions to use. Seems to favor healing for just the -- right amount of HP instead of defaulting to the highest-rank potion. mob:addMod(xi.mod.MPP, -90) - mob:addSimpleGambit(ai.t.CASTER, ai.c.MPP_LT, 25, ai.r.MS, ai.s.SPECIFIC, 4254, healingMoveCooldown) -- Mix: Dry Ether Concoction - mob:addSimpleGambit(ai.t.PARTY, ai.c.HPP_LT, 90, ai.r.MS, ai.s.SPECIFIC, 4236, healingMoveCooldown) -- Max Potion (500 HP) - mob:addSimpleGambit(ai.t.PARTY, ai.c.HPP_LT, 75, ai.r.MS, ai.s.SPECIFIC, 4237, healingMoveCooldown) -- Mix: Max Potion (700 HP) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.POISON, ai.r.MS, ai.s.SPECIFIC, 4238, healingMoveCooldown) -- Mix: Antidote - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.SILENCE, ai.r.MS, ai.s.SPECIFIC, 4241, healingMoveCooldown) -- Echo Drops - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.PARALYSIS, ai.r.MS, ai.s.SPECIFIC, 4247, healingMoveCooldown) -- Mix: Para-B-Gone - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS_FLAG, xi.effectFlag.ERASABLE, ai.r.MS, ai.s.SPECIFIC, 4245, healingMoveCooldown) -- Mix: Panacea-1 - mob:addSimpleGambit(ai.t.PARTY, ai.c.NOT_STATUS, xi.effect.REGEN, ai.r.MS, ai.s.SPECIFIC, 4257, healingMoveCooldown) -- Mix: Life Water - mob:addSimpleGambit(ai.t.PARTY, ai.c.NOT_STATUS, xi.effect.STR_BOOST, ai.r.MS, ai.s.SPECIFIC, 4261, healingMoveCooldown) -- Mix: Samson's Strength - mob:addSimpleGambit(ai.t.PARTY, ai.c.NOT_STATUS, xi.effect.MAGIC_DEF_BOOST, ai.r.MS, ai.s.SPECIFIC, 4259, healingMoveCooldown) -- Mix: Dragon Shield - mob:addSimpleGambit(ai.t.PARTY, ai.c.NOT_STATUS, xi.effect.MAGIC_ATK_BOOST, ai.r.MS, ai.s.SPECIFIC, 4258, healingMoveCooldown) -- Mix: Elemental Power - mob:addSimpleGambit(ai.t.PARTY, ai.c.NOT_STATUS, xi.effect.PROTECT, ai.r.MS, ai.s.SPECIFIC, 4255, healingMoveCooldown) -- Mix: Guard Drink - -- mob:addSimpleGambit(ai.t.PARTY, ai.c.NOT_STATUS, xi.effect.NEGATE_SLEEP, ai.r.MS, ai.s.SPECIFIC, 4256, healingMoveCooldown) -- Insomniant. Disabled because animation when used is completely wrong. - mob:addSimpleGambit(ai.t.TARGET, ai.c.HP_MISSING, 99, ai.r.MS, ai.s.SPECIFIC, 4260, healingMoveCooldown) -- Dark Potion (666 Dark Damage) + mob:addGambit(ai.t.CASTER, { ai.c.MPP_LT, 25 }, { ai.r.MS, ai.s.SPECIFIC, 4254 }, healingMoveCooldown) -- Mix: Dry Ether Concoction + mob:addGambit(ai.t.PARTY, { ai.c.HPP_LT, 90 }, { ai.r.MS, ai.s.SPECIFIC, 4236 }, healingMoveCooldown) -- Max Potion (500 HP) + mob:addGambit(ai.t.PARTY, { ai.c.HPP_LT, 75 }, { ai.r.MS, ai.s.SPECIFIC, 4237 }, healingMoveCooldown) -- Mix: Max Potion (700 HP) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.POISON }, { ai.r.MS, ai.s.SPECIFIC, 4238 }, healingMoveCooldown) -- Mix: Antidote + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.SILENCE }, { ai.r.MS, ai.s.SPECIFIC, 4241 }, healingMoveCooldown) -- Echo Drops + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.PARALYSIS }, { ai.r.MS, ai.s.SPECIFIC, 4247 }, healingMoveCooldown) -- Mix: Para-B-Gone + mob:addGambit(ai.t.PARTY, { ai.c.STATUS_FLAG, xi.effectFlag.ERASABLE }, { ai.r.MS, ai.s.SPECIFIC, 4245 }, healingMoveCooldown) -- Mix: Panacea-1 + mob:addGambit(ai.t.PARTY, { ai.c.NOT_STATUS, xi.effect.REGEN }, { ai.r.MS, ai.s.SPECIFIC, 4257 }, healingMoveCooldown) -- Mix: Life Water + mob:addGambit(ai.t.PARTY, { ai.c.NOT_STATUS, xi.effect.STR_BOOST }, { ai.r.MS, ai.s.SPECIFIC, 4261 }, healingMoveCooldown) -- Mix: Samson's Strength + mob:addGambit(ai.t.PARTY, { ai.c.NOT_STATUS, xi.effect.MAGIC_DEF_BOOST }, { ai.r.MS, ai.s.SPECIFIC, 4259 }, healingMoveCooldown) -- Mix: Dragon Shield + mob:addGambit(ai.t.PARTY, { ai.c.NOT_STATUS, xi.effect.MAGIC_ATK_BOOST }, { ai.r.MS, ai.s.SPECIFIC, 4258 }, healingMoveCooldown) -- Mix: Elemental Power + mob:addGambit(ai.t.PARTY, { ai.c.NOT_STATUS, xi.effect.PROTECT }, { ai.r.MS, ai.s.SPECIFIC, 4255 }, healingMoveCooldown) -- Mix: Guard Drink + -- mob:addGambit(ai.t.PARTY, { ai.c.NOT_STATUS, xi.effect.NEGATE_SLEEP }, { ai.r.MS, ai.s.SPECIFIC, 4256 }, healingMoveCooldown) -- Insomniant. Disabled because animation when used is completely wrong. + mob:addGambit(ai.t.TARGET, { ai.c.HP_MISSING, 99 }, { ai.r.MS, ai.s.SPECIFIC, 4260 }, healingMoveCooldown) -- Dark Potion (666 Dark Damage) mob:setAutoAttackEnabled(false) diff --git a/scripts/actions/spells/trust/mumor.lua b/scripts/actions/spells/trust/mumor.lua index 7f88eb2232a..171beb5c04d 100644 --- a/scripts/actions/spells/trust/mumor.lua +++ b/scripts/actions/spells/trust/mumor.lua @@ -48,14 +48,14 @@ spellObject.onMobSpawn = function(mob) end) -- Sets stance - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_STATUS, xi.effect.SABER_DANCE, ai.r.JA, ai.s.SPECIFIC, xi.ja.SABER_DANCE) + mob:addGambit(ai.t.SELF, { ai.c.NOT_STATUS, xi.effect.SABER_DANCE }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.SABER_DANCE }) -- Step usage: -DEF debuff and stuns - mob:addSimpleGambit(ai.t.TARGET, ai.c.NOT_STATUS, xi.effect.WEAKENED_DAZE_5, ai.r.JA, ai.s.SPECIFIC, xi.ja.STUTTER_STEP) - mob:addSimpleGambit(ai.t.TARGET, ai.c.READYING_WS, 0, ai.r.JA, ai.s.SPECIFIC, xi.ja.VIOLENT_FLOURISH) - mob:addSimpleGambit(ai.t.TARGET, ai.c.READYING_MS, 0, ai.r.JA, ai.s.SPECIFIC, xi.ja.VIOLENT_FLOURISH) - mob:addSimpleGambit(ai.t.TARGET, ai.c.READYING_JA, 0, ai.r.JA, ai.s.SPECIFIC, xi.ja.VIOLENT_FLOURISH) - mob:addSimpleGambit(ai.t.TARGET, ai.c.CASTING_MA, 0, ai.r.JA, ai.s.SPECIFIC, xi.ja.VIOLENT_FLOURISH) + mob:addGambit(ai.t.TARGET, { ai.c.NOT_STATUS, xi.effect.WEAKENED_DAZE_5 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.STUTTER_STEP }) + mob:addGambit(ai.t.TARGET, { ai.c.READYING_WS, 0 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.VIOLENT_FLOURISH }) + mob:addGambit(ai.t.TARGET, { ai.c.READYING_MS, 0 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.VIOLENT_FLOURISH }) + mob:addGambit(ai.t.TARGET, { ai.c.READYING_JA, 0 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.VIOLENT_FLOURISH }) + mob:addGambit(ai.t.TARGET, { ai.c.CASTING_MA, 0 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.VIOLENT_FLOURISH }) -- Samba logic -- Checks masters job, adjusts samba type if master has a healer main job. @@ -65,14 +65,14 @@ spellObject.onMobSpawn = function(mob) master and master:getMainJob() == healingJobs[i] then - mob:addSimpleGambit(ai.t.SELF, ai.c.NO_SAMBA, ai.r.JA, 0, ai.s.SPECIFIC, xi.ja.HASTE_SAMBA) + mob:addGambit(ai.t.SELF, { ai.c.NO_SAMBA, ai.r.JA }, { 0, ai.s.SPECIFIC, xi.ja.HASTE_SAMBA }) end end -- Adds ecosystem to adjust samba to haste if target is undead - mob:addSimpleGambit(ai.t.TARGET, ai.c.IS_ECOSYSTEM, xi.ecosystem.UNDEAD, ai.r.JA, ai.s.SPECIFIC, xi.ja.HASTE_SAMBA) + mob:addGambit(ai.t.TARGET, { ai.c.IS_ECOSYSTEM, xi.ecosystem.UNDEAD }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.HASTE_SAMBA }) -- Else picks highest drain spell available - mob:addSimpleGambit(ai.t.SELF, ai.c.NO_SAMBA, 0, ai.r.JA, ai.s.BEST_SAMBA, xi.ja.DRAIN_SAMBA) + mob:addGambit(ai.t.SELF, { ai.c.NO_SAMBA, 0 }, { ai.r.JA, ai.s.BEST_SAMBA, xi.ja.DRAIN_SAMBA }) end spellObject.onMobDespawn = function(mob) diff --git a/scripts/actions/spells/trust/naja_salaheem.lua b/scripts/actions/spells/trust/naja_salaheem.lua index bc3005d369e..4473acd243e 100644 --- a/scripts/actions/spells/trust/naja_salaheem.lua +++ b/scripts/actions/spells/trust/naja_salaheem.lua @@ -28,14 +28,11 @@ spellObject.onMobSpawn = function(mob) end end) - mob:addSimpleGambit(ai.t.SELF, ai.c.ALWAYS, 0, - ai.r.JA, ai.s.SPECIFIC, xi.ja.FOCUS) + mob:addGambit(ai.t.SELF, { ai.c.ALWAYS, 0 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.FOCUS }) - mob:addSimpleGambit(ai.t.SELF, ai.c.ALWAYS, 0, - ai.r.JA, ai.s.SPECIFIC, xi.ja.DODGE) + mob:addGambit(ai.t.SELF, { ai.c.ALWAYS, 0 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.DODGE }) - mob:addSimpleGambit(ai.t.SELF, ai.c.HAS_TOP_ENMITY, 0, - ai.r.JA, ai.s.SPECIFIC, xi.ja.COUNTERSTANCE) + mob:addGambit(ai.t.SELF, { ai.c.HAS_TOP_ENMITY, 0 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.COUNTERSTANCE }) end spellObject.onMobDespawn = function(mob) diff --git a/scripts/actions/spells/trust/naji.lua b/scripts/actions/spells/trust/naji.lua index e3b88fc634d..e4d4d1fbe22 100644 --- a/scripts/actions/spells/trust/naji.lua +++ b/scripts/actions/spells/trust/naji.lua @@ -27,8 +27,7 @@ spellObject.onMobSpawn = function(mob) [xi.magic.spell.AYAME] = xi.trust.messageOffset.TEAMWORK_1, }) - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_HAS_TOP_ENMITY, 0, - ai.r.JA, ai.s.SPECIFIC, xi.ja.PROVOKE) + mob:addGambit(ai.t.SELF, { ai.c.NOT_HAS_TOP_ENMITY, 0 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.PROVOKE }) end spellObject.onMobDespawn = function(mob) diff --git a/scripts/actions/spells/trust/nanaa_mihgo.lua b/scripts/actions/spells/trust/nanaa_mihgo.lua index 96c0cfc73f4..f92e456dbca 100644 --- a/scripts/actions/spells/trust/nanaa_mihgo.lua +++ b/scripts/actions/spells/trust/nanaa_mihgo.lua @@ -17,8 +17,7 @@ spellObject.onMobSpawn = function(mob) [xi.magic.spell.ROMAA_MIHGO] = xi.trust.messageOffset.TEAMWORK_1, }) - mob:addSimpleGambit(ai.t.TARGET, ai.c.ALWAYS, 0, - ai.r.JA, ai.s.SPECIFIC, xi.ja.DESPOIL) + mob:addGambit(ai.t.TARGET, { ai.c.ALWAYS, 0 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.DESPOIL }) mob:setTrustTPSkillSettings(ai.tp.OPENER, ai.s.HIGHEST) end diff --git a/scripts/actions/spells/trust/nashmeira_ii.lua b/scripts/actions/spells/trust/nashmeira_ii.lua index b532a2f9764..f999f84da61 100644 --- a/scripts/actions/spells/trust/nashmeira_ii.lua +++ b/scripts/actions/spells/trust/nashmeira_ii.lua @@ -21,21 +21,21 @@ spellObject.onMobSpawn = function(mob) [xi.magic.spell.PRISHE_II] = xi.trust.messageOffset.TEAMWORK_5, }) - mob:addSimpleGambit(ai.t.PARTY, ai.c.HPP_LT, 75, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE) + mob:addGambit(ai.t.PARTY, { ai.c.HPP_LT, 75 }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE }) -- TODO: Should only use Curaga when *3* or more party members are below 75% -- Setting the Curaga threshold a bit lower here to prevent a priority conflict with regular Cure gambit, above. - mob:addSimpleGambit(ai.t.PARTY, ai.c.HPP_LT, 50, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURAGA) - - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.POISON, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.POISONA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.PARALYSIS, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.PARALYNA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.BLINDNESS, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.BLINDNA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.SILENCE, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.SILENA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.PETRIFICATION, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STONA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.DISEASE, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.VIRUNA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.CURSE_I, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURSNA) - - mob:addSimpleGambit(ai.t.SELF, ai.c.STATUS_FLAG, xi.effectFlag.ERASABLE, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.ERASE) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS_FLAG, xi.effectFlag.ERASABLE, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.ERASE) + mob:addGambit(ai.t.PARTY, { ai.c.HPP_LT, 50 }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURAGA }) + + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.POISON }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.POISONA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.PARALYSIS }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.PARALYNA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.BLINDNESS }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.BLINDNA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.SILENCE }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.SILENA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.PETRIFICATION }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STONA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.DISEASE }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.VIRUNA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.CURSE_I }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURSNA }) + + mob:addGambit(ai.t.SELF, { ai.c.STATUS_FLAG, xi.effectFlag.ERASABLE }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.ERASE }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS_FLAG, xi.effectFlag.ERASABLE }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.ERASE }) mob:addListener('WEAPONSKILL_USE', 'NASHMEIRA_II_WEAPONSKILL_USE', function(mobArg, target, wsid, tp, action) if wsid == 3243 then -- Imperial Authority diff --git a/scripts/actions/spells/trust/prishe.lua b/scripts/actions/spells/trust/prishe.lua index 0c0d6646aae..92db023a5e9 100644 --- a/scripts/actions/spells/trust/prishe.lua +++ b/scripts/actions/spells/trust/prishe.lua @@ -21,7 +21,7 @@ spellObject.onMobSpawn = function(mob) [xi.magic.spell.MILDAURION] = xi.trust.messageOffset.TEAMWORK_5, }) - mob:addSimpleGambit(ai.t.PARTY, ai.c.HPP_LT, 25, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE) + mob:addGambit(ai.t.PARTY, { ai.c.HPP_LT, 25 }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE }) end spellObject.onMobDespawn = function(mob) diff --git a/scripts/actions/spells/trust/prishe_ii.lua b/scripts/actions/spells/trust/prishe_ii.lua index 9f7ae254d98..2d1034ade9d 100644 --- a/scripts/actions/spells/trust/prishe_ii.lua +++ b/scripts/actions/spells/trust/prishe_ii.lua @@ -23,13 +23,13 @@ spellObject.onMobSpawn = function(mob) [xi.magic.spell.IROHA_II] = xi.trust.messageOffset.TEAMWORK_5, }) - local itemOneGambit = mob:addSimpleGambit(ai.t.SELF, ai.c.HPP_LT, 35, ai.r.MS, ai.s.SPECIFIC, psychoAnima) + local itemOneGambit = mob:addGambit(ai.t.SELF, { ai.c.HPP_LT, 35 }, { ai.r.MS, ai.s.SPECIFIC, psychoAnima }) -- TODO: Add additional logic for Hysteroanima - -- local itemTwoGambit = mob:addSimpleGambit(ai.t.TARGET, ai.c.CASTING_MA, 35, ai.r.MS, ai.s.SPECIFIC, 3540) + -- local itemTwoGambit = mob:addGambit(ai.t.TARGET, { ai.c.CASTING_MA, 35 }, { ai.r.MS, ai.s.SPECIFIC, 3540 }) - mob:addSimpleGambit(ai.t.PARTY, ai.c.HPP_LT, 25, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURAGA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.SLEEP_I, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURAGA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.SLEEP_II, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURAGA) + mob:addGambit(ai.t.PARTY, { ai.c.HPP_LT, 25 }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURAGA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.SLEEP_I }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURAGA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.SLEEP_II }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURAGA }) -- TODO: Trust Synergy: If Ulmia in the party, Prishe will cast Curaga when party members are in the yellow instead of red. -- Prishe will use Cure spells exclusively on Ulmia (Only Cure I-IV) diff --git a/scripts/actions/spells/trust/qultada.lua b/scripts/actions/spells/trust/qultada.lua index 5de42cdb5e9..02949ca496b 100644 --- a/scripts/actions/spells/trust/qultada.lua +++ b/scripts/actions/spells/trust/qultada.lua @@ -15,10 +15,10 @@ end spellObject.onMobSpawn = function(mob) xi.trust.message(mob, xi.trust.messageOffset.SPAWN) - mob:addSimpleGambit(ai.t.PARTY, ai.c.NOT_STATUS, xi.effect.CORSAIRS_ROLL, ai.r.JA, ai.s.SPECIFIC, xi.ja.CORSAIRS_ROLL) - mob:addSimpleGambit(ai.t.PARTY, ai.c.NOT_STATUS, xi.effect.CHAOS_ROLL, ai.r.JA, ai.s.SPECIFIC, xi.ja.CHAOS_ROLL) + mob:addGambit(ai.t.PARTY, { ai.c.NOT_STATUS, xi.effect.CORSAIRS_ROLL }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.CORSAIRS_ROLL }) + mob:addGambit(ai.t.PARTY, { ai.c.NOT_STATUS, xi.effect.CHAOS_ROLL }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.CHAOS_ROLL }) - mob:addSimpleGambit(ai.t.TARGET, ai.c.ALWAYS, 0, ai.r.RATTACK, 0, 0, 10) + mob:addGambit(ai.t.TARGET, { ai.c.ALWAYS, 0 }, { ai.r.RATTACK, 0, 0 }, 10) -- Notable: Uses a balance of melee and ranged attacks. -- TODO: Observe his WS behavior on retail diff --git a/scripts/actions/spells/trust/rainemard.lua b/scripts/actions/spells/trust/rainemard.lua index af360807642..4e3417f2e74 100644 --- a/scripts/actions/spells/trust/rainemard.lua +++ b/scripts/actions/spells/trust/rainemard.lua @@ -18,22 +18,22 @@ spellObject.onMobSpawn = function(mob) }) -- TODO: Selection based on enemy weakness - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_STATUS, xi.effect.ENFIRE, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.ENFIRE) + mob:addGambit(ai.t.SELF, { ai.c.NOT_STATUS, xi.effect.ENFIRE }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.ENFIRE }) - mob:addSimpleGambit(ai.t.TARGET, ai.c.NOT_STATUS, xi.effect.EVASION_DOWN, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.DISTRACT, 60) + mob:addGambit(ai.t.TARGET, { ai.c.NOT_STATUS, xi.effect.EVASION_DOWN }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.DISTRACT }, 60) - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_STATUS, xi.effect.PHALANX, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.PHALANX) - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_STATUS, xi.effect.HASTE, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.HASTE) - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_STATUS, xi.effect.REFRESH, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.REFRESH) + mob:addGambit(ai.t.SELF, { ai.c.NOT_STATUS, xi.effect.PHALANX }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.PHALANX }) + mob:addGambit(ai.t.SELF, { ai.c.NOT_STATUS, xi.effect.HASTE }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.HASTE }) + mob:addGambit(ai.t.SELF, { ai.c.NOT_STATUS, xi.effect.REFRESH }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.REFRESH }) -- If Curilla is present, will cast Haste/Phalanx/Refresh on her. - mob:addSimpleGambit(ai.t.CURILLA, ai.c.NOT_STATUS, xi.effect.HASTE, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.HASTE) - mob:addSimpleGambit(ai.t.CURILLA, ai.c.NOT_STATUS, xi.effect.PHALANX, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.PHALANX_II) - mob:addSimpleGambit(ai.t.CURILLA, ai.c.NOT_STATUS, xi.effect.REFRESH, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.REFRESH) + mob:addGambit(ai.t.CURILLA, { ai.c.NOT_STATUS, xi.effect.HASTE }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.HASTE }) + mob:addGambit(ai.t.CURILLA, { ai.c.NOT_STATUS, xi.effect.PHALANX }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.PHALANX_II }) + mob:addGambit(ai.t.CURILLA, { ai.c.NOT_STATUS, xi.effect.REFRESH }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.REFRESH }) -- NOTE: Do these late, to try and avoid clashing with healers casting -ra's - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_STATUS, xi.effect.PROTECT, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.PROTECT) - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_STATUS, xi.effect.SHELL, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.SHELL) + mob:addGambit(ai.t.SELF, { ai.c.NOT_STATUS, xi.effect.PROTECT }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.PROTECT }) + mob:addGambit(ai.t.SELF, { ai.c.NOT_STATUS, xi.effect.SHELL }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.SHELL }) end spellObject.onMobDespawn = function(mob) diff --git a/scripts/actions/spells/trust/rughadjeen.lua b/scripts/actions/spells/trust/rughadjeen.lua index ce59ce11533..182370f20da 100644 --- a/scripts/actions/spells/trust/rughadjeen.lua +++ b/scripts/actions/spells/trust/rughadjeen.lua @@ -34,22 +34,22 @@ spellObject.onMobSpawn = function(mob) mob:addMod(xi.mod.TRIPLE_ATTACK, 3) -- TODO: Add en-fire effect from Algol - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_STATUS, xi.effect.SENTINEL, ai.r.JA, ai.s.SPECIFIC, xi.ja.SENTINEL) + mob:addGambit(ai.t.SELF, { ai.c.NOT_STATUS, xi.effect.SENTINEL }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.SENTINEL }) - mob:addSimpleGambit(ai.t.TARGET, ai.c.NOT_STATUS, xi.effect.FLASH, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.FLASH) + mob:addGambit(ai.t.TARGET, { ai.c.NOT_STATUS, xi.effect.FLASH }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.FLASH }) - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_STATUS, xi.effect.DIVINE_EMBLEM, ai.r.JA, ai.s.SPECIFIC, xi.ja.DIVINE_EMBLEM) + mob:addGambit(ai.t.SELF, { ai.c.NOT_STATUS, xi.effect.DIVINE_EMBLEM }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.DIVINE_EMBLEM }) - mob:addSimpleGambit(ai.t.TARGET, ai.c.NOT_SC_AVAILABLE, 0, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.HOLY) + mob:addGambit(ai.t.TARGET, { ai.c.NOT_SC_AVAILABLE, 0 }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.HOLY }) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.SLEEP_I, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURE) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.SLEEP_II, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURE) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.SLEEP_I }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURE }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.SLEEP_II }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURE }) - mob:addSimpleGambit(ai.t.PARTY, ai.c.HPP_LT, 75, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE) + mob:addGambit(ai.t.PARTY, { ai.c.HPP_LT, 75 }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE }) - mob:addSimpleGambit(ai.t.TARGET, ai.c.IS_ECOSYSTEM, xi.ecosystem.UNDEAD, ai.r.JA, ai.s.SPECIFIC, xi.ja.HOLY_CIRCLE) + mob:addGambit(ai.t.TARGET, { ai.c.IS_ECOSYSTEM, xi.ecosystem.UNDEAD }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.HOLY_CIRCLE }) - mob:addSimpleGambit(ai.t.SELF, ai.c.MPP_LT, 50, ai.r.JA, ai.s.SPECIFIC, xi.ja.CHIVALRY) + mob:addGambit(ai.t.SELF, { ai.c.MPP_LT, 50 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.CHIVALRY }) -- TODO: Add Trust Synergy for Serpent Generals diff --git a/scripts/actions/spells/trust/semih_lafihna.lua b/scripts/actions/spells/trust/semih_lafihna.lua index 0986a4657a3..faefd5ab4c5 100644 --- a/scripts/actions/spells/trust/semih_lafihna.lua +++ b/scripts/actions/spells/trust/semih_lafihna.lua @@ -18,18 +18,14 @@ spellObject.onMobSpawn = function(mob) [xi.magic.spell.AJIDO_MARUJIDO] = xi.trust.messageOffset.TEAMWORK_2, }) - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_STATUS, xi.effect.BARRAGE, - ai.r.JA, ai.s.SPECIFIC, xi.ja.BARRAGE) + mob:addGambit(ai.t.SELF, { ai.c.NOT_STATUS, xi.effect.BARRAGE }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.BARRAGE }) - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_STATUS, xi.effect.SHARPSHOT, - ai.r.JA, ai.s.SPECIFIC, xi.ja.SHARPSHOT) + mob:addGambit(ai.t.SELF, { ai.c.NOT_STATUS, xi.effect.SHARPSHOT }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.SHARPSHOT }) - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_STATUS, xi.effect.DOUBLE_SHOT, - ai.r.JA, ai.s.SPECIFIC, xi.ja.DOUBLE_SHOT) + mob:addGambit(ai.t.SELF, { ai.c.NOT_STATUS, xi.effect.DOUBLE_SHOT }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.DOUBLE_SHOT }) -- TODO: Stealth Shot not yet implemented - -- mob:addSimpleGambit(ai.t.SELF, ai.c.HAS_TOP_ENMITY, 0, - -- ai.r.JA, ai.s.SPECIFIC, xi.ja.STEALTH_SHOT) + -- mob:addGambit(ai.t.SELF, { ai.c.HAS_TOP_ENMITY, 0 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.STEALTH_SHOT }) mob:addListener('WEAPONSKILL_USE', 'SEMIH_LAFIHNA_WEAPONSKILL_USE', function(mobArg, target, wsid, tp, action) if wsid == 3490 then -- Stellar Arrow @@ -39,7 +35,7 @@ spellObject.onMobSpawn = function(mob) end) -- Ranged Attack as much as possible (limited by 'weapon' delay) - mob:addSimpleGambit(ai.t.TARGET, ai.c.ALWAYS, 0, ai.r.RATTACK, 0, 0) + mob:addGambit(ai.t.TARGET, { ai.c.ALWAYS, 0 }, { ai.r.RATTACK, 0, 0 }) mob:setAutoAttackEnabled(false) diff --git a/scripts/actions/spells/trust/shantotto.lua b/scripts/actions/spells/trust/shantotto.lua index a830bfd95e2..c49ed399266 100644 --- a/scripts/actions/spells/trust/shantotto.lua +++ b/scripts/actions/spells/trust/shantotto.lua @@ -20,9 +20,9 @@ spellObject.onMobSpawn = function(mob) [xi.magic.spell.KING_OF_HEARTS] = xi.trust.messageOffset.TEAMWORK_4 }) - mob:addSimpleGambit(ai.t.TARGET, ai.c.MB_AVAILABLE, 0, ai.r.MA, ai.s.MB_ELEMENT, xi.magic.spellFamily.NONE) + mob:addGambit(ai.t.TARGET, { ai.c.MB_AVAILABLE, 0 }, { ai.r.MA, ai.s.MB_ELEMENT, xi.magic.spellFamily.NONE }) - mob:addSimpleGambit(ai.t.TARGET, ai.c.NOT_SC_AVAILABLE, 0, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.NONE, 60) + mob:addGambit(ai.t.TARGET, { ai.c.NOT_SC_AVAILABLE, 0 }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.NONE }, 60) local power = mob:getMainLvl() / 10 mob:addMod(xi.mod.MATT, power) diff --git a/scripts/actions/spells/trust/shantotto_ii.lua b/scripts/actions/spells/trust/shantotto_ii.lua index f67e3b944e4..a1b91422ec5 100644 --- a/scripts/actions/spells/trust/shantotto_ii.lua +++ b/scripts/actions/spells/trust/shantotto_ii.lua @@ -15,8 +15,8 @@ end spellObject.onMobSpawn = function(mob) xi.trust.message(mob, xi.trust.messageOffset.SPAWN) - mob:addSimpleGambit(ai.t.TARGET, ai.c.MB_AVAILABLE, 0, ai.r.MA, ai.s.MB_ELEMENT, xi.magic.spellFamily.NONE) - mob:addSimpleGambit(ai.t.TARGET, ai.c.NOT_SC_AVAILABLE, 0, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.NONE, 45) + mob:addGambit(ai.t.TARGET, { ai.c.MB_AVAILABLE, 0 }, { ai.r.MA, ai.s.MB_ELEMENT, xi.magic.spellFamily.NONE }) + mob:addGambit(ai.t.TARGET, { ai.c.NOT_SC_AVAILABLE, 0 }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.NONE }, 45) local trustLevel = mob:getMainLvl() local power = trustLevel / 5 diff --git a/scripts/actions/spells/trust/shikaree_z.lua b/scripts/actions/spells/trust/shikaree_z.lua index 953c811d191..468d63e702d 100644 --- a/scripts/actions/spells/trust/shikaree_z.lua +++ b/scripts/actions/spells/trust/shikaree_z.lua @@ -27,29 +27,29 @@ spellObject.onMobSpawn = function(mob) mob:addMod(xi.mod.STORETP, 174) mob:addMod(xi.mod.JUMP_TP_BONUS, 164) - mob:addSimpleGambit(ai.t.SELF, ai.c.STATUS, xi.effect.SLOW, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.ERASE) - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_STATUS, xi.effect.HASTE, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.HASTE) - mob:addSimpleGambit(ai.t.MASTER, ai.c.STATUS, xi.effect.SLOW, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.ERASE) - mob:addSimpleGambit(ai.t.MASTER, ai.c.NOT_STATUS, xi.effect.HASTE, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.HASTE) + mob:addGambit(ai.t.SELF, { ai.c.STATUS, xi.effect.SLOW }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.ERASE }) + mob:addGambit(ai.t.SELF, { ai.c.NOT_STATUS, xi.effect.HASTE }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.HASTE }) + mob:addGambit(ai.t.MASTER, { ai.c.STATUS, xi.effect.SLOW }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.ERASE }) + mob:addGambit(ai.t.MASTER, { ai.c.NOT_STATUS, xi.effect.HASTE }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.HASTE }) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.SLEEP_I, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURE) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.SLEEP_II, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURE) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.SLEEP_I }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURE }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.SLEEP_II }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURE }) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.POISON, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.POISONA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.PARALYSIS, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.PARALYNA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.BLINDNESS, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.BLINDNA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.SILENCE, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.SILENA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.PETRIFICATION, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STONA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.DISEASE, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.VIRUNA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.CURSE_I, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURSNA) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.POISON }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.POISONA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.PARALYSIS }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.PARALYNA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.BLINDNESS }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.BLINDNA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.SILENCE }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.SILENA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.PETRIFICATION }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STONA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.DISEASE }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.VIRUNA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.CURSE_I }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURSNA }) - mob:addSimpleGambit(ai.t.PARTY, ai.c.HPP_LT, 50, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE) + mob:addGambit(ai.t.PARTY, { ai.c.HPP_LT, 50 }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE }) - mob:addSimpleGambit(ai.t.TARGET, ai.c.IS_ECOSYSTEM, xi.ecosystem.DRAGON, ai.r.JA, ai.s.SPECIFIC, xi.ja.ANCIENT_CIRCLE) + mob:addGambit(ai.t.TARGET, { ai.c.IS_ECOSYSTEM, xi.ecosystem.DRAGON }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.ANCIENT_CIRCLE }) - mob:addSimpleGambit(ai.t.TARGET, ai.c.ALWAYS, 0, ai.r.JA, ai.s.SPECIFIC, xi.ja.JUMP) - mob:addSimpleGambit(ai.t.TARGET, ai.c.ALWAYS, 0, ai.r.JA, ai.s.SPECIFIC, xi.ja.HIGH_JUMP) - mob:addSimpleGambit(ai.t.SELF, ai.c.HAS_TOP_ENMITY, 0, ai.r.JA, ai.s.SPECIFIC, xi.ja.SUPER_JUMP) + mob:addGambit(ai.t.TARGET, { ai.c.ALWAYS, 0 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.JUMP }) + mob:addGambit(ai.t.TARGET, { ai.c.ALWAYS, 0 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.HIGH_JUMP }) + mob:addGambit(ai.t.SELF, { ai.c.HAS_TOP_ENMITY, 0 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.SUPER_JUMP }) mob:setTrustTPSkillSettings(ai.tp.CLOSER_UNTIL_TP, ai.s.HIGHEST, 2000) end diff --git a/scripts/actions/spells/trust/sylvie_uc.lua b/scripts/actions/spells/trust/sylvie_uc.lua index 2e855f7659c..176bd09ed10 100644 --- a/scripts/actions/spells/trust/sylvie_uc.lua +++ b/scripts/actions/spells/trust/sylvie_uc.lua @@ -34,28 +34,28 @@ spellObject.onMobSpawn = function(mob) mob:addMod(xi.mod.GEOMANCY_BONUS, 3) end - mob:addSimpleGambit(ai.t.PARTY, ai.c.HPP_LT, 25, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE) + mob:addGambit(ai.t.PARTY, { ai.c.HPP_LT, 25 }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE }) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.SLEEP_I, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURE) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.SLEEP_II, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURE) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.SLEEP_I }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURE }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.SLEEP_II }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURE }) - mob:addSimpleGambit(ai.t.PARTY, ai.c.HPP_LT, 75, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE) + mob:addGambit(ai.t.PARTY, { ai.c.HPP_LT, 75 }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE }) - mob:addSimpleGambit(ai.t.MASTER, ai.c.STATUS_FLAG, xi.effectFlag.ERASABLE, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.ERASE) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS_FLAG, xi.effectFlag.ERASABLE, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.ERASE) - mob:addSimpleGambit(ai.t.SELF, ai.c.STATUS_FLAG, xi.effectFlag.ERASABLE, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.ERASE) + mob:addGambit(ai.t.MASTER, { ai.c.STATUS_FLAG, xi.effectFlag.ERASABLE }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.ERASE }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS_FLAG, xi.effectFlag.ERASABLE }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.ERASE }) + mob:addGambit(ai.t.SELF, { ai.c.STATUS_FLAG, xi.effectFlag.ERASABLE }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.ERASE }) if mob:getMainLvl() >= 20 then - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_STATUS, xi.effect.COLURE_ACTIVE, ai.r.MA, ai.s.BEST_INDI, xi.magic.spellFamily.NONE) + mob:addGambit(ai.t.SELF, { ai.c.NOT_STATUS, xi.effect.COLURE_ACTIVE }, { ai.r.MA, ai.s.BEST_INDI, xi.magic.spellFamily.NONE }) end if mob:getMainLvl() >= 93 and mJob ~= xi.job.GEO then - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_STATUS, xi.effect.ENTRUST, ai.r.JA, ai.s.SPECIFIC, xi.jobAbility.ENTRUST) - mob:addSimpleGambit(ai.t.SELF, ai.c.STATUS, xi.effect.ENTRUST, ai.r.MA, ai.s.ENTRUSTED, xi.magic.spellFamily.INDI_BUFF) + mob:addGambit(ai.t.SELF, { ai.c.NOT_STATUS, xi.effect.ENTRUST }, { ai.r.JA, ai.s.SPECIFIC, xi.jobAbility.ENTRUST }) + mob:addGambit(ai.t.SELF, { ai.c.STATUS, xi.effect.ENTRUST }, { ai.r.MA, ai.s.ENTRUSTED, xi.magic.spellFamily.INDI_BUFF }) end - mob:addSimpleGambit(ai.t.MASTER, ai.c.NOT_STATUS, xi.effect.HASTE, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.HASTE) - mob:addSimpleGambit(ai.t.MELEE, ai.c.NOT_STATUS, xi.effect.HASTE, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.HASTE) + mob:addGambit(ai.t.MASTER, { ai.c.NOT_STATUS, xi.effect.HASTE }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.HASTE }) + mob:addGambit(ai.t.MELEE, { ai.c.NOT_STATUS, xi.effect.HASTE }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.HASTE }) mob:setAutoAttackEnabled(false) end diff --git a/scripts/actions/spells/trust/tenzen.lua b/scripts/actions/spells/trust/tenzen.lua index 191557c9365..da38ea6ab5e 100644 --- a/scripts/actions/spells/trust/tenzen.lua +++ b/scripts/actions/spells/trust/tenzen.lua @@ -22,11 +22,9 @@ spellObject.onMobSpawn = function(mob) [xi.magic.spell.IROHA] = xi.trust.messageOffset.TEAMWORK_1, }) - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_STATUS, xi.effect.HASSO, - ai.r.JA, ai.s.SPECIFIC, xi.ja.HASSO) + mob:addGambit(ai.t.SELF, { ai.c.NOT_STATUS, xi.effect.HASSO }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.HASSO }) - mob:addSimpleGambit(ai.t.SELF, ai.c.HAS_TOP_ENMITY, 0, - ai.r.JA, ai.s.SPECIFIC, xi.ja.THIRD_EYE) + mob:addGambit(ai.t.SELF, { ai.c.HAS_TOP_ENMITY, 0 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.THIRD_EYE }) mob:setTrustTPSkillSettings(ai.tp.CLOSER_UNTIL_TP, ai.s.HIGHEST, 1500) end diff --git a/scripts/actions/spells/trust/tenzen_ii.lua b/scripts/actions/spells/trust/tenzen_ii.lua index e80d9228ce7..dc55b5b5013 100644 --- a/scripts/actions/spells/trust/tenzen_ii.lua +++ b/scripts/actions/spells/trust/tenzen_ii.lua @@ -35,7 +35,7 @@ spellObject.onMobSpawn = function(mob) end) -- Ranged Attack as much as possible (limited by 'weapon' delay) - mob:addSimpleGambit(ai.t.TARGET, ai.c.ALWAYS, 0, ai.r.RATTACK, 0, 0) + mob:addGambit(ai.t.TARGET, { ai.c.ALWAYS, 0 }, { ai.r.RATTACK, 0, 0 }) mob:setAutoAttackEnabled(false) diff --git a/scripts/actions/spells/trust/trion.lua b/scripts/actions/spells/trust/trion.lua index 98b5f25db1a..86faf6da0ff 100644 --- a/scripts/actions/spells/trust/trion.lua +++ b/scripts/actions/spells/trust/trion.lua @@ -19,14 +19,11 @@ spellObject.onMobSpawn = function(mob) [xi.magic.spell.HALVER] = xi.trust.messageOffset.TEAMWORK_3, }) - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_HAS_TOP_ENMITY, 0, - ai.r.JA, ai.s.SPECIFIC, xi.ja.PROVOKE) + mob:addGambit(ai.t.SELF, { ai.c.NOT_HAS_TOP_ENMITY, 0 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.PROVOKE }) - mob:addSimpleGambit(ai.t.TARGET, ai.c.NOT_STATUS, xi.effect.FLASH, - ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.FLASH) + mob:addGambit(ai.t.TARGET, { ai.c.NOT_STATUS, xi.effect.FLASH }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.FLASH }) - mob:addSimpleGambit(ai.t.PARTY, ai.c.HPP_LT, 75, - ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE) + mob:addGambit(ai.t.PARTY, { ai.c.HPP_LT, 75 }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE }) end spellObject.onMobDespawn = function(mob) diff --git a/scripts/actions/spells/trust/uka_totlihn.lua b/scripts/actions/spells/trust/uka_totlihn.lua index 1fabf8c1892..c07254923fe 100644 --- a/scripts/actions/spells/trust/uka_totlihn.lua +++ b/scripts/actions/spells/trust/uka_totlihn.lua @@ -54,27 +54,27 @@ spellObject.onMobSpawn = function(mob) master and master:getMainJob() == healingJobs[i] then - mob:addSimpleGambit(ai.t.SELF, ai.c.NO_SAMBA, 0, ai.r.JA, ai.s.SPECIFIC, xi.ja.HASTE_SAMBA) + mob:addGambit(ai.t.SELF, { ai.c.NO_SAMBA, 0 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.HASTE_SAMBA }) end end -- Step Interactions: - mob:addSimpleGambit(ai.t.TARGET, ai.c.NOT_STATUS, xi.effect.LETHARGIC_DAZE_5, ai.r.JA, ai.s.SPECIFIC, xi.ja.QUICKSTEP, 20) - mob:addSimpleGambit(ai.t.TARGET, ai.c.READYING_WS, 0, ai.r.JA, ai.s.SPECIFIC, xi.ja.VIOLENT_FLOURISH) - mob:addSimpleGambit(ai.t.TARGET, ai.c.READYING_MS, 0, ai.r.JA, ai.s.SPECIFIC, xi.ja.VIOLENT_FLOURISH) - mob:addSimpleGambit(ai.t.TARGET, ai.c.READYING_JA, 0, ai.r.JA, ai.s.SPECIFIC, xi.ja.VIOLENT_FLOURISH) - mob:addSimpleGambit(ai.t.TARGET, ai.c.CASTING_MA, 0, ai.r.JA, ai.s.SPECIFIC, xi.ja.VIOLENT_FLOURISH) + mob:addGambit(ai.t.TARGET, { ai.c.NOT_STATUS, xi.effect.LETHARGIC_DAZE_5 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.QUICKSTEP }, 20) + mob:addGambit(ai.t.TARGET, { ai.c.READYING_WS, 0 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.VIOLENT_FLOURISH }) + mob:addGambit(ai.t.TARGET, { ai.c.READYING_MS, 0 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.VIOLENT_FLOURISH }) + mob:addGambit(ai.t.TARGET, { ai.c.READYING_JA, 0 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.VIOLENT_FLOURISH }) + mob:addGambit(ai.t.TARGET, { ai.c.CASTING_MA, 0 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.VIOLENT_FLOURISH }) -- Ecosystem check to swap to Haste samba if the target is undead - mob:addSimpleGambit(ai.t.TARGET, ai.c.IS_ECOSYSTEM, xi.ecosystem.UNDEAD, ai.r.JA, ai.s.SPECIFIC, xi.ja.HASTE_SAMBA) + mob:addGambit(ai.t.TARGET, { ai.c.IS_ECOSYSTEM, xi.ecosystem.UNDEAD }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.HASTE_SAMBA }) -- Healing logic - mob:addSimpleGambit(ai.t.PARTY, ai.c.HPP_LT, 50, ai.r.JA, ai.s.HIGHEST_WALTZ, xi.ja.CURING_WALTZ) - mob:addSimpleGambit(ai.t.SELF, ai.c.NO_SAMBA, 0, ai.r.JA, ai.s.BEST_SAMBA, xi.ja.DRAIN_SAMBA) - mob:addSimpleGambit(ai.t.SELF, ai.c.STATUS_FLAG, xi.effectFlag.WALTZABLE, ai.r.JA, ai.s.SPECIFIC, xi.ja.HEALING_WALTZ) + mob:addGambit(ai.t.PARTY, { ai.c.HPP_LT, 50 }, { ai.r.JA, ai.s.HIGHEST_WALTZ, xi.ja.CURING_WALTZ }) + mob:addGambit(ai.t.SELF, { ai.c.NO_SAMBA, 0 }, { ai.r.JA, ai.s.BEST_SAMBA, xi.ja.DRAIN_SAMBA }) + mob:addGambit(ai.t.SELF, { ai.c.STATUS_FLAG, xi.effectFlag.WALTZABLE }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.HEALING_WALTZ }) -- TP use and return - mob:addSimpleGambit(ai.t.SELF, ai.c.STATUS, xi.effect.FINISHING_MOVE_5, ai.r.JA, ai.s.SPECIFIC, xi.ja.REVERSE_FLOURISH, 60) + mob:addGambit(ai.t.SELF, { ai.c.STATUS, xi.effect.FINISHING_MOVE_5 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.REVERSE_FLOURISH }, 60) mob:setTrustTPSkillSettings(ai.tp.CLOSER_UNTIL_TP, ai.s.RANDOM, 2000) end diff --git a/scripts/actions/spells/trust/ulmia.lua b/scripts/actions/spells/trust/ulmia.lua index 632eb9fefca..f2ecae8eb4a 100644 --- a/scripts/actions/spells/trust/ulmia.lua +++ b/scripts/actions/spells/trust/ulmia.lua @@ -19,8 +19,8 @@ spellObject.onMobSpawn = function(mob) }) -- TODO: BRD trusts need better logic and major overhaul, for now they compliment each other - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_STATUS, xi.effect.MADRIGAL, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.MADRIGAL) - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_STATUS, xi.effect.MINUET, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.VALOR_MINUET) + mob:addGambit(ai.t.SELF, { ai.c.NOT_STATUS, xi.effect.MADRIGAL }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.MADRIGAL }) + mob:addGambit(ai.t.SELF, { ai.c.NOT_STATUS, xi.effect.MINUET }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.VALOR_MINUET }) mob:setAutoAttackEnabled(false) diff --git a/scripts/actions/spells/trust/valaineral.lua b/scripts/actions/spells/trust/valaineral.lua index 994e4552293..55ee275370e 100644 --- a/scripts/actions/spells/trust/valaineral.lua +++ b/scripts/actions/spells/trust/valaineral.lua @@ -24,17 +24,13 @@ spellObject.onMobSpawn = function(mob) ]] xi.trust.message(mob, xi.trust.messageOffset.SPAWN) - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_HAS_TOP_ENMITY, 0, - ai.r.JA, ai.s.SPECIFIC, xi.ja.PROVOKE) + mob:addGambit(ai.t.SELF, { ai.c.NOT_HAS_TOP_ENMITY, 0 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.PROVOKE }) - mob:addSimpleGambit(ai.t.TARGET, ai.c.NOT_STATUS, xi.effect.FLASH, - ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.FLASH) + mob:addGambit(ai.t.TARGET, { ai.c.NOT_STATUS, xi.effect.FLASH }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.FLASH }) - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_STATUS, xi.effect.SENTINEL, - ai.r.JA, ai.s.SPECIFIC, xi.ja.SENTINEL) + mob:addGambit(ai.t.SELF, { ai.c.NOT_STATUS, xi.effect.SENTINEL }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.SENTINEL }) - mob:addSimpleGambit(ai.t.PARTY, ai.c.HPP_LT, 50, - ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE) + mob:addGambit(ai.t.PARTY, { ai.c.HPP_LT, 50 }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE }) end spellObject.onMobDespawn = function(mob) diff --git a/scripts/actions/spells/trust/volker.lua b/scripts/actions/spells/trust/volker.lua index b175c36e078..7e961d5b9e9 100644 --- a/scripts/actions/spells/trust/volker.lua +++ b/scripts/actions/spells/trust/volker.lua @@ -24,16 +24,16 @@ spellObject.onMobSpawn = function(mob) }) -- DD Mode - mob:addSimpleGambit(ai.t.SELF, ai.c.PT_HAS_TANK, 0, ai.r.JA, ai.s.SPECIFIC, xi.ja.BERSERK) - mob:addSimpleGambit(ai.t.SELF, ai.c.PT_HAS_TANK, 0, ai.r.JA, ai.s.SPECIFIC, xi.ja.AGGRESSOR) - mob:addSimpleGambit(ai.t.TANK, ai.c.HPP_LT, 50, ai.r.JA, ai.s.SPECIFIC, xi.ja.PROVOKE) + mob:addGambit(ai.t.SELF, { ai.c.PT_HAS_TANK, 0 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.BERSERK }) + mob:addGambit(ai.t.SELF, { ai.c.PT_HAS_TANK, 0 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.AGGRESSOR }) + mob:addGambit(ai.t.TANK, { ai.c.HPP_LT, 50 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.PROVOKE }) -- Tank Mode - mob:addSimpleGambit(ai.t.TARGET, ai.c.NOT_PT_HAS_TANK, 0, ai.r.JA, ai.s.SPECIFIC, xi.ja.PROVOKE) - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_PT_HAS_TANK, 0, ai.r.JA, ai.s.SPECIFIC, xi.ja.DEFENDER) - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_PT_HAS_TANK, 0, ai.r.JA, ai.s.SPECIFIC, xi.ja.RETALIATION) + mob:addGambit(ai.t.TARGET, { ai.c.NOT_PT_HAS_TANK, 0 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.PROVOKE }) + mob:addGambit(ai.t.SELF, { ai.c.NOT_PT_HAS_TANK, 0 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.DEFENDER }) + mob:addGambit(ai.t.SELF, { ai.c.NOT_PT_HAS_TANK, 0 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.RETALIATION }) - mob:addSimpleGambit(ai.t.MASTER, ai.c.HPP_LT, 50, ai.r.JA, ai.s.SPECIFIC, xi.ja.PROVOKE) + mob:addGambit(ai.t.MASTER, { ai.c.HPP_LT, 50 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.PROVOKE }) -- TODO: Add Warriors Charge + WS Logic end diff --git a/scripts/actions/spells/trust/yoran-oran_uc.lua b/scripts/actions/spells/trust/yoran-oran_uc.lua index 735153947a7..bf5183dab93 100644 --- a/scripts/actions/spells/trust/yoran-oran_uc.lua +++ b/scripts/actions/spells/trust/yoran-oran_uc.lua @@ -25,21 +25,21 @@ spellObject.onMobSpawn = function(mob) mob:addMod(xi.mod.REGAIN, 50) mob:addMod(xi.mod.MPP, 15) -- TODO: This is supposed to increase with Unity rank, but I don't believe that's implemented so it is set to the minimum. - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_STATUS, xi.effect.AFFLATUS_SOLACE, ai.r.JA, ai.s.SPECIFIC, xi.ja.AFFLATUS_SOLACE) - mob:addSimpleGambit(ai.t.PARTY, ai.c.HPP_LT, 25, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE) -- Prioritizes curing party members at lower HP%. - mob:addSimpleGambit(ai.t.PARTY, ai.c.HPP_LT, 75, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE) - mob:addSimpleGambit(ai.t.PARTY, ai.c.NOT_STATUS, xi.effect.PROTECT, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.PROTECTRA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.NOT_STATUS, xi.effect.SHELL, ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.SHELLRA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.POISON, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.POISONA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.PARALYSIS, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.PARALYNA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.BLINDNESS, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.BLINDNA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.SILENCE, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.SILENA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.PETRIFICATION, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STONA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.DISEASE, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.VIRUNA) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS, xi.effect.CURSE_I, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURSNA) - mob:addSimpleGambit(ai.t.SELF, ai.c.STATUS_FLAG, xi.effectFlag.ERASABLE, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.ERASE) - mob:addSimpleGambit(ai.t.PARTY, ai.c.STATUS_FLAG, xi.effectFlag.ERASABLE, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.ERASE) - mob:addSimpleGambit(ai.t.SELF, ai.c.NOT_STATUS, xi.effect.STONESKIN, ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STONESKIN) + mob:addGambit(ai.t.SELF, { ai.c.NOT_STATUS, xi.effect.AFFLATUS_SOLACE }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.AFFLATUS_SOLACE }) + mob:addGambit(ai.t.PARTY, { ai.c.HPP_LT, 25 }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE }) -- Prioritizes curing party members at lower HP%. + mob:addGambit(ai.t.PARTY, { ai.c.HPP_LT, 75 }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.CURE }) + mob:addGambit(ai.t.PARTY, { ai.c.NOT_STATUS, xi.effect.PROTECT }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.PROTECTRA }) + mob:addGambit(ai.t.PARTY, { ai.c.NOT_STATUS, xi.effect.SHELL }, { ai.r.MA, ai.s.HIGHEST, xi.magic.spellFamily.SHELLRA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.POISON }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.POISONA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.PARALYSIS }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.PARALYNA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.BLINDNESS }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.BLINDNA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.SILENCE }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.SILENA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.PETRIFICATION }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STONA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.DISEASE }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.VIRUNA }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS, xi.effect.CURSE_I }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.CURSNA }) + mob:addGambit(ai.t.SELF, { ai.c.STATUS_FLAG, xi.effectFlag.ERASABLE }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.ERASE }) + mob:addGambit(ai.t.PARTY, { ai.c.STATUS_FLAG, xi.effectFlag.ERASABLE }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.ERASE }) + mob:addGambit(ai.t.SELF, { ai.c.NOT_STATUS, xi.effect.STONESKIN }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STONESKIN }) mob:setAutoAttackEnabled(false) mob:setMobMod(xi.mobMod.TRUST_DISTANCE, xi.trust.movementType.LONG_RANGE) diff --git a/scripts/actions/spells/trust/zeid_ii.lua b/scripts/actions/spells/trust/zeid_ii.lua index 4d5e1801b89..92d5119ecec 100644 --- a/scripts/actions/spells/trust/zeid_ii.lua +++ b/scripts/actions/spells/trust/zeid_ii.lua @@ -25,24 +25,18 @@ spellObject.onMobSpawn = function(mob) end) -- Stun all the things! - mob:addSimpleGambit(ai.t.TARGET, ai.c.READYING_WS, 0, - ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STUN) + mob:addGambit(ai.t.TARGET, { ai.c.READYING_WS, 0 }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STUN }) - mob:addSimpleGambit(ai.t.TARGET, ai.c.READYING_MS, 0, - ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STUN) + mob:addGambit(ai.t.TARGET, { ai.c.READYING_MS, 0 }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STUN }) - mob:addSimpleGambit(ai.t.TARGET, ai.c.READYING_JA, 0, - ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STUN) + mob:addGambit(ai.t.TARGET, { ai.c.READYING_JA, 0 }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STUN }) - mob:addSimpleGambit(ai.t.TARGET, ai.c.CASTING_MA, 0, - ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STUN) + mob:addGambit(ai.t.TARGET, { ai.c.CASTING_MA, 0 }, { ai.r.MA, ai.s.SPECIFIC, xi.magic.spell.STUN }) -- Non-stun things - mob:addSimpleGambit(ai.t.SELF, ai.c.ALWAYS, 0, - ai.r.JA, ai.s.SPECIFIC, xi.ja.SOULEATER) + mob:addGambit(ai.t.SELF, { ai.c.ALWAYS, 0 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.SOULEATER }) - mob:addSimpleGambit(ai.t.SELF, ai.c.ALWAYS, 0, - ai.r.JA, ai.s.SPECIFIC, xi.ja.LAST_RESORT) + mob:addGambit(ai.t.SELF, { ai.c.ALWAYS, 0 }, { ai.r.JA, ai.s.SPECIFIC, xi.ja.LAST_RESORT }) mob:setTrustTPSkillSettings(ai.tp.CLOSER_UNTIL_TP, ai.s.RANDOM, 3000) end From 94987cdbaf1506939e877c6ce8c9b489a739e6f8 Mon Sep 17 00:00:00 2001 From: Zach Toogood Date: Tue, 28 Jan 2025 21:12:52 +0000 Subject: [PATCH 2/2] Remove 'SimpleGambit' concept --- scripts/actions/spells/trust/prishe_ii.lua | 4 +- scripts/specs/core/CBaseEntity.lua | 20 -------- src/map/lua/lua_baseentity.cpp | 55 +--------------------- src/map/lua/lua_baseentity.h | 3 -- 4 files changed, 3 insertions(+), 79 deletions(-) diff --git a/scripts/actions/spells/trust/prishe_ii.lua b/scripts/actions/spells/trust/prishe_ii.lua index 2d1034ade9d..53d96875131 100644 --- a/scripts/actions/spells/trust/prishe_ii.lua +++ b/scripts/actions/spells/trust/prishe_ii.lua @@ -44,12 +44,12 @@ spellObject.onMobSpawn = function(mob) mob:addListener('WEAPONSKILL_STATE_EXIT', 'ANIMA_USED', function(mobArg, wsid) if wsid == psychoAnima then - mobArg:removeSimpleGambit(itemOneGambit) + mobArg:removeGambit(itemOneGambit) end --[[ if wsid == hysteroAnima then - mobArg:removeSimpleGambit(itemTwoGambit) + mobArg:removeGambit(itemTwoGambit) end ]]-- end) diff --git a/scripts/specs/core/CBaseEntity.lua b/scripts/specs/core/CBaseEntity.lua index 3acc44383d7..15117088f7b 100644 --- a/scripts/specs/core/CBaseEntity.lua +++ b/scripts/specs/core/CBaseEntity.lua @@ -3287,35 +3287,15 @@ end function CBaseEntity:addGambit(targ, conditions, reactions, retry) end ----@param targ integer ----@param cond integer ----@param condition_arg integer ----@param react integer ----@param select integer ----@param selectorArg integer ----@param retry integer? ----@return string -function CBaseEntity:addSimpleGambit(targ, cond, condition_arg, react, select, selectorArg, retry) -end - ---@param id string ---@return nil function CBaseEntity:removeGambit(id) end ----@param id string ----@return nil -function CBaseEntity:removeSimpleGambit(id) -end - ---@return nil function CBaseEntity:removeAllGambits() end ----@return nil -function CBaseEntity:removeAllSimpleGambits() -end - ---@param trigger integer ---@param select integer ---@param value integer? diff --git a/src/map/lua/lua_baseentity.cpp b/src/map/lua/lua_baseentity.cpp index 47257ba7e6c..90862b35cf0 100644 --- a/src/map/lua/lua_baseentity.cpp +++ b/src/map/lua/lua_baseentity.cpp @@ -15286,35 +15286,12 @@ std::string CLuaBaseEntity::addGambit(uint16 targ, sol::table const& predicates, return controller->m_GambitsContainer->AddGambit(g); } -/************************************************************************ - * DEPRECATED: Use trust:addGambit(...) instead - * Function: addSimpleGambit() - * Purpose : - * Example : trust:addSimpleGambit(target, condition, condition_arg, reaction, selector, selector_arg) - * Notes : Adds a behavior to the gambit system - ************************************************************************/ - -std::string CLuaBaseEntity::addSimpleGambit(uint16 targ, uint16 cond, uint32 condition_arg, uint16 react, uint16 select, uint32 selector_arg, sol::object const& retry) -{ - const auto* PTrust = dynamic_cast(m_PBaseEntity); - if (!PTrust) - { - ShowWarning("Invalid Entity calling function (%s).", m_PBaseEntity->getName()); - return {}; - } - ShowWarning("%s: addSimpleGambit is deprecated. Please use addGambit instead.", m_PBaseEntity->getName()); - const auto conditionsTable = lua.create_table_with(1, cond, 2, condition_arg); - const auto reactionsTable = lua.create_table_with(1, react, 2, select, 3, selector_arg); - - return addGambit(targ, conditionsTable, reactionsTable, retry); -} - /************************************************************************ * Function: removeGambit() * Purpose : * Example : trust:removeGambit(id) * Notes : Removes a behavior from the gambit system, using the id returned - * : from addGambit/addSimpleGambit + * : from addGambit ************************************************************************/ void CLuaBaseEntity::removeGambit(std::string const& id) @@ -15331,20 +15308,6 @@ void CLuaBaseEntity::removeGambit(std::string const& id) controller->m_GambitsContainer->RemoveGambit(id); } -/************************************************************************ - * Function: removeSimpleGambit() - * Purpose : - * Example : trust:removeSimpleGambit(id) - * Notes : Removes a behavior from the gambit system, using the id returned - * : from addSimpleGambit - ************************************************************************/ - -void CLuaBaseEntity::removeSimpleGambit(std::string const& id) -{ - ShowWarning("%s: removeSimpleGambit is deprecated. Please use removeGambit instead.", m_PBaseEntity->getName()); - removeGambit(id); -} - /************************************************************************ * Function: removeAllGambits() * Purpose : @@ -15366,19 +15329,6 @@ void CLuaBaseEntity::removeAllGambits() controller->m_GambitsContainer->RemoveAllGambits(); } -/************************************************************************ - * Function: removeAllSimpleGambits() - * Purpose : - * Example : trust:removeAllSimpleGambits() - * Notes : Removes all gambits from a trust. - ************************************************************************/ - -void CLuaBaseEntity::removeAllSimpleGambits() -{ - ShowWarning("%s: removeAllSimpleGambits is deprecated. Please use removeAllGambits instead.", m_PBaseEntity->getName()); - removeAllGambits(); -} - /************************************************************************ * Function: setTrustTPSkillSettings(trigger, select, value) * Purpose : @@ -19555,11 +19505,8 @@ void CLuaBaseEntity::Register() SOL_REGISTER("getTrustID", CLuaBaseEntity::getTrustID); SOL_REGISTER("trustPartyMessage", CLuaBaseEntity::trustPartyMessage); SOL_REGISTER("addGambit", CLuaBaseEntity::addGambit); - SOL_REGISTER("addSimpleGambit", CLuaBaseEntity::addSimpleGambit); SOL_REGISTER("removeGambit", CLuaBaseEntity::removeGambit); - SOL_REGISTER("removeSimpleGambit", CLuaBaseEntity::removeSimpleGambit); SOL_REGISTER("removeAllGambits", CLuaBaseEntity::removeAllGambits); - SOL_REGISTER("removeAllSimpleGambits", CLuaBaseEntity::removeAllSimpleGambits); SOL_REGISTER("setTrustTPSkillSettings", CLuaBaseEntity::setTrustTPSkillSettings); // Mob Entity-Specific diff --git a/src/map/lua/lua_baseentity.h b/src/map/lua/lua_baseentity.h index 1f67b122865..77c8a5ed168 100644 --- a/src/map/lua/lua_baseentity.h +++ b/src/map/lua/lua_baseentity.h @@ -753,11 +753,8 @@ class CLuaBaseEntity uint32 getTrustID(); void trustPartyMessage(uint32 message_id); auto addGambit(uint16 targ, sol::table const& predicates, sol::table const& reactions, sol::object const& retry) -> std::string; - auto addSimpleGambit(uint16 targ, uint16 cond, uint32 condition_arg, uint16 react, uint16 select, uint32 selector_arg, sol::object const& retry) -> std::string; void removeGambit(std::string const& id); - void removeSimpleGambit(std::string const& id); void removeAllGambits(); - void removeAllSimpleGambits(); void setTrustTPSkillSettings(uint16 trigger, uint16 select, sol::object const& value); bool hasValidJugPetItem();