|
Gearswap Support Thread
Quetzalcoatl.Dalkiel
サーバ: Quetzalcoatl
Game: FFXI
Posts: 1
By Quetzalcoatl.Dalkiel 2014-10-27 01:11:48
Hi, I just started using Motenten's GS files, and I'm having a hard time getting weaponskillmode to cycle, All of the other binds are working, I've tried switching the binds for weaponskillmode cycling and nothing seems to work as if there is no bind for it at all. and when i hit f12 for user update its always ws mode Normal
I am used to his spellcast scripts where if you put your offensive mode to acc, your weaponskill would be in acc mode aslo.
Anyone know what might be wrong?
By Xavierr 2014-10-27 01:54:35
yay Flippant :D
thankyou so much for this. My GS is now functioning exactly as I wanted it to.
Quetzalcoatl.Orestes
サーバ: Quetzalcoatl
Game: FFXI
Posts: 430
By Quetzalcoatl.Orestes 2014-10-27 09:14:00
this wont work idk: Code hands={"Xaddi Gauntlets",augments={"Accuracy+15"}}
this samlua has this built into the code, not sure if it works beccause i dont have acc+8 ontronif but i tried use the same idea to change xaddi gauntlets based on acc differentiator between the two pairs I have but it won't work, any ideas for me to try?
Code legs={"Otronif Brais +1",augments={"Accuracy +8"}} You have to type the augments exactly how they're written on your gear.
It looks like you don't have a space between Accuracy and +15.
This is a more complicated example. Note the augments are typed exactly how they are in game. If there's double quotes around a stat, then you have to wrap single quotes around it, and include them as well.
Code
back={name="Takaha Mantle", augments={'STR+3','"Store TP"+2','"Zanshin"+3'}},
Quetzalcoatl.Orestes
サーバ: Quetzalcoatl
Game: FFXI
Posts: 430
By Quetzalcoatl.Orestes 2014-10-27 09:19:28
Quetzalcoatl.Dalkiel said: »Hi, I just started using Motenten's GS files, and I'm having a hard time getting weaponskillmode to cycle, All of the other binds are working, I've tried switching the binds for weaponskillmode cycling and nothing seems to work as if there is no bind for it at all. and when i hit f12 for user update its always ws mode Normal
I am used to his spellcast scripts where if you put your offensive mode to acc, your weaponskill would be in acc mode aslo.
Anyone know what might be wrong?
Mote's gearswap's work exactly like that. If you specify your WeaponskillMode's with identical toggles as your OffenseModes, then they will be used without having to cycle WS modes.
for example. Code
state.OffenseMode:options('Normal', 'Mid', 'Acc')
state.WeaponskillMode:options('Normal', 'Mid', 'Acc')
Using sam + fudo as an example..
If you hit F9, and toggle Mid offense mode, you should be able to use //gs showswaps and see that sets.precast.WS['Tachi: Fudo'].Mid is used.
サーバ: Siren
Game: FFXI
Posts: 507
By Siren.Inuyushi 2014-10-27 11:09:00
what would i use to swap; say, the pre-determened augment armor (paths ABC), what would the code look like to have those different pieces swapping how one needs? is my question as best as I can ask. tough sometimes hehe
any help;) /bow /salute All~
The simplest way to get what you want would to equip the augmented gear, and then type //gs export currentset. The exported set will be in addons/Gearswap/data/export. Open up the file and set what the equipment says.
Does anyone know how to get equipment to change automatically when your hpp or mpp goes above a certain percentage? Like 95%?
Quetzalcoatl.Orestes
サーバ: Quetzalcoatl
Game: FFXI
Posts: 430
By Quetzalcoatl.Orestes 2014-10-27 13:37:50
Does anyone know how to get equipment to change automatically when your hpp or mpp goes above a certain percentage? Like 95%?
As I mentioned before, it's not possible. Gearswap has a lot of "events" that when triggered, allow the user to perform arbitrary actions, but your HP changing is not one of them.
You can check your HP
- when your status changes. idle engaged resting, etc.
- when you gain/lose a buff
- before/during/after using abilities, spells, weaponskills
- when you press a button (custom, or F12)
I should probably have said, it's not possible "within reason", as I'm sure somebody could think of some way to hack this in by filtering the chat log, etc. but that honestly sounds like overkill.
You could check in precast or customize_idle_sets / customize_melee_sets, and job_update() to reach a satisfactory result.
サーバ: Siren
Game: FFXI
Posts: 507
By Siren.Inuyushi 2014-10-27 20:11:33
Ah ok, got it. Just good to know. I didn't know if it could or not.
Thanks!
Ragnarok.Flippant
サーバ: Ragnarok
Game: FFXI
Posts: 660
By Ragnarok.Flippant 2014-10-28 04:58:37
While Gearswap has functions that it calls itself based on Windower events, you can also register your own Windower events. You can view various events here:
http://dev.windower.net/doku.php?id=lua:api:events:start
Example (would be added anywhere outside of other functions in your lua file and will be called every time your hpp changes):
Code windower.register_event('hpp change', function(new, old)
if player.hpp >= 95 then
do something
end
end)
Seems largely unnecessary to me, but yes, it can be done.
Ragnarok.Flippant
サーバ: Ragnarok
Game: FFXI
Posts: 660
By Ragnarok.Flippant 2014-10-29 01:32:25
Not sure I understand exactly D:
spell.interrupted refers to the current spell passed to the function, not to a condition of the player, so it's never going to have valid use aside from in aftercast function (a spell can't already have been interrupted during precast). The final condition in your code also makes little sense to me (why do you want to equip your status gear during precast if you're not midaction?)
Are you saying...
1. Start casting Reraise
2. Equip Reraise precast
3. Equip Reraise midcast
4. Start casting Cure, spell is canceled during precast
5. Finish casting Reraise in Reraise midcast, but you don't go back to your status gear
or
1. Start casting Reraise
2. Equip Reraise precast
3. Equip Reraise midcast
4. Start casting Cure, spell is canceled during precast, but gear still equipped
5. Finish casting Reraise in Cure midcast
Either way, I can't reproduce any such issue using just Code if midaction() then cancel_spell() return end
in precast, but I also don't use Mote's files. If you can be more specific as to the actions that are happening, I could take a closer look.
By wick 2014-10-29 06:40:02
hello,
I have a problem that happens occasionally where as brd when i JA songs, it will sometimes not equip my duration gear for a random song, usually if i sing a song fast after JA's. Could this be just a lag issue or is there someone who could check my lua too see if its a bit dodgy? Thanks a lot in advance!
Code -------------------------------------------------------------------------------------------------------------------
-- Initialization function that defines sets and variables to be used.
-------------------------------------------------------------------------------------------------------------------
town_zones = S{"Ru'Lude Gardens","Upper Jeuno","Lower Jeuno","Port Jeuno",
"Western Adoulin","Eastern Adoulin","Aht Urhgan Whitegate","Al Zahbi","Nashmau",
"Port Windhurst","Windhurst Walls", "Windhurst Woods", "Windhurst Waters",
"Port Bastok", "Bastok Mines", "Bastok Markets", "Metalworks",
"Northern San d'Oria", "Southern San d'Oria","Port San d'Oria"}
FakeSongs = S{"Dark Carol II", "Lightning Carol II", "Fire Carol II", "Wind Carol II", "Water Carol II",'Warding Round',"Army's Paeon", "Army's Paeon II","Army's Paeon III","Army's Paeon IV","Army's Paeon V","Army's Paeon VI",'Herb Pastoral','Goblin Gavotte'}
SongIndex = 1
SongArray = {"Gjallarhorn","Daurdabla"}
send_command('bind f9 gs c Instrument')
send_command('bind f11 gs c Lock')
send_command('bind f12 gs c Unlock')
function get_sets()
--DarkRing = {name="Dark Ring",augments={"Physical Damage Taken -6%", "Magical Damage Taken -3%", "Spell Interruption Rate Down 5%"}}
--rightDarkRing = {name="Dark Ring",augments={"Physical Damage Taken -5%", "Magical Damage Taken -3%"}}
--------------------------------------
-- Start defining the sets
--------------------------------------
sets.Gjallarhorn = {range="Gjallarhorn"}
sets.Daurdabla = {range="Daurdabla"}
-- Idle sets
sets.idle =
{main="Izhiikoh", sub="Genbu's shield",
head="Bihu roundlet +1",neck="Twilight torque",ear1="Gifted earring", ear2="Loquac. earring",
body="Artsieq jubbah",hands="Bihu cuffs +1",ring1="Sangoma ring",ring2="Sheltered ring",
back="Mecisto. Mantle",waist="Fucho-no-obi",legs="Bihu cannions +1",feet="Aoidos' Cothurnes +2"}
sets.town = set_combine(sets.idle,
{main="Izhiikoh", sub="Genbu's shield"})
-- Sets to return to when not performing an action.
-- Resting sets
sets.resting = set_combine(sets.idle,
{main="Boonwell staff",
body="Gendewitha bilaut +1", hands="Serpentes cuffs",
legs="Nares Trews",feet="Chelona Boots"})
-- Defense sets (not used, only base sets, or macro activated)
sets.defense =
{main="Terra's staff", sub="Oneiros Grip",
head="Gendewitha caubeen +1",neck="Twilight torque",ear1="Merman's Earring",ear2="Sanare earring",
body="Gendewitha bilaut +1",hands="Gendewitha Gages +1",ring1="dark Ring",ring2="defending Ring",
back="shadow mantle", waist="slipor sash", legs="Gendewitha Spats", feet="Gendewitha galoshes +1"}
sets.Kiting = set_combine(sets.defense,
{main="Terra's staff", sub="Oneiros Grip",
legs="Gendewitha Spats", feet="Aoidos' Cothurnes +2"})
-- Precast Sets
sets.fastcast = set_combine(sets.defense,
{head="Nahtirah Hat",neck="orunmila's torque",ear2="Loquac. Earring",
body="Anhur robe",hands="Gendewitha Gages",ring1="Prolix Ring",ring2="Veneficium ring",
back="Swith Cape +1", waist="Witful belt",legs="Artsieq hose",feet="Chelona Boots +1"})
sets.songcast = set_combine(sets.defense,
{main="Felibre's Dague", sub="Genbu's shield",
head="Aoidos' Calot +2",neck="Orunmila's torque",ear1="Aoidos' Earring",ear2="Loquac. Earring",
body="Sha'ir manteel",hands="Gendewitha Gages",ring1="Prolix Ring",
back="Swith Cape +1", waist="Aoidos' belt", legs="Gendewitha Spats +1",feet="Bihu Slippers +1"})
sets.songcast.thunder = set_combine(sets.songcast,{main="Apamajas I", sub="Vivid strap"})
sets.songcast.fire = set_combine(sets.songcast,{main="Atar I", sub="Vivid strap"})
sets.songcast.light = set_combine(sets.songcast,{main="Arka I", sub="Vivid strap"})
sets.curecast = set_combine(sets.fastcast,
{main="Apaisante", sub="Genbu's shield",body="Heka's Kalasiris", back="Pahtli cape", waist="Acerbic sash +1"})
sets.enhancecast = set_combine(sets.fastcast,
{waist="Siegel Sash"})
sets.nincast = set_combine(sets.fastcast, {})
-- Precast sets to enhance JAs
sets.Nightingale = {feet="Bihu Slippers +1"}
sets.Troubadour = {body="Bihu justaucorps"}
sets.SoulVoice = {legs="Bihu Cannions +1"}
-- Waltz set (chr and vit)
sets.Waltz = set_combine(sets.defense,
{range="Gjallarhorn",
head="Nahtirah Hat",
body="Gendewitha bilaut +1",
back="Refraction Cape",legs="Gendewitha Spats",feet="Gendewitha Galoshes +1"})
-- Weaponskill sets
-- Default set for any weaponskill that isn't any more specifically defined
sets.WS =
{range="Gjallarhorn",
head="Nahtirah Hat",neck="Asperity Necklace",ear1="Bladeborn Earring",ear2="Steelflash Earring",
body="Bard's Justaucorps +2",hands="Gendewitha Gages +1",ring1="Rajas Ring",
back="Atheling Mantle",waist="Caudata Belt",legs="Gendewitha Spats",feet="Gendewitha Galoshes +1"}
sets.WS.Evisceration = set_combine(sets.WS, {})
sets.WS.Exent = set_combine(sets.WS, {})
-- Midcast Sets
-- General set for recast times.
sets.FastRecast = set_combine(sets.defense,
{head="Nahtirah Hat",neck="Orunmila's Torque", ear2="Loquacious Earring",
body="Bihu justaucorps",hands="Gendewitha Gages +1",ring1="Prolix Ring",
back="Swith Cape +1",waist="Phasmida belt",legs="Artsieq hose",feet="Gendewitha Galoshes +1"})
-- Song-specific recast reduction
sets.SongRecast = set_combine(sets.FastRecast, {})
sets.FakeSong = set_combine(sets.SongCast, {range="Daurdabla"})
-- Buff Song midcasts
sets.SongEffect = set_combine(sets.defense, {main="Legato Dagger", sub="Genbu's shield",
head="Aoidos' Calot +2",neck="Aoidos' Matinee",ear2="Loquacious Earring",
body="Aoidos' Hongreline +2",hands="Aoidos' Manchettes +2",ring1="Prolix Ring",
legs="Mdk. shalwar +1",feet="Brioso Slippers +1"})
sets.SongEffect.Ballad = set_combine(sets.SongEffect,
{legs="Aoidos' Rhing. +2"})
sets.SongEffect.Mazurka = set_combine(sets.SongEffect,
{range="Daurdabla"})
sets.SongEffect.Madrigal = set_combine(sets.SongEffect,
{head="Aoidos' Calot +2"})
sets.SongEffect.March = set_combine(sets.SongEffect,
{hands="Aoidos' manchettes +2"})
sets.SongEffect.Minuet = set_combine(sets.SongEffect,
{body="Aoidos' Hongreline +2"})
sets.SongEffect.Minne = set_combine(sets.SongEffect,{})
sets.SongEffect.Scherzo = set_combine(sets.SongEffect,{feet="Aoidos' Cothrn. +2"})
sets.SongEffect.Paeon = set_combine(sets.SongEffect,
{head="Brioso Roundlet +1"})
-- song Debuffs midcasts
sets.SongDebuff =
{main="Lehbrailg +2", sub="Mephitis grip", range="Gjallarhorn",
head="Bihu Roundlet +1", neck="Nuna gorget +1", ear1="Gwati earring", ear2="Enchntr. Earring +1",
body="Brioso justaucorps +1",hands="Bihu cuffs +1", ring1="Carb. Ring +1", ring2="Carb. Ring +1",
back="Kumbira Cape", waist="Demonry sash", legs="Bihu Cannions +1", feet="Artsieq boots"}
sets.SongDebuff.Finale = set_combine(sets.SongDebuff)
sets.SongDebuff.Foelullaby = set_combine(sets.SongDebuff,
{hands="Brioso Cuffs +1"})
sets.SongDebuff.Hordelullaby = set_combine(sets.SongDebuff,
{range="Daurdabla", hands="Brioso Cuffs"})
-- Magic midcasts.
sets.Cure = set_combine(sets.FastRecast, {
main="Arka IV",sub='Verse strap +1',
head="Paean Mitra", neck="Colossus's torque", ear1="Psystorm Earring",ear2="Lifestorm Earring",
body="Heka's Kalasiris",hands="Bokwus Gloves", ring1="Ephedra Ring", ring2="Sirona's Ring",
back="Tempered cape +1",legs="Bihu cannions +1", feet="Rubeus boots"})
sets.Stoneskin = set_combine(sets.defense,{
waist="Siegel sash", legs="Shedir seraweels"})
sets.EnhancingMagic = set_combine(sets.defense,{
legs="Shedir seraweels"})
sets.EnfeeblingMagic =
{main="Izhiikoh", sub="Genbu's shield", range="Gjallarhorn",
head="Nahtirah hat", neck="Weike torque", ear1="Psystorm Earring", ear2="Lifestorm Earring",
body="Brioso justaucorps +1", hands="Lurid Mitts", ring1="Sangoma ring", ring2="Maquette ring",
back="Refraction Cape", waist="Demonry sash", legs="Bihu Cannions +1", feet="Artsieq boots"}
sets.Cursna = set_combine(sets.FastRecast,
{ring1="Ephedra Ring", feet="Gende. Galoshes"})
-- Engaged sets
sets.engaged = set_combine(sets.defense,
{range="Gjallarhorn",
head="Gendewitha caubeen +1", neck="Asperity necklace", ear1="Bladeborn Earring",ear2="Steelflash Earring",
body="Bihu justaucorps", hands="Gendewitha Gages +1", ring1="Rajas Ring",
back="Atheling mantle", waist="Phasmida belt",legs="Gendewitha Spats",feet="Gendewitha Galoshes +1"})
-- Sets with weapons defined.
sets.engaged.Dagger = set_combine(sets.engaged,
{main="Vanir Knife", sub="Genbu's shield"})
sets.engaged.DW = set_combine(sets.engaged,
{main="Vanir Knife", sub="Izhiikoh"})
sets.Gearcollector =
{item="Remedy", item2="Echo Drops"}
end
-------------------------------------------------------------------------------------------------------------------
-- Precast Rules
-------------------------------------------------------------------------------------------------------------------
function precast(spell)
if spell.action_type == 'Magic' then
if spell.type == 'BardSong' then
-- Auto-Pianissimo
if spell.target.type == 'PLAYER' and not spell.target.charmed and not buffactive['Pianissimo'] then
cancel_spell()
send_command('@input /ja "Pianissimo" <me>; wait 1.25; input /ma "'..spell.name..'" '..spell.target.name)
return
elseif spell.english:find('March') or spell.english:find('Madrigal')then
equip(sets.songcast.thunder)
elseif buffactive ['Nightingale'] then
elseif spell.english:find('Minuet') or spell.english:find('Pinning Nocturne')then
equip(sets.songcast.fire)
elseif buffactive ['Nightingale'] then
elseif spell.english:find('Ballad') or spell.english:find('Paeon')or spell.english:find('Requiem')or spell.english:find('Lullaby')then
equip(sets.songcast.light)
elseif buffactive ['Nightingale'] then
elseif buffactive['Nightingale'] then
if spell.target.type == 'SELF' or spell.target.type == 'PLAYER' then
equip(sets[SongArray[SongIndex]])
add_to_chat(206,'Nightingale on')
if spell.english:find('Ballad') then
equip(sets.SongEffect)
elseif spell.english:find('Madrigal') then
equip(sets.SongEffect.Madrigal)
elseif spell.english:find('March') then
equip(sets.SongEffect.March)
elseif spell.english:find('Minuet') then
equip(sets.SongEffect.Minuet)
elseif spell.english:find('Minne') then
equip(sets.SongEffect.Minne)
elseif spell.english:find('Scherzo') then
equip(sets.SongEffect.Scherzo)
elseif FakeSongs:contains(spell.name) then
equip(sets.FakeSong)
add_to_chat(206,'Fake song')
else
equip(sets.SongEffect)
end
elseif spell.target.type == 'MONSTER' then
if spell.english:find('Foe Lullaby') then
equip(sets.SongDebuff.Foelullaby)
elseif spell.english:find('Horde Lullaby') then
equip(sets.SongDebuff.Hordelullaby)
elseif spell.english:find('Finale') then
equip(sets.SongDebuff.Finale)
else
equip(sets.SongDebuff)
end
end
else
equip(sets.songcast)
end
elseif spell.skill == 'Healing Magic' then
if spell.english:find('Cure') or spell.english:find('Cura')then
equip(sets.curecast)
else
equip(sets.fastcast)
end
elseif spell.skill == 'Enhancing Magic' then
equip(sets.enhancecast)
elseif spell.skill == 'Ninjutsu' then
equip(sets.nincast)
else
equip(sets.fastcast)
end
elseif spell.type == 'JobAbility' then
if spell.english == 'Nightingale' then
equip(sets.Nightingale)
elseif spell.english == 'Troubadour' then
equip(sets.Troubadour)
elseif spell.english == 'Soul Voice' then
equip(sets.SoulVoice)
end
elseif spell.type == 'WeaponSkill' then
equip(sets.WS)
end
end
-------------------------------------------------------------------------------------------------------------------
-- Midcast Rules
-------------------------------------------------------------------------------------------------------------------
function midcast(spell)
if spell.skill == 'Singing' then
if spell.target.type == 'SELF' or spell.target.type == 'PLAYER' then
equip(sets[SongArray[SongIndex]])
add_to_chat(206,'Intrument: '..SongArray[SongIndex])
SongIndex = 1
if spell.english:find('Ballad') then
equip(sets.SongEffect)
elseif spell.english:find('Madrigal') then
equip(sets.SongEffect.Madrigal)
elseif spell.english:find('Mazurka') then
equip(sets.SongEffect.Mazurka)
elseif spell.english:find('March') then
equip(sets.SongEffect.March)
elseif spell.english:find('Minuet') then
equip(sets.SongEffect.Minuet)
elseif spell.english:find('Minne') then
equip(sets.SongEffect.Minne)
elseif spell.english:find('Scherzo') then
equip(sets.SongEffect.Scherzo)
elseif FakeSongs:contains(spell.name) then
equip(sets.FakeSong)
add_to_chat(206,'Fake song')
else
equip(sets.SongEffect)
end
elseif spell.target.type == 'MONSTER' then
if spell.english:find('Foe Lullaby') then
equip(sets.SongDebuff.Foelullaby)
elseif spell.english:find('Horde Lullaby') then
equip(sets.SongDebuff.Hordelullaby)
elseif spell.english:find('Finale') then
equip(sets.SongDebuff.Finale)
else
equip(sets.SongDebuff)
end
end
elseif spell.skill == 'Healing Magic' then
if spell.english:find('Cure') or spell.english:find('Cura')then
equip(sets.Cure)
elseif spell.english:find('Cursna') then
equip(sets.Cursna)
else
equip(sets.FastRecast)
end
elseif spell.skill == 'Enhancing Magic' then
if spell.english:find('Bar') or spell.english:find('Boost') or spell.english:find('Protect') or spell.english:find('Shell') then
equip(sets.EnhancingMagic)
elseif spell.english:find('Stoneskin') or spell.english:find('Aquaveil')then
equip(sets.Stoneskin)
else
equip(sets.FastRecast)
end
elseif spell.skill == 'Enfeebling Magic' then
equip(sets.SongDebuff)
else
equip(sets.FastRecast)
end
end
-------------------------------------------------------------------------------------------------------------------
-- Aftercast Rules
-------------------------------------------------------------------------------------------------------------------
function aftercast(spell)
if player.status == 'Engaged' then
if player.sub_job == 'DNC' or player.sub_job == 'NIN'then
equip(sets.engaged.DW)
else
equip(sets.engaged.Dagger)
end
elseif player.status == 'Idle' then
if town_zones:contains(world.area) then
equip(sets.town)
else
equip(sets.idle)
end
end
end
function status_change(new,old)
if new == 'Engaged' then
if player.sub_job == 'DNC' or player.sub_job == 'NIN'then
equip(sets.engaged.DW)
else
equip(sets.engaged.Dagger)
end
elseif new == 'Idle' then
equip(sets.idle)
elseif new == 'Resting' then
equip(sets.resting)
end
end
function calculate_duration(name)
local mult = 1
if player.equipment.main == "Carnwenhan" then mult = mult + 0.5 end
if player.equipment.range == 'Daurdabla' then mult = mult + 0.3 end
if player.equipment.range == "Gjallarhorn" then mult = mult + 0.4 end
if player.equipment.neck == "Aoidos' Matinee" then mult = mult + 0.1 end
if player.equipment.body == "Aoidos' Hngrln. +2" then mult = mult + 0.1 end
if player.equipment.legs == "Mdk. Shalwar +1" then mult = mult + 0.1 end
if player.equipment.feet == "Brioso Slippers +1" then mult = mult + 0.11 end
if string.find(name,'Paeon') and player.equipment.head == 'Brioso Roundlet +1' then mult = mult + 0.1 end
if string.find(name,'March') and player.equipment.hands == 'Ad. Mnchtte. +2' then mult = mult + 0.1 end
if string.find(name,'Minuet') and player.equipment.body == "Aoidos' Hngrln. +2" then mult = mult + 0.1 end
if string.find(name,'Madrigal') and player.equipment.head == "Aoidos' Calot +2" then mult = mult + 0.1 end
if string.find(name,'Ballad') and player.equipment.legs == "Aoidos' Rhing. +2" then mult = mult + 0.1 end
if string.find(name,'Scherzo') and player.equipment.feet == "Aoidos' Cothrn. +2" then mult = mult + 0.1 end
if buffactive.Troubadour then
mult = mult*2
end
if string.find(name,'Scherzo') then
if buffactive['Soul Voice'] then
mult = mult*2
elseif buffactive['marcato'] then
mult = mult*1.5
end
end
mult = mult - 0.05
local totalDuration = mult*120
return totalDuration
end
function self_command(command)
if command == 'Lock' then
disable('main','sub')
add_to_chat(206,'Weapons locked')
elseif command == 'Unlock' then
enable('main','sub')
add_to_chat(206,'Weapons unlocked')
elseif command == 'Instrument' then -- Instrument Toggle --
SongIndex = (SongIndex % #SongArray) + 1
add_to_chat(206,'Next song instrument: '..SongArray[SongIndex])
status_change(player.status)
end
end
サーバ: Siren
Game: FFXI
Posts: 228
By Siren.Noxzema 2014-11-03 10:14:25
So I'm starting my switch from SC to GS, using Motes mnk.lua. I'm running into a snag when using trying to use emp body for Impetus, I have it switch when I have HF and Imp up, but not when it is just Impetus.
Basically I'd like to have it locked when I have the fodder/normal sets on, but off for the SomeAcc/ACC sets. I've been googling, but I'm not seeing anything about it. So I'm not sure if I'm just missing something, or if I broke something while entering my gear.
サーバ: Fenrir
Game: FFXI
Posts: 183
By Fenrir.Brimstonefox 2014-11-04 18:52:52
I'm completely flummoxed, I'm using Mote's v2 files, I was trying to create a variable to switch my weapon (and it works fine) however I can't get it to actually switch the weapon. My modifications to the pick_tp_weapon function (there is an similar example in the brd.lua):
Code function pick_tp_weapon()
add_to_chat(122,' pick tp weapon '..state.WeaponMode.value)
-- if staffs:contains(player.equipment.main) then
-- state.CombatWeapon:set('Staff')
-- end
-- if polearms:contains(player.equipment.main) then
-- state.CombatWeapon:set('Polearm')
-- end
if state.WeaponMode.value == 'Polearm' then
state.CombatWeapon:set('Polearm')
end
if state.WeaponMode.value == 'Staff' then
state.CombatWeapon:set('Staff')
end
add_to_chat(123, 'combat weapon set to '..state.CombatWeapon.value)
end
Now the commented out code works fine, so long as I manually switch my weapon. The active code is not working and I'm not sure why, WeaponMode is set correctly as I can see it echo when the function runs. The error I'm getting is: attempt to call method 'set' (a nil value) What's driving me bonkers is its referencing the state.CombatWeapon:set('Staff') line but that code works fine if I use the staffs:contains(player.equipment.main) if instead of the state.WeaponMode.value == 'Staff' if, which makes no sense to me.
Any ideas?
Quetzalcoatl.Orestes
サーバ: Quetzalcoatl
Game: FFXI
Posts: 430
By Quetzalcoatl.Orestes 2014-11-05 12:01:05
Fenrir.Brimstonefox said: »I'm completely flummoxed, I'm using Mote's v2 files, I was trying to create a variable to switch my weapon (and it works fine) however I can't get it to actually switch the weapon. My modifications to the pick_tp_weapon function (there is an similar example in the brd.lua):
Code function pick_tp_weapon()
add_to_chat(122,' pick tp weapon '..state.WeaponMode.value)
-- if staffs:contains(player.equipment.main) then
-- state.CombatWeapon:set('Staff')
-- end
-- if polearms:contains(player.equipment.main) then
-- state.CombatWeapon:set('Polearm')
-- end
if state.WeaponMode.value == 'Polearm' then
state.CombatWeapon:set('Polearm')
end
if state.WeaponMode.value == 'Staff' then
state.CombatWeapon:set('Staff')
end
add_to_chat(123, 'combat weapon set to '..state.CombatWeapon.value)
end
Now the commented out code works fine, so long as I manually switch my weapon. The active code is not working and I'm not sure why, WeaponMode is set correctly as I can see it echo when the function runs. The error I'm getting is: attempt to call method 'set' (a nil value) What's driving me bonkers is its referencing the state.CombatWeapon:set('Staff') line but that code works fine if I use the staffs:contains(player.equipment.main) if instead of the state.WeaponMode.value == 'Staff' if, which makes no sense to me.
Any ideas?
It's pretty difficult to help you without knowing where you're actually calling this function, and what state.WeaponMode looks like.
I'm also a little confused by this usage scenario. You need a default state, and don't seem to have one specified. I'm going to assume 'Polearm' is what you normally gear for, and the only real toggle you need here is for Staff. If that doesn't make sense, think about what setting CombatWeapon does. It allows you to build a set, in addition to your normal set. For example, your normal set is sets.engaged = {} You want to equip a Staff, so you need sets.engaged.Staff = {}. Just make sure you put a polearm in your regular set. Unless there's a third usage scenario you didn't mention, that should be all that's necessary.
This is how you would do this:
You would need this in job_setup()
Code
function job_setup()
state.WeaponMode = M{['description']='Weapon Mode', 'Normal', 'Staff'}
pick_tp_weapon()
end
Put it in job_update, so you can hit F12 and have it re-evaluate anytime you want. Code
function job_update(cmdParams, eventArgs)
pick_tp_weapon()
end
Add the following to job_state_change. Code
function job_state_change(stateField, newValue, oldValue)
if stateField == 'Weapon Mode' then
if newValue == 'Staff' then
state.CombatWeapon:set('Staff')
else
state.CombatWeapon:reset()
end
end
end
And finally, your function
Code
function pick_tp_weapon()
add_to_chat(122,' pick tp weapon '..state.WeaponMode.value)
if state.WeaponMode.value == 'Staff' then
state.CombatWeapon:set('Staff')
else
state.CombatWeapon:reset()
end
add_to_chat(123, 'combat weapon set to '..state.CombatWeapon.value)
end
Either use a macro, or type //gs c cycle WeaponMode
サーバ: Fenrir
Game: FFXI
Posts: 183
By Fenrir.Brimstonefox 2014-11-05 15:28:04
The format of the rest of the file is similar to say this:
https://github.com/Kinematics/GearSwap-Jobs/blob/master/BRD.lua
I believe its called in job_update (sorry I'm at work now and don't have the file).
The idea for weaponMode was to create a variable to control CombatWeapon with (can I control it directly?).
I have a list of weapon types in weapon mode I wanted to cycle through, I can do that, and sets.engaged.Staff (or whatever) has main="my favorite staff" in it already.
Maybe the problem is my definition of weaponmode, I defined it as a list (probably not the correct lua term), but that doesn't explain why it echos the proper value, and points to the state.CombatWeapon:set('Staff') as being the problem, when it works fine in a slightly different conditional. I can try to strip down the lua file some and post the whole thing if you think that would help.
サーバ: Fenrir
Game: FFXI
Posts: 183
By Fenrir.Brimstonefox 2014-11-05 19:57:32
Here's the full file, works fine until I hit cntl-` it says it changes to Staff (weaponMode) but won't set combatweapon from it, I tried setting combatweapon directly and it doesn't work.
Code -------------------------------------------------------------------------------------------------------------------
-- Initialization function that defines sets and variables to be used.
-------------------------------------------------------------------------------------------------------------------
-- IMPORTANT: Make sure to also get the Mote-Include.lua file (and its supplementary files) to go with this.
-- Initialization function for this job file.
function get_sets()
mote_include_version = 2
-- Load and initialize the include file.
include('Mote-Include.lua')
end
-- Setup vars that are user-independent.
function job_setup()
-- state.CombatForm = get_combat_form()
state.Buff = {}
end
-- Setup vars that are user-dependent. Can override this function in a sidecar file.
function user_setup()
-- add_to_chat(122,'user setup')
-- Options: Override default values
state.OffenseMode:options('Normal', 'Acc', 'Att', 'Crit', 'DA', 'Haste', 'Skill', 'sTP', 'STR')
state.HybridMode:options('Normal', 'PDT', 'Reraise')
state.WeaponskillMode:options('Normal', 'Acc', 'Att', 'Mod')
state.CastingMode:options('Normal')
state.IdleMode:options('Normal')
state.RestingMode:options('Normal')
state.PhysicalDefenseMode:options('PDT', 'Reraise')
state.MagicalDefenseMode:options('MDT')
-- state.WeaponMode:options('Polearm', 'Staff', 'Club', 'Dagger', 'Sword')
state.WeaponMode = M{['description']='Weapon Mode', 'Polearm', 'Staff', 'Club', 'Dagger', 'Sword'}
-- state.WeaponMode:set('Polearm')
polearms = S{'Gungnir'}
staffs = S{'Chatoyant Staff'}
-- Additional local binds
--send_command('bind ^` input /ja "Hasso" <me>')
--send_command('bind !` input /ja "Seigan" <me>')
send_command('bind ^` gs c cycle WeaponMode')
select_default_macro_book()
end
-- Called when this job file is unloaded (eg: job change)
function file_unload()
if binds_on_unload then
binds_on_unload()
end
send_command('unbind ^`')
send_command('unbind !-')
end
-- Define sets and vars used by this job file.
function init_gear_sets()
add_to_chat(122,'init gear sets')
--------------------------------------
-- Start defining the sets
--------------------------------------
-- Sets to return to when not performing an action.
-- Idle sets
sets.idle = {head="Twilight Helm",neck="Twilight Torque",ear1="Ethereal Earring",ear2="Moonshade Earring",
body="Twlight Mail",hands="Buremte Gloves",ring1="Rajas Ring",ring2="Ulthalam's Ring",
back="Updraft Mantle",waist="Zoran's Belt",legs="Crimson Cuisses",feet="Ejekamal Boots"}
-- Idle sets (default idle set not needed since the other three are defined, but leaving for testing purposes)
sets.idle.Town = set_combine(sets.idle, {})
sets.idle.Field = set_combine(sets.idle, {})
sets.idle.Weak = set_combine(sets.idle, {})
-- Resting sets
sets.resting = set_combine(sets.idle, {})
-- Engaged sets
-- Variations for TP weapon and (optional) offense/defense modes. Code will fall back on previous
-- sets if more refined versions aren't defined.
-- If you create a set with both offense and defense modes, the offense mode should be first.
-- EG: sets.engaged.Dagger.Accuracy.Evasion
-- Normal melee group
sets.engaged = {ammo="Potestas Bomblet",
head="Yaoyotl Helm",neck="Ganesha's Mala",ear1="Bladeborn Earring",ear2="Steelflash Earring",
body="Vishap Mail",hands="Miki. Gauntlets",ring1="Rajas Ring",ring2="K'ayres Ring",
back="Atheling Mantle",waist="Zoran's Belt",legs="Phorcys Dirs",feet="Ejekamal Boots"}
sets.engaged.Polearm = {}
sets.engaged.Staff = {}
-- Basic Mode definitions
sets.Mode = {}
sets.Mode.Acc = set_combine(sets.engaged, {ammo="Potestas Bomblet",
head="Ares' Mask",neck="Agasaya's Collar",ear1="Bladeborn Earring",ear2="Steelflash Earring",
body="Vishap Mail",hands="Miki. Gauntlets",ring1="Rajas Ring",ring2="Ulthalam's Ring",
back="Atheling Mantle",waist="Nu Sash",legs="Lncr. Cuissots +2",feet="Wym. Greaves +2"})
sets.engaged.Polearm = set_combine(sets.engaged, {main="Gungnir", sub="Pole Grip",ammo="Potestas Bomblet"})
sets.engaged.Polearm.Refresh = set_combine(sets.engaged, {ear1="Ethereal Earring",ear2="Brutal Earring",
body="Ares' Cuirass"})
sets.engaged.Polearm.Acc = set_combine(sets.engaged.Polearm, sets.Mode.Acc)
sets.engaged.Staff = set_combine(sets.engaged, {main="Chatoyant Staff",
ear2="Terminus Earring",
ring2="Prouesse Ring"})
sets.engaged.Staff.Acc = set_combine(sets.engaged.Staff, sets.Mode.Acc)
sets.engaged.Reraise = set_combine(sets.engaged,{
head="Twilight Helm",
body="Twilight Mail"})
end
-------------------------------------------------------------------------------------------------------------------
-- Job-specific hooks that are called to process player actions at specific points in time.
-------------------------------------------------------------------------------------------------------------------
-- Modify the default idle set after it was constructed.
function customize_idle_set(idleSet)
return idleSet
end
-- Modify the default melee set after it was constructed.
function customize_melee_set(meleeSet)
return meleeSet
end
-------------------------------------------------------------------------------------------------------------------
-- Customization hooks for idle and melee sets, after they've been automatically constructed.
-------------------------------------------------------------------------------------------------------------------
-- Called before the Include starts constructing melee/idle/resting sets.
-- Can customize state or custom melee class values at this point.
-- Set eventArgs.handled to true if we don't want any automatic gear equipping to be done.
function job_handle_equipping_gear(status, eventArgs)
add_to_chat(122,'handle equiping gear')
pick_tp_weapon()
end
-- Modify the default idle set after it was constructed.
function customize_idle_set(idleSet)
add_to_chat(122,'customize idle set')
return idleSet
end
-- Modify the default melee set after it was constructed.
function customize_melee_set(meleeSet)
add_to_chat(122,'customize melee set')
return meleeSet
end
-------------------------------------------------------------------------------------------------------------------
-- General hooks for other events.
-------------------------------------------------------------------------------------------------------------------
-- Called when a player gains or loses a buff.
-- buff == buff gained or lost
-- gain == true if the buff was gained, false if it was lost.
function job_buff_change(buff, gain)
determine_groups()
end
-------------------------------------------------------------------------------------------------------------------
-- User code that supplements self-commands.
-------------------------------------------------------------------------------------------------------------------
-- Called by the 'update' self-command, for common needs.
-- Set eventArgs.handled to true if we don't want automatic equipping of gear.
function job_update(cmdParams, eventArgs)
classes.CustomMeleeGroups:clear()
if areas.Adoulin:contains(world.area) and buffactive.ionis then
classes.CustomMeleeGroups:append('Adoulin')
end
if areas.Assault:contains(world.area) then
classes.CustomMeleeGroups:append('Assault')
end
state.CombatWeapon = player.equipment.main
end
-------------------------------------------------------------------------------------------------------------------
-- Utility functions specific to this job.
-------------------------------------------------------------------------------------------------------------------
function determine_groups()
-- add_to_chat(122,' determine groups')
classes.CustomMeleeGroups:clear()
-- If sub job has MP then set refresh groups for refresh gear
if jobs.MP:contains(player.sub_job) then
-- add_to_chat(122,' using refresh because SJ: '..player.sub_job)
classes.CustomMeleeGroups:append('Refresh')
end
end
-- Select default macro book on initial load or subjob change.
function select_default_macro_book()
-- Default macro set/book
if player.sub_job == 'WAR' then
set_macro_page(2, 1)
elseif player.sub_job == 'NIN' then
set_macro_page(4, 1)
elseif player.sub_job == 'SAM' then
set_macro_page(1, 1)
elseif player.sub_job == 'WHM' then
set_macro_page(3, 1)
else
set_macro_page(1, 1)
end
end
-- Examine equipment to determine what our current TP weapon is.
function pick_tp_weapon()
add_to_chat(122,' pick tp weapon '..state.WeaponMode.value)
-- if staffs:contains(player.equipment.main) then
-- state.CombatWeapon:set('Staff')
-- end
-- if polearms:contains(player.equipment.main) then
-- state.CombatWeapon:set('Polearm')
-- end
if state.WeaponMode.value == 'Polearm' then
state.CombatWeapon:set('Polearm')
end
if state.WeaponMode.value == 'Staff' then
state.CombatWeapon:set('Staff')
end
add_to_chat(123, 'combat weapon set to '..state.CombatWeapon.value)
end
Quetzalcoatl.Orestes
サーバ: Quetzalcoatl
Game: FFXI
Posts: 430
By Quetzalcoatl.Orestes 2014-11-05 20:31:07
Fenrir.Brimstonefox said: »Here's the full file, works fine until I hit cntl-` it says it changes to Staff (weaponMode) but won't set combatweapon from it, I tried setting combatweapon directly and it doesn't work.
Code -------------------------------------------------------------------------------------------------------------------
-- Initialization function that defines sets and variables to be used.
-------------------------------------------------------------------------------------------------------------------
-- IMPORTANT: Make sure to also get the Mote-Include.lua file (and its supplementary files) to go with this.
-- Initialization function for this job file.
function get_sets()
mote_include_version = 2
-- Load and initialize the include file.
include('Mote-Include.lua')
end
-- Setup vars that are user-independent.
function job_setup()
-- state.CombatForm = get_combat_form()
state.Buff = {}
end
-- Setup vars that are user-dependent. Can override this function in a sidecar file.
function user_setup()
-- add_to_chat(122,'user setup')
-- Options: Override default values
state.OffenseMode:options('Normal', 'Acc', 'Att', 'Crit', 'DA', 'Haste', 'Skill', 'sTP', 'STR')
state.HybridMode:options('Normal', 'PDT', 'Reraise')
state.WeaponskillMode:options('Normal', 'Acc', 'Att', 'Mod')
state.CastingMode:options('Normal')
state.IdleMode:options('Normal')
state.RestingMode:options('Normal')
state.PhysicalDefenseMode:options('PDT', 'Reraise')
state.MagicalDefenseMode:options('MDT')
-- state.WeaponMode:options('Polearm', 'Staff', 'Club', 'Dagger', 'Sword')
state.WeaponMode = M{['description']='Weapon Mode', 'Polearm', 'Staff', 'Club', 'Dagger', 'Sword'}
-- state.WeaponMode:set('Polearm')
polearms = S{'Gungnir'}
staffs = S{'Chatoyant Staff'}
-- Additional local binds
--send_command('bind ^` input /ja "Hasso" <me>')
--send_command('bind !` input /ja "Seigan" <me>')
send_command('bind ^` gs c cycle WeaponMode')
select_default_macro_book()
end
-- Called when this job file is unloaded (eg: job change)
function file_unload()
if binds_on_unload then
binds_on_unload()
end
send_command('unbind ^`')
send_command('unbind !-')
end
-- Define sets and vars used by this job file.
function init_gear_sets()
add_to_chat(122,'init gear sets')
--------------------------------------
-- Start defining the sets
--------------------------------------
-- Sets to return to when not performing an action.
-- Idle sets
sets.idle = {head="Twilight Helm",neck="Twilight Torque",ear1="Ethereal Earring",ear2="Moonshade Earring",
body="Twlight Mail",hands="Buremte Gloves",ring1="Rajas Ring",ring2="Ulthalam's Ring",
back="Updraft Mantle",waist="Zoran's Belt",legs="Crimson Cuisses",feet="Ejekamal Boots"}
-- Idle sets (default idle set not needed since the other three are defined, but leaving for testing purposes)
sets.idle.Town = set_combine(sets.idle, {})
sets.idle.Field = set_combine(sets.idle, {})
sets.idle.Weak = set_combine(sets.idle, {})
-- Resting sets
sets.resting = set_combine(sets.idle, {})
-- Engaged sets
-- Variations for TP weapon and (optional) offense/defense modes. Code will fall back on previous
-- sets if more refined versions aren't defined.
-- If you create a set with both offense and defense modes, the offense mode should be first.
-- EG: sets.engaged.Dagger.Accuracy.Evasion
-- Normal melee group
sets.engaged = {ammo="Potestas Bomblet",
head="Yaoyotl Helm",neck="Ganesha's Mala",ear1="Bladeborn Earring",ear2="Steelflash Earring",
body="Vishap Mail",hands="Miki. Gauntlets",ring1="Rajas Ring",ring2="K'ayres Ring",
back="Atheling Mantle",waist="Zoran's Belt",legs="Phorcys Dirs",feet="Ejekamal Boots"}
sets.engaged.Polearm = {}
sets.engaged.Staff = {}
-- Basic Mode definitions
sets.Mode = {}
sets.Mode.Acc = set_combine(sets.engaged, {ammo="Potestas Bomblet",
head="Ares' Mask",neck="Agasaya's Collar",ear1="Bladeborn Earring",ear2="Steelflash Earring",
body="Vishap Mail",hands="Miki. Gauntlets",ring1="Rajas Ring",ring2="Ulthalam's Ring",
back="Atheling Mantle",waist="Nu Sash",legs="Lncr. Cuissots +2",feet="Wym. Greaves +2"})
sets.engaged.Polearm = set_combine(sets.engaged, {main="Gungnir", sub="Pole Grip",ammo="Potestas Bomblet"})
sets.engaged.Polearm.Refresh = set_combine(sets.engaged, {ear1="Ethereal Earring",ear2="Brutal Earring",
body="Ares' Cuirass"})
sets.engaged.Polearm.Acc = set_combine(sets.engaged.Polearm, sets.Mode.Acc)
sets.engaged.Staff = set_combine(sets.engaged, {main="Chatoyant Staff",
ear2="Terminus Earring",
ring2="Prouesse Ring"})
sets.engaged.Staff.Acc = set_combine(sets.engaged.Staff, sets.Mode.Acc)
sets.engaged.Reraise = set_combine(sets.engaged,{
head="Twilight Helm",
body="Twilight Mail"})
end
-------------------------------------------------------------------------------------------------------------------
-- Job-specific hooks that are called to process player actions at specific points in time.
-------------------------------------------------------------------------------------------------------------------
-- Modify the default idle set after it was constructed.
function customize_idle_set(idleSet)
return idleSet
end
-- Modify the default melee set after it was constructed.
function customize_melee_set(meleeSet)
return meleeSet
end
-------------------------------------------------------------------------------------------------------------------
-- Customization hooks for idle and melee sets, after they've been automatically constructed.
-------------------------------------------------------------------------------------------------------------------
-- Called before the Include starts constructing melee/idle/resting sets.
-- Can customize state or custom melee class values at this point.
-- Set eventArgs.handled to true if we don't want any automatic gear equipping to be done.
function job_handle_equipping_gear(status, eventArgs)
add_to_chat(122,'handle equiping gear')
pick_tp_weapon()
end
-- Modify the default idle set after it was constructed.
function customize_idle_set(idleSet)
add_to_chat(122,'customize idle set')
return idleSet
end
-- Modify the default melee set after it was constructed.
function customize_melee_set(meleeSet)
add_to_chat(122,'customize melee set')
return meleeSet
end
-------------------------------------------------------------------------------------------------------------------
-- General hooks for other events.
-------------------------------------------------------------------------------------------------------------------
-- Called when a player gains or loses a buff.
-- buff == buff gained or lost
-- gain == true if the buff was gained, false if it was lost.
function job_buff_change(buff, gain)
determine_groups()
end
-------------------------------------------------------------------------------------------------------------------
-- User code that supplements self-commands.
-------------------------------------------------------------------------------------------------------------------
-- Called by the 'update' self-command, for common needs.
-- Set eventArgs.handled to true if we don't want automatic equipping of gear.
function job_update(cmdParams, eventArgs)
classes.CustomMeleeGroups:clear()
if areas.Adoulin:contains(world.area) and buffactive.ionis then
classes.CustomMeleeGroups:append('Adoulin')
end
if areas.Assault:contains(world.area) then
classes.CustomMeleeGroups:append('Assault')
end
state.CombatWeapon = player.equipment.main
end
-------------------------------------------------------------------------------------------------------------------
-- Utility functions specific to this job.
-------------------------------------------------------------------------------------------------------------------
function determine_groups()
-- add_to_chat(122,' determine groups')
classes.CustomMeleeGroups:clear()
-- If sub job has MP then set refresh groups for refresh gear
if jobs.MP:contains(player.sub_job) then
-- add_to_chat(122,' using refresh because SJ: '..player.sub_job)
classes.CustomMeleeGroups:append('Refresh')
end
end
-- Select default macro book on initial load or subjob change.
function select_default_macro_book()
-- Default macro set/book
if player.sub_job == 'WAR' then
set_macro_page(2, 1)
elseif player.sub_job == 'NIN' then
set_macro_page(4, 1)
elseif player.sub_job == 'SAM' then
set_macro_page(1, 1)
elseif player.sub_job == 'WHM' then
set_macro_page(3, 1)
else
set_macro_page(1, 1)
end
end
-- Examine equipment to determine what our current TP weapon is.
function pick_tp_weapon()
add_to_chat(122,' pick tp weapon '..state.WeaponMode.value)
-- if staffs:contains(player.equipment.main) then
-- state.CombatWeapon:set('Staff')
-- end
-- if polearms:contains(player.equipment.main) then
-- state.CombatWeapon:set('Polearm')
-- end
if state.WeaponMode.value == 'Polearm' then
state.CombatWeapon:set('Polearm')
end
if state.WeaponMode.value == 'Staff' then
state.CombatWeapon:set('Staff')
end
add_to_chat(123, 'combat weapon set to '..state.CombatWeapon.value)
end Check the examples I posted. You have to state.CombatWeapon:reset(), and call job_state_change().
I would do something like this, since you have more than a few weapons. i.e. Add "Normal", and test it like so.. Code
state.WeaponMode = M{['description']='Weapon Mode', 'Normal', 'Polearm', 'Staff', 'Club', 'Dagger', 'Sword'}
function job_state_change(stateField, newValue, oldValue)
if stateField == 'Weapon Mode' then
if newValue ~= 'Normal' then
state.CombatWeapon:set(newValue)
else
state.CombatWeapon:reset()
end
end
end
You should be able to do something similar in pick_tp_weapon()
サーバ: Fenrir
Game: FFXI
Posts: 183
By Fenrir.Brimstonefox 2014-11-06 19:07:48
Ok Fantastic thank you its working now.
Siren.Kenesu
サーバ: Siren
Game: FFXI
Posts: 150
By Siren.Kenesu 2014-11-06 21:34:49
I just came back to the game after a break and need some help getting started with gearswap. anyone have vent that could walk me though it. much appreciated.
サーバ: Phoenix
Game: FFXI
Posts: 661
By Phoenix.Demonjustin 2014-11-06 21:54:43
Ok, I'm getting an issue with my gear swap. The line says it's actually an issue with Mote-Include line 879 when it comes to Aftercast. My gear isn't swapping to midcast or idle at all.
Code -------------------------------------------------------------------------------------------------------------------
-- Setup functions for this job. Generally should not be modified.
-------------------------------------------------------------------------------------------------------------------
-- Initialization function for this job file.
function get_sets()
mote_include_version = 2
-- Load and initialize the include file.
include('Mote-Include.lua')
end
-- Setup vars that are user-independent. state.Buff vars initialized here will automatically be tracked.
function job_setup()
state.Buff.Saboteur = buffactive.saboteur or false
end
-------------------------------------------------------------------------------------------------------------------
-- User setup functions for this job. Recommend that these be overridden in a sidecar file.
-------------------------------------------------------------------------------------------------------------------
-- Setup vars that are user-dependent. Can override this function in a sidecar file.
function user_setup()
state.CombatModes:options('Frontline', 'Backline')
state.OffenseModes:options('Normal', 'Acc', 'TH')
state.DefenseModes:options('Normal', 'DT')
state.WeaponskillModes:options('Normal', 'Acc', 'TH')
state.CastingModes:options('Normal', 'Acc', 'TH')
state.IdleModes:options('Normal')
state.RestingModes:options('Normal')
state.PhysicalDefenseModes:options('PDT', 'RefreshPDT')
state.MagicalDefenseModes:options('MDT')
select_default_macro_book()
state.Defense.PhysicalMode = 'PDT'
state.CombatForm = nil
if player.sub_job == 'NIN' or player.sub_job == 'DNC' then
state.CombatForm = 'DW'
else
state.CombatForm = nil
end
if S{'WAR', 'THF', 'PLD', 'DRK', 'BST', 'RNG', 'SAM', 'NIN', 'BLU', 'DNC', 'RUN'}:contains(player.sub_job) then
state.CombatMode = 'Frontline'
else
state.CombatMode = 'Backline'
end
EnhancingSpells = S{'Haste', 'Haste', 'Invisible', 'Sneak', 'Regen', 'Regen II', 'Refresh', 'Refresh II', 'Sandstorm', 'Rainstorm', 'Windstorm', 'Firestorm', 'Hailstorm', 'Klimaform'}
MNDPotencySpells = S{'Paralyze', 'Paralyze II', 'Slow', 'Slow II', 'Addle'}
INTAccuracySpells = S{'Sleep', 'Sleep II', 'Sleepga', 'Sleepga II', 'Break', 'Breakga', 'Bind', 'Dispel', 'Gravity', 'Gravity II'}
IceSpells = S{'Blizzard', 'Blizzard II', 'Blizzard III', 'Blizzard IV', 'Blizzard V', 'Blizzaga', 'Blizzaga II', 'Blizzaga III', 'Blizzaja', 'Blizzara', 'Blizzara II', 'Cryohelix'}
send_command('unbind !f11; wait 0.1; bind !f11 gs c cycle CombatMode')
HMAtk = {name="Hagondes Cuffs +1",augments={'Phys. dmg. taken -3%','Magic dmg. taken -3%','"Mag.Atk.Bns."+21',}}
HMAcc = {name="Hagondes Cuffs +1",augments={'Phys. dmg. taken -3%','Mag. Acc.+26',}}
end
-- Define sets and vars used by this job file.
function init_gear_sets()
--------------------------------------
-- Start defining the sets
--------------------------------------
-- Precast Sets
-- Precast sets to enhance JAs
sets.precast.JA['Chainspell'] = {body="Vitivation Tabard"}
-- Waltz set (chr and vit)
sets.precast.Waltz = {main="Excalibur",sub="Buramenk'ah",ammo="Impatiens",
head="Atro. Chapeau +1",neck="Twilight Torque",ear1="Brutal Earring",ear2="Ethereal Earring",
body="Atrophy Tabard +1",hands="Viti. Gloves +1",ring1="Aqua Ring",ring2="Asklepian Ring",
back="Swith Cape",waist="Fucho-no-obi",legs="Atrophy Tights +1",feet="Vitivation Boots +1"}
-- Fast cast sets for spells
-- 80% Fast Cast (including trait) for all spells, plus 5% quick cast
-- No other FC sets necessary.
sets.precast.FC = {main="Shikargar",sub="Genbu's Shield",ammo="Impatiens",
head="Atro. Chapeau +1",neck="Orunmila's Torque",ear1="Estq. Earring",ear2="Ethereal Earring",
body="Vitivation Tabard",hands="Gende. Gages +1",ring1="Prolix Ring",ring2="Shadow Ring",
back="Swith Cape",waist="Witful Belt",legs="Artsieq Hose",feet="Battlecast Gaiters"}
sets.precast.FC.Impact = set_combine(sets.precast.FC, {head=empty,body="Twilight Cloak"})
-- Weaponskill sets
-- Default set for any weaponskill that isn't any more specifically defined
sets.precast.WS = {ammo="Cheruski Needle",
head="Lithelimb Cap",neck="Asperity Necklace",ear1="Bladeborn Earring",ear2="Steelflash Earring",
body="Karmesin Vest",hands="Umuthi Gloves",ring1="Aqua Ring",ring2="Rajas Ring",
back="Atheling Mantle",waist="Wanion Belt",legs="Osmium Cuisses",feet="Battlecast Gaiters"}
sets.precast.WS.Acc = {ammo="Jukukik Feather",
head="Sukeroku Hachi.",neck="Iqabi Necklace",ear1="Bladeborn Earring",ear2="Steelflash Earring",
body="Atrophy Tabard +1",hands="Viti. Gloves +1",ring1="Aqua Ring",ring2="Rajas Ring",
back="Letalis Mantle",waist="Wanion Belt",legs="Atrophy Tights +1",feet="Battlecast Gaiters"}
sets.precast.WS.DaytimeAcc = set_combine(sets.precast.WS.Acc, {ammo="Tengu-no-Hane"})
sets.precast.WS.TH= {ammo="Cheruski Needle",
head="Sukeroku Hachi.",neck="Asperity Necklace",ear1="Bladeborn Earring",ear2="Steelflash Earring",
body="Atrophy Tabard +1",hands="Viti. Gloves +1",ring1="Aqua Ring",ring2="Rajas Ring",
back="Letalis Mantle",waist="Tarutaru Sash",legs="Atrophy Tights +1",feet="Vitivation Boots +1"}
-- Specific weaponskill sets. Uses the base set if an appropriate WSMod version isn't found.
sets.precast.WS['Requiescat'] = {ammo="Oreiad's Tathlum",
head="Viti. Chapeau +1",neck="Soil Gorget",ear1="Bladeborn Earring",ear2="Steelflash Earring",
body="Atrophy Tabard +1",hands="Viti. Gloves +1",ring1="Aqua Ring",ring2="Rajas Ring",
back="Atheling Mantle",waist="Soil Belt",legs="Atrophy Tights +1",feet="Vitivation Boots +1"}
sets.precast.WS['Requiescat'].Acc = {ammo="Jukukik Feather",
head="Sukeroku Hachi.",neck="Soil Gorget",ear1="Bladeborn Earring",ear2="Steelflash Earring",
body="Atrophy Tabard +1",hands="Viti. Gloves +1",ring1="Aqua Ring",ring2="Rajas Ring",
back="Letalis Mantle",waist="Soil Belt",legs="Atrophy Tights +1",feet="Battlecast Gaiters"}
sets.precast.WS['Requiescat'].DaytimeAcc = set_combine(sets.precast.WS['Requiescat'].Acc, {ammo="Tengu-no-Hane"})
sets.precast.WS['Knights of Round'] = {ammo="Cheruski Needle",
head="Atro. Chapeau +1",neck="Asperity Necklace",ear1="Bladeborn Earring",ear2="Steelflash Earring",
body="Atrophy Tabard +1",hands="Viti. Gloves +1",ring1="Aqua Ring",ring2="Rajas Ring",
back="Atheling Mantle",waist="Celt Belt",legs="Atrophy Tights +1",feet="Vitivation Boots +1"}
sets.precast.WS['Knights of Round'].Acc = {ammo="Jukukik Feather",
head="Sukeroku Hachi.",neck="Iqabi Necklace",ear1="Bladeborn Earring",ear2="Steelflash Earring",
body="Atrophy Tabard +1",hands="Viti. Gloves +1",ring1="Aqua Ring",ring2="Rajas Ring",
back="Letalis Mantle",waist="Celt Belt",legs="Atrophy Tights +1",feet="Battlecast Gaiters"}
sets.precast.WS['Knights of Round'].DaytimeAcc = set_combine(sets.precast.WS['Knights of Round'].Acc, {ammo="Tengu-no-Hane"})
sets.precast.WS['Death Blossom'] = {ammo="Cheruski Needle",
head="Viti. Chapeau +1",neck="Asperity Necklace",ear1="Bladeborn Earring",ear2="Steelflash Earring",
body="Atrophy Tabard +1",hands="Viti. Gloves +1",ring1="Aqua Ring",ring2="Rajas Ring",
back="Atheling Mantle",waist="Celt Belt",legs="Atrophy Tights +1",feet="Vitivation Boots +1"}
sets.precast.WS['Death Blossom'].Acc = {ammo="Jukukik Feather",
head="Sukeroku Hachi.",neck="Iqabi Necklace",ear1="Bladeborn Earring",ear2="Steelflash Earring",
body="Atrophy Tabard +1",hands="Viti. Gloves +1",ring1="Aqua Ring",ring2="Rajas Ring",
back="Letalis Mantle",waist="Celt Belt",legs="Atrophy Tights +1",feet="Battlecast Gaiters"}
sets.precast.WS['Death Blossom'].DaytimeAcc = set_combine(sets.precast.WS['Death Blossom'].Acc, {ammo="Tengu-no-Hane"})
sets.precast.WS['Chant du Cygne'] = {ammo="Yetshila",
head="Lithelimb Cap",neck="Asperity Necklace",ear1="Bladeborn Earring",ear2="Steelflash Earring",
body="Karmesin Vest",hands="Umuthi Gloves",ring1="Thundersoul Ring",ring2="Rajas Ring",
back="Atheling Mantle",waist="Wanion Belt",legs="Osmium Cuisses",feet="Vanir Boots"}
sets.precast.WS['Chant du Cygne'].Acc = {ammo="Jukukik Feather",
head="Sukeroku Hachi.",neck="Iqabi Necklace",ear1="Bladeborn Earring",ear2="Steelflash Earring",
body="Karmesin Vest",hands="Umuthi Gloves",ring1="Thundersoul Ring",ring2="Rajas Ring",
back="Letalis Mantle",waist="Wanion Belt",legs="Osmium Cuisses",feet="Battlecast Gaiters"}
sets.precast.WS['Chant du Cygne'].DaytimeAcc = set_combine(sets.precast.WS['Chant du Cygne'].Acc, {ammo="Tengu-no-Hane"})
-- Midcast Sets
sets.midcast.FastRecast = {main="Twebuliij",sub="Mephitis Grip",ammo="Impatiens",
head="Atro. Chapeau +1",neck="Orunmila's Torque",ear1="Estq. Earring",ear2="Ethereal Earring",
body="Vitivation Tabard",hands="Umuthi Gloves",ring1="Prolix Ring",ring2="Shadow Ring",
back="Swith Cape",waist="Pya'ekue Belt",legs="Artsieq Hose",feet="Battlecast Gaiters"}
sets.midcast.FrontlineCure = {main="Excalibur",sub="Buramenk'ah",ammo="Oreiad's Tathlum",
head="Gende. Caubeen +1",neck="Phalaina Locket",ear1="Estq. Earring",ear2="Ethereal Earring",
body="Heka's Kalasiris",hands="Bokwus Gloves",ring1="Prolix Ring",ring2="Asklepian Ring",
back="Pahtli Cape",waist="Pya'ekue Belt",legs="Atrophy Tights +1",feet="Estq. Houseaux +2"}
sets.midcast.BacklineCure = {main="Tamaxchi",sub="Genbu's Shield",ammo="Oreiad's Tathlum",
head="Gende. Caubeen +1",neck="Orunmila's Torque",ear1="Estq. Earring",ear2="Novia Earring",
body="Heka's Kalasiris",hands="Gende. Gages +1",ring1="Prolix Ring",ring2="Sirona's Ring",
back="Pahtli Cape",waist="Pya'ekue Belt",legs="Atrophy Tights +1",feet="Estq. Houseaux +2"}
sets.midcast['Enhancing Magic'] = {main="Bolelabunga",sub="Genbu's Shield",ammo="Impatiens",
head="Umuthi Hat",neck="Colossus's Torque",ear1="Estq. Earring",ear2="Andoaa Earring",
body="Vitivation Tabard",hands="Atrophy Gloves +1",ring1="Prolix Ring",ring2="Defending Ring",
back="Estoqueur's Cape",waist="Pya'ekue Belt",legs="Atrophy Tights +1",feet="Estq. Houseaux +2"}
sets.midcast.Enhancing = {main="Twebuliij",sub="Mephitis Grip",ammo="Impatiens",
head="Estoqueur's Chappel +2",neck="Orunmila's Torque",ear1="Estq. Earring",ear2="Ethereal Earring",
body="Estoqueur's Sayon +2",hands="Atrophy Gloves +1",ring1="Prolix Ring",ring2="Defending Ring",
back="Estoqueur's Cape",waist="Pya'ekue Belt",legs="Estoqueur's Fuseau +2",feet="Estoqueur's Houseaux +2"}
sets.midcast.Refresh = set_combine(sets.midcast.Enhancing, {legs="Estoqueur's Fuseau +2"})
sets.midcast.Stoneskin = {neck="Stone Gorget",ear2="Earthcry Earring",waist="Siegel Sash",legs="Shedir Seraweels"}
sets.midcast.Aquaveil = set_combine(sets.midcast['Enhancing Magic'], {waist="Emphatikos Rope",legs="Shedir Seraweels"})
sets.midcast['Enfeebling Magic'] = {main="Twebuliij",sub="Mephitis Grip",ammo="Kalboron Stone",
head="Viti. Chapeau +1",neck="Weike Torque",ear1="Lifestorm Earring",ear2="Psystorm Earring",
body="Atrophy Tabard +1",hands=HMAcc,ring1="Sangoma Ring",ring2="Perception Ring",
back="Refraction Cape",waist="Demonry Sash",legs="Artsieq Hose",feet="Vitivation Boots +1"}
sets.midcast['Dia III'] = {head="Viti. Chapeau +1"}
sets.midcast['Diaga'] = set_combine(sets.midcast.EnfeeblingMagic, {waist="Tarutaru Sash"})
sets.midcast.MNDPotency = {main="Twebuliij",sub="Mephitis Grip",ammo="Oreiad's Tathlum",
head="Viti. Chapeau +1",neck="Phalaina Locket",ear1="Lifestorm Earring",ear2="Psystorm Earring",
body="Estoqueur's Sayon +2",hands=HMAcc,ring1="Aqua Ring",ring2="Sirona's Ring",
back="Refraction Cape",waist="Demonry Sash",legs="Artsieq Hose",feet="Uk'uxkaj Boots"}
sets.midcast.MNDPotency.Acc = set_combine(sets.midcast.MNDAccuracy, {body="Estoqueur's Sayon +2",feet="Uk'uxkaj Boots"})
sets.midcast.MNDAccuracy = {main="Twebuliij",sub="Mephitis Grip",ammo="Kalboron Stone",
head="Viti. Chapeau +1",neck="Weike Torque",ear1="Lifestorm Earring",ear2="Psystorm Earring",
body="Artsieq Jubbah",hands=HMAcc,ring1="Sangoma Ring",ring2="Perception Ring",
back="Refraction Cape",waist="Demonry Sash",legs="Artsieq Hose",feet="Vitivation Boots +1"}
sets.midcast.INTPotency = {main="Twebuliij",sub="Mephitis Grip",ammo="Oreiad's Tathlum",
head="Atro. Chapeau +1",neck="Weike Torque",ear1="Lifestorm Earring",ear2="Psystorm Earring",
body="Estoqueur's Sayon +2",hands=HMAcc,ring1="Spiral Ring",ring2="Diamond Ring",
back="Refraction Cape",waist="Wanion Belt",legs="Artsieq Hose",feet="Uk'uxkaj Boots"}
sets.midcast.INTPotency.Acc = set_combine(sets.midcast.INTAccuracy, {body="Estoqueur's Sayon +2",feet="Uk'uxkaj Boots"})
sets.midcast.INTAccuracy = {main="Twebuliij",sub="Mephitis Grip",ammo="Impatiens",
head="Atro. Chapeau +1",neck="Orunmila's Torque",ear1="Estq. Earring",ear2="Ethereal Earring",
body="Artsieq Jubbah",hands="Gende. Gages +1",ring1="Prolix Ring",ring2="Perception Ring",
back="Swith Cape",waist="Witful Belt",legs="Artsieq Hose",feet="Vitivation Boots +1"}
sets.midcast['ElementalEnfeeble'] = {main="Twebuliij",sub="Mephitis Grip",ammo="Kalboron Stone",
head="Atro. Chapeau +1",neck="Weike Torque",ear1="Lifestorm Earring",ear2="Psystorm Earring",
body="Artsieq Jubbah",hands=HMAcc,ring1="Sangoma Ring",ring2="Perception Ring",
back="Refraction Cape",waist="Wanion Belt",legs="Artsieq Hose",feet="Vitivation Boots +1"}
sets.midcast['Elemental Magic'] = {main="Lehbrailg +2",sub="Mephitis Grip",ammo="Witchstone",
head="Hagondes Hat +1",neck="Eddy Necklace",ear1="Friomisi Earring",ear2="Crematio Earring",
body="Seidr Cotehardie",hands=HMAtk,ring1="Acumen Ring",ring2="Diamond Ring",
back="Refraction Cape",waist="Sekhmet Corset",legs="Hagondes Pants +1",feet="Umbani Boots"}
sets.midcast['Elemental Magic'].Acc = {main="Lehbrailg +2",sub="Mephitis Grip",ammo="Kalboron Stone",
head="Atro. Chapeau +1",neck="Imbodla Necklace",ear1="Lifestorm Earring",ear2="Psystorm Earring",
body="Artsieq Jubbah",hands=HMAtk,ring1="Sangoma Ring",ring2="Diamond Ring",
back="Refraction Cape",waist="Wanion Belt",legs="Hagondes Pants +1",feet="Vitivation Boots +1"}
sets.midcast['Elemental Magic'].TH = {main="Lehbrailg +2",sub="Mephitis Grip",ammo="Witchstone",
head="Hagondes Hat +1",neck="Eddy Necklace",ear1="Friomisi Earring",ear2="Crematio Earring",
body="Seidr Cotehardie",hands=HMAtk,ring1="Acumen Ring",ring2="Diamond Ring",
back="Refraction Cape",waist="Tarutaru Sash",legs="Hagondes Pants +1",feet="Umbani Boots"}
sets.midcast.Blizzard = set_combine(sets.midcast['Elemental Magic'], {main="Ngqoqwanb"})
sets.midcast.Blizzard.Acc = set_combine(sets.midcast['Elemental Magic'].Acc, {main="Ngqoqwanb"})
sets.midcast.Blizzard.TH = set_combine(sets.midcast['Elemental Magic'].TH, {main="Ngqoqwanb"})
sets.midcast.Impact = set_combine(sets.midcast['ElementalEnfeeble'], {head=empty,body="Twilight Cloak"})
sets.midcast['Dark Magic'] = {main="Twebuliij",sub="Mephitis Grip",ammo="Kalboron Stone",
head="Viti. Chapeau +1",neck="Weike Torque",ear1="Lifestorm Earring",ear2="Psystorm Earring",
body="Atrophy Tabard +1",hands=HMAcc,ring1="Sangoma Ring",ring2="Diamond Ring",
back="Refraction Cape",waist="Wanion Belt",legs="Artsieq Hose",feet="Vitivation Boots +1"}
sets.midcast.Stun = {main="Twebuliij",sub="Mephitis Grip",ammo="Impatiens",
head="Atro. Chapeau +1",neck="Orunmila's Torque",ear1="Estq. Earring",ear2="Ethereal Earring",
body="Vitivation Tabard",hands="Gende. Gages +1",ring1="Prolix Ring",ring2="Diamond Ring",
back="Swith Cape",waist="Witful Belt",legs="Artsieq Hose",feet="Battlecast Gaiters"}
--sets.midcast.Stun = set_combine(sets.midcast.DarkMagic, {})
--sets.midcast.Drain = set_combine(sets.midcast.DarkMagic, {ring2="Excelsis Ring"})
--sets.midcast.Aspir = sets.midcast.Drain
-- Sets for special buff conditions on spells.
sets.midcast.EnhancingDuration = {hands="Atrophy Gloves +1",back="Estoqueur's Cape",feet="Estoqueur's Houseaux +2"}
sets.buff.ComposureOther = {head="Estoqueur's Chappel +2",
body="Estoqueur's Sayon +2",hands="Atrophy Gloves +1",
back="Estoqueur's Cape",legs="Estoqueur's Fuseau +2",feet="Estoqueur's Houseaux +2"}
sets.buff.Saboteur = {hands="Estoqueur's Gantherots +2"}
-- Sets to return to when not performing an action.
-- Resting sets
sets.resting = {main="Bolelabunga",sub="Genbu's Shield",ammo="Impatiens",
head="Viti. Chapeau +1",neck="Twilight Torque",ear1="Novia Earring",ear2="Ethereal Earring",
body="Atrophy Tabard +1",hands="Serpentes Cuffs",ring1="Defending Ring",ring2="Shadow Ring",
back="Shadow Mantle",waist="Fucho-no-obi",legs="Nares Trews",feet="Serpentes Sabots"}
-- Idle sets (default idle set not needed since the other three are defined, but leaving for testing purposes)
sets.idle.Town = {main="Bolelabunga",sub="Genbu's Shield",ammo="Impatiens",
head="Viti. Chapeau +1",neck="Twilight Torque",ear1="Novia Earring",ear2="Ethereal Earring",
body="Atrophy Tabard +1",hands="Serpentes Cuffs",ring1="Defending Ring",ring2="Shadow Ring",
back="Kumbira Cape",waist="Fucho-no-obi",legs="Nares Trews",feet="Serpentes Sabots"}
sets.idle.Field = {main="Bolelabunga",sub="Genbu's Shield",ammo="Impatiens",
head="Viti. Chapeau +1",neck="Twilight Torque",ear1="Novia Earring",ear2="Ethereal Earring",
body="Atrophy Tabard +1",hands="Serpentes Cuffs",ring1="Defending Ring",ring2="Shadow Ring",
back="Kumbira Cape",waist="Fucho-no-obi",legs="Nares Trews",feet="Serpentes Sabots"}
sets.idle.Weak = {main="Bolelabunga",sub="Genbu's Shield",ammo="Impatiens",
head="Viti. Chapeau +1",neck="Twilight Torque",ear1="Novia Earring",ear2="Ethereal Earring",
body="Atrophy Tabard +1",hands="Serpentes Cuffs",ring1="Defending Ring",ring2="Shadow Ring",
back="Kumbira Cape",waist="Fucho-no-obi",legs="Nares Trews",feet="Serpentes Sabots"}
-- Defense sets
sets.defense.PDT = {main="Shikargar",sub="Genbu's Shield",ammo="Impatiens",
head="Lithelimb Cap",neck="Twilight Torque",ear1="Brutal Earring",ear2="Ethereal Earring",
body="Karmesin Vest",hands="Umuthi Gloves",ring1="Defending Ring",ring2="K'ayres Ring",
back="Shadow Mantle",waist="Fucho-no-obi",legs="Osmium Cuisses",feet="Battlecast Gaiters"}
sets.defense.RefreshPDT = {main="Shikargar",sub="Genbu's Shield",ammo="Impatiens",
head="Viti. Chapeau +1",neck="Twilight Torque",ear1="Brutal Earring",ear2="Ethereal Earring",
body="Atrophy Tabard +1",hands="Umuthi Gloves",ring1="Defending Ring",ring2="K'ayres Ring",
back="Shadow Mantle",waist="Fucho-no-obi",legs="Osmium Cuisses",feet="Battlecast Gaiters"}
sets.defense.MDT = {main="Shikargar",sub="Genbu's Shield",ammo="Impatiens",
head="Atrophy Chapeau +1",neck="Twilight Torque",ear1="Novia Earring",ear2="Ethereal Earring",
body="Atrophy Tabard +1",hands="Vitivation Gloves +1",ring1="Defending Ring",ring2="Shadow Ring",
back="Refraction Cape",waist="Wanion Belt",legs="Atrophy Tights +1",feet="Umbani Boots"}
-- Engaged sets
-- Variations for TP weapon and (optional) offense/defense modes. Code will fall back on previous
-- sets if more refined versions aren't defined.
-- If you create a set with both offense and defense modes, the offense mode should be first.
-- EG: sets.engaged.Dagger.Accuracy.Evasion
-- Normal melee group
sets.engaged = {main="Excalibur", sub="Genbu's Shield",ammo="Paeapua",
head="Lithelimb Cap",neck="Asperity Necklace",ear1="Bladeborn Earring",ear2="Steelflash Earring",
body="Karmesin Vest",hands="Umuthi Gloves",ring1="K'ayres Ring",ring2="Rajas Ring",
back="Atheling Mantle",waist="Shetal Stone",legs="Osmium Cuisses",feet="Battlecast Gaiters"}
sets.engaged.Acc = {main="Excalibur", sub="Genbu's Shield",ammo="Jukukik Feather",
head="Lithelimb Cap",neck="Iqabi Necklace",ear1="Bladeborn Earring",ear2="Steelflash Earring",
body="Karmesin Vest",hands="Umuthi Gloves",ring1="K'ayres Ring",ring2="Rajas Ring",
back="Letalis Mantle",waist="Shetal Stone",legs="Osmium Cuisses",feet="Battlecast Gaiters"}
sets.engaged.Acc.Daytime = set_combine(sets.engaged.Acc, {ammo="Tengu-no-Hane"})
sets.engaged.TH = {main="Excalibur", sub="Genbu's Shield",ammo="Paeapua",
head="Lithelimb Cap",neck="Asperity Necklace",ear1="Bladeborn Earring",ear2="Steelflash Earring",
body="Karmesin Vest",hands="Umuthi Gloves",ring1="K'ayres Ring",ring2="Rajas Ring",
back="Atheling Mantle",waist="Tarutaru Sash",legs="Osmium Cuisses",feet="Battlecast Gaiters"}
sets.engaged.DW = set_combine(sets.engaged, {sub="Buramenk'ah",ear1="Brutal Earring",ear2="Suppanomimi"})
sets.engaged.DW.Acc = set_combine(sets.engaged.Acc, {sub="Buramenk'ah",ear1="Brutal Earring",ear2="Suppanomimi"})
sets.engaged.DW.Acc.Daytime = set_combine(sets.engaged.Acc.Daytime, {sub="Buramenk'ah",ear1="Brutal Earring",ear2="Suppanomimi"})
sets.engaged.DW.TH = set_combine(sets.engaged.TH, {sub="Buramenk'ah",ear1="Brutal Earring",ear2="Suppanomimi"})
-- Defensive melee group
sets.engaged.DT = set_combine(sets.engaged, {head="Lithelimb Cap",neck="Twilight Torque",
hands="Umuthi Gloves",ring1="K'ayres Ring",ring2="Defending Ring",legs="Osmium Cuisses",feet="Battlecast Gaiters"})
sets.engaged.Acc.DT = set_combine(sets.engaged.Acc, {head="Lithelimb Cap",neck="Twilight Torque",
hands="Umuthi Gloves",ring1="K'ayres Ring",ring2="Defending Ring",legs="Osmium Cuisses",feet="Battlecast Gaiters"})
sets.engaged.Acc.DT.Daytime = set_combine(sets.engaged.Acc.Daytime, {head="Lithelimb Cap",neck="Twilight Torque",
hands="Umuthi Gloves",ring1="K'ayres Ring",ring2="Defending Ring",legs="Osmium Cuisses",feet="Battlecast Gaiters"})
sets.engaged.TH.DT = set_combine(sets.engaged.TH, {head="Lithelimb Cap",neck="Twilight Torque",
hands="Umuthi Gloves",ring1="K'ayres Ring",ring2="Defending Ring",legs="Osmium Cuisses",feet="Battlecast Gaiters"})
sets.engaged.DW.DT = set_combine(sets.engaged.DW, {head="Lithelimb Cap",neck="Twilight Torque",
hands="Umuthi Gloves",ring1="K'ayres Ring",ring2="Defending Ring",legs="Osmium Cuisses",feet="Battlecast Gaiters"})
sets.engaged.DW.Acc.DT = set_combine(sets.engaged.DW.Acc, {head="Lithelimb Cap",neck="Twilight Torque",
hands="Umuthi Gloves",ring1="K'ayres Ring",ring2="Defending Ring",legs="Osmium Cuisses",feet="Battlecast Gaiters"})
sets.engaged.DW.Acc.DT.Daytime = set_combine(sets.engaged.DW.Acc.Daytime, {head="Lithelimb Cap",neck="Twilight Torque",
hands="Umuthi Gloves",ring1="K'ayres Ring",ring2="Defending Ring",legs="Osmium Cuisses",feet="Battlecast Gaiters"})
sets.engaged.DW.TH.DT = set_combine(sets.engaged.DW.TH, {head="Lithelimb Cap",neck="Twilight Torque",
hands="Umuthi Gloves",ring1="K'ayres Ring",ring2="Defending Ring",legs="Osmium Cuisses",feet="Battlecast Gaiters"})
sets.FrontlineWeapons = {main="Excalibur", sub="Genbu's Shield"}
sets.FrontlineWeapons.DW = {main="Excalibur", sub="Buramenk'ah"}
end
-------------------------------------------------------------------------------------------------------------------
-- Job-specific hooks for standard casting events.
-------------------------------------------------------------------------------------------------------------------
-- Run after the default midcast() is done.
-- eventArgs is the same one used in job_midcast, in case information needs to be persisted.
function job_post_midcast(spell, action, spellMap, eventArgs)
if spell.skill == 'Enfeebling Magic' and state.Buff.Saboteur then
equip(sets.buff.Saboteur)
elseif spell.skill == 'Enhancing Magic' then
if buffactive.composure and spell.target.type == 'PLAYER' then
if spell.english == 'Phalanx II' then
equip(sets.buff.EnhancingDuration)
else
equip(sets.buff.ComposureOther)
end
else
equip(sets.midcast.EnhancingDuration)
end
end
end
-------------------------------------------------------------------------------------------------------------------
-- Job-specific hooks for non-casting events.
-------------------------------------------------------------------------------------------------------------------
-- Handle notifications of general user state change.
function job_state_change(stateField, newValue, oldValue)
if stateField == 'CombatMode' then
if newValue == 'Frontline' then
weapons = sets.FrontlineWeapons[state.CombatForm] or sets.FrontlineWeapons
send_command('wait 0.1; gs disable main sub')
else
enable('main', 'sub')
end
end
end
-------------------------------------------------------------------------------------------------------------------
-- User code that supplements standard library decisions.
-------------------------------------------------------------------------------------------------------------------
-- Modify the default idle set after it was constructed.
function customize_idle_set(idleSet)
if player.mpp < 51 then
idleSet = set_combine(idleSet, sets.latent_refresh)
end
return idleSet
end
-- Set eventArgs.handled to true if we don't want the automatic display to be run.
function display_current_job_state(eventArgs)
display_current_caster_state()
eventArgs.handled = true
end
-------------------------------------------------------------------------------------------------------------------
-- Utility functions specific to this job.
-------------------------------------------------------------------------------------------------------------------
-- Select default macro book on initial load or subjob change.
function select_default_macro_book()
-- Default macro set/book
if player.sub_job == 'BLM' then
set_macro_page(2, 5)
elseif player.sub_job == 'NIN' then
set_macro_page(4, 5)
elseif player.sub_job == 'DNC' then
set_macro_page(5, 5)
elseif player.sub_job == 'DRK' then
set_macro_page(7, 5)
elseif player.sub_job == 'PLD' then
set_macro_page(8, 5)
else
set_macro_page(1, 5)
end
end
This one is the one having the issues. Basically I just copy-pasted most of my stuff from my old one into Motenten's RDM Gearswap to create the new one. So~ if anyone can help me by telling me what I am doing that's breaking my new one and how to fix it, that'd be great. I really would love to be able to play my RDM again. : /
サーバ: Phoenix
Game: FFXI
Posts: 661
By Phoenix.Demonjustin 2014-11-06 21:56:43
My old Gearswap before I updated it to 2.0 was...
Code -------------------------------------------------------------------------------------------------------------------
-- Initialization function that defines sets and variables to be used.
-------------------------------------------------------------------------------------------------------------------
-- IMPORTANT: Make sure to also get the Mote-Include.lua file (and its supplementary files) to go with this.
-- Initialization function for this job file.
function get_sets()
-- Load and initialize the include file.
include('Mote-Include.lua')
end
-- Setup vars that are user-independent.
function job_setup()
state.Buff.Saboteur = buffactive.saboteur or false
event_list = L{}
event_list:append(windower.register_event('time change', time_change))
end
-- Setup vars that are user-dependent. Can override this function in a sidecar file.
function user_setup()
-- Options: Override default values
options.CombatModes = {'Frontline', 'Backline'}
options.OffenseModes = {'Normal', 'Acc', 'TH'}
options.DefenseModes = {'Normal', 'DT'}
options.WeaponskillModes = {'Normal', 'Acc', 'TH'}
options.CastingModes = {'Normal', 'Acc', 'TH'}
options.IdleModes = {'Normal'}
options.RestingModes = {'Normal'}
options.PhysicalDefenseModes = {'PDT', 'RefreshPDT'}
options.MagicalDefenseModes = {'MDT'}
state.Defense.PhysicalMode = 'PDT'
state.CombatForm = nil
if player.sub_job == 'NIN' or player.sub_job == 'DNC' then
state.CombatForm = 'DW'
else
state.CombatForm = nil
end
if S{'WAR', 'THF', 'PLD', 'DRK', 'BST', 'RNG', 'SAM', 'NIN', 'BLU', 'DNC', 'RUN'}:contains(player.sub_job) then
state.CombatMode = 'Frontline'
else
state.CombatMode = 'Backline'
end
EnhancingSpells = S{'Haste', 'Haste', 'Invisible', 'Sneak', 'Regen', 'Regen II', 'Refresh', 'Refresh II', 'Sandstorm', 'Rainstorm', 'Windstorm', 'Firestorm', 'Hailstorm', 'Klimaform'}
MNDPotencySpells = S{'Paralyze', 'Paralyze II', 'Slow', 'Slow II', 'Addle'}
INTAccuracySpells = S{'Sleep', 'Sleep II', 'Sleepga', 'Sleepga II', 'Break', 'Breakga', 'Bind', 'Dispel', 'Gravity', 'Gravity II'}
IceSpells = S{'Blizzard', 'Blizzard II', 'Blizzard III', 'Blizzard IV', 'Blizzard V', 'Blizzaga', 'Blizzaga II', 'Blizzaga III', 'Blizzaja', 'Blizzara', 'Blizzara II', 'Cryohelix'}
send_command('unbind !f11; wait 0.1; bind !f11 gs c cycle CombatMode')
HMAtk = {name="Hagondes Cuffs +1",augments={'Phys. dmg. taken -3%','Magic dmg. taken -3%','"Mag.Atk.Bns."+21',}}
HMAcc = {name="Hagondes Cuffs +1",augments={'Phys. dmg. taken -3%','Mag. Acc.+26',}}
end
-- Called when this job file is unloaded (eg: job change)
function file_unload()
if binds_on_unload then
binds_on_unload()
end
event_list:map(unregister_event)
end
-- Define sets and vars used by this job file.
function init_gear_sets()
--------------------------------------
-- Start defining the sets
--------------------------------------
-- Precast Sets
-- Precast sets to enhance JAs
sets.precast.JA['Chainspell'] = {body="Vitivation Tabard"}
-- Waltz set (chr and vit)
sets.precast.Waltz = {main="Excalibur",sub="Buramenk'ah",ammo="Impatiens",
head="Atro. Chapeau +1",neck="Twilight Torque",ear1="Brutal Earring",ear2="Ethereal Earring",
body="Atrophy Tabard +1",hands="Viti. Gloves +1",ring1="Aqua Ring",ring2="Asklepian Ring",
back="Swith Cape",waist="Fucho-no-obi",legs="Atrophy Tights +1",feet="Vitivation Boots +1"}
-- Fast cast sets for spells
-- 80% Fast Cast (including trait) for all spells, plus 5% quick cast
-- No other FC sets necessary.
sets.precast.FC = {main="Shikargar",sub="Genbu's Shield",ammo="Impatiens",
head="Atro. Chapeau +1",neck="Orunmila's Torque",ear1="Estq. Earring",ear2="Ethereal Earring",
body="Vitivation Tabard",hands="Gende. Gages +1",ring1="Prolix Ring",ring2="Shadow Ring",
back="Swith Cape",waist="Witful Belt",legs="Artsieq Hose",feet="Battlecast Gaiters"}
sets.precast.FC.Impact = set_combine(sets.precast.FC, {head=empty,body="Twilight Cloak"})
-- Weaponskill sets
-- Default set for any weaponskill that isn't any more specifically defined
sets.precast.WS = {ammo="Cheruski Needle",
head="Lithelimb Cap",neck="Asperity Necklace",ear1="Bladeborn Earring",ear2="Steelflash Earring",
body="Karmesin Vest",hands="Umuthi Gloves",ring1="Aqua Ring",ring2="Rajas Ring",
back="Atheling Mantle",waist="Wanion Belt",legs="Osmium Cuisses",feet="Battlecast Gaiters"}
sets.precast.WS.Acc = {ammo="Jukukik Feather",
head="Sukeroku Hachi.",neck="Iqabi Necklace",ear1="Bladeborn Earring",ear2="Steelflash Earring",
body="Atrophy Tabard +1",hands="Viti. Gloves +1",ring1="Aqua Ring",ring2="Rajas Ring",
back="Letalis Mantle",waist="Wanion Belt",legs="Atrophy Tights +1",feet="Battlecast Gaiters"}
sets.precast.WS.DaytimeAcc = set_combine(sets.precast.WS.Acc, {ammo="Tengu-no-Hane"})
sets.precast.WS.TH= {ammo="Cheruski Needle",
head="Sukeroku Hachi.",neck="Asperity Necklace",ear1="Bladeborn Earring",ear2="Steelflash Earring",
body="Atrophy Tabard +1",hands="Viti. Gloves +1",ring1="Aqua Ring",ring2="Rajas Ring",
back="Letalis Mantle",waist="Tarutaru Sash",legs="Atrophy Tights +1",feet="Vitivation Boots +1"}
-- Specific weaponskill sets. Uses the base set if an appropriate WSMod version isn't found.
sets.precast.WS['Requiescat'] = {ammo="Oreiad's Tathlum",
head="Viti. Chapeau +1",neck="Soil Gorget",ear1="Bladeborn Earring",ear2="Steelflash Earring",
body="Atrophy Tabard +1",hands="Viti. Gloves +1",ring1="Aqua Ring",ring2="Rajas Ring",
back="Atheling Mantle",waist="Soil Belt",legs="Atrophy Tights +1",feet="Vitivation Boots +1"}
sets.precast.WS['Requiescat'].Acc = {ammo="Jukukik Feather",
head="Sukeroku Hachi.",neck="Soil Gorget",ear1="Bladeborn Earring",ear2="Steelflash Earring",
body="Atrophy Tabard +1",hands="Viti. Gloves +1",ring1="Aqua Ring",ring2="Rajas Ring",
back="Letalis Mantle",waist="Soil Belt",legs="Atrophy Tights +1",feet="Battlecast Gaiters"}
sets.precast.WS['Requiescat'].DaytimeAcc = set_combine(sets.precast.WS['Requiescat'].Acc, {ammo="Tengu-no-Hane"})
sets.precast.WS['Knights of Round'] = {ammo="Cheruski Needle",
head="Atro. Chapeau +1",neck="Asperity Necklace",ear1="Bladeborn Earring",ear2="Steelflash Earring",
body="Atrophy Tabard +1",hands="Viti. Gloves +1",ring1="Aqua Ring",ring2="Rajas Ring",
back="Atheling Mantle",waist="Celt Belt",legs="Atrophy Tights +1",feet="Vitivation Boots +1"}
sets.precast.WS['Knights of Round'].Acc = {ammo="Jukukik Feather",
head="Sukeroku Hachi.",neck="Iqabi Necklace",ear1="Bladeborn Earring",ear2="Steelflash Earring",
body="Atrophy Tabard +1",hands="Viti. Gloves +1",ring1="Aqua Ring",ring2="Rajas Ring",
back="Letalis Mantle",waist="Celt Belt",legs="Atrophy Tights +1",feet="Battlecast Gaiters"}
sets.precast.WS['Knights of Round'].DaytimeAcc = set_combine(sets.precast.WS['Knights of Round'].Acc, {ammo="Tengu-no-Hane"})
sets.precast.WS['Death Blossom'] = {ammo="Cheruski Needle",
head="Viti. Chapeau +1",neck="Asperity Necklace",ear1="Bladeborn Earring",ear2="Steelflash Earring",
body="Atrophy Tabard +1",hands="Viti. Gloves +1",ring1="Aqua Ring",ring2="Rajas Ring",
back="Atheling Mantle",waist="Celt Belt",legs="Atrophy Tights +1",feet="Vitivation Boots +1"}
sets.precast.WS['Death Blossom'].Acc = {ammo="Jukukik Feather",
head="Sukeroku Hachi.",neck="Iqabi Necklace",ear1="Bladeborn Earring",ear2="Steelflash Earring",
body="Atrophy Tabard +1",hands="Viti. Gloves +1",ring1="Aqua Ring",ring2="Rajas Ring",
back="Letalis Mantle",waist="Celt Belt",legs="Atrophy Tights +1",feet="Battlecast Gaiters"}
sets.precast.WS['Death Blossom'].DaytimeAcc = set_combine(sets.precast.WS['Death Blossom'].Acc, {ammo="Tengu-no-Hane"})
sets.precast.WS['Chant du Cygne'] = {ammo="Yetshila",
head="Lithelimb Cap",neck="Asperity Necklace",ear1="Bladeborn Earring",ear2="Steelflash Earring",
body="Karmesin Vest",hands="Umuthi Gloves",ring1="Thundersoul Ring",ring2="Rajas Ring",
back="Atheling Mantle",waist="Wanion Belt",legs="Osmium Cuisses",feet="Vanir Boots"}
sets.precast.WS['Chant du Cygne'].Acc = {ammo="Jukukik Feather",
head="Sukeroku Hachi.",neck="Iqabi Necklace",ear1="Bladeborn Earring",ear2="Steelflash Earring",
body="Karmesin Vest",hands="Umuthi Gloves",ring1="Thundersoul Ring",ring2="Rajas Ring",
back="Letalis Mantle",waist="Wanion Belt",legs="Osmium Cuisses",feet="Battlecast Gaiters"}
sets.precast.WS['Chant du Cygne'].DaytimeAcc = set_combine(sets.precast.WS['Chant du Cygne'].Acc, {ammo="Tengu-no-Hane"})
-- Midcast Sets
sets.midcast.FastRecast = {main="Twebuliij",sub="Mephitis Grip",ammo="Impatiens",
head="Atro. Chapeau +1",neck="Orunmila's Torque",ear1="Estq. Earring",ear2="Ethereal Earring",
body="Vitivation Tabard",hands="Umuthi Gloves",ring1="Prolix Ring",ring2="Shadow Ring",
back="Swith Cape",waist="Pya'ekue Belt",legs="Artsieq Hose",feet="Battlecast Gaiters"}
sets.midcast.FrontlineCure = {main="Excalibur",sub="Buramenk'ah",ammo="Oreiad's Tathlum",
head="Gende. Caubeen +1",neck="Phalaina Locket",ear1="Estq. Earring",ear2="Ethereal Earring",
body="Heka's Kalasiris",hands="Bokwus Gloves",ring1="Prolix Ring",ring2="Asklepian Ring",
back="Pahtli Cape",waist="Pya'ekue Belt",legs="Atrophy Tights +1",feet="Estq. Houseaux +2"}
sets.midcast.BacklineCure = {main="Tamaxchi",sub="Genbu's Shield",ammo="Oreiad's Tathlum",
head="Gende. Caubeen +1",neck="Orunmila's Torque",ear1="Estq. Earring",ear2="Novia Earring",
body="Heka's Kalasiris",hands="Gende. Gages +1",ring1="Prolix Ring",ring2="Sirona's Ring",
back="Pahtli Cape",waist="Pya'ekue Belt",legs="Atrophy Tights +1",feet="Estq. Houseaux +2"}
sets.midcast['Enhancing Magic'] = {main="Bolelabunga",sub="Genbu's Shield",ammo="Impatiens",
head="Umuthi Hat",neck="Colossus's Torque",ear1="Estq. Earring",ear2="Andoaa Earring",
body="Vitivation Tabard",hands="Atrophy Gloves +1",ring1="Prolix Ring",ring2="Defending Ring",
back="Estoqueur's Cape",waist="Pya'ekue Belt",legs="Atrophy Tights +1",feet="Estq. Houseaux +2"}
sets.midcast.Enhancing = {main="Twebuliij",sub="Mephitis Grip",ammo="Impatiens",
head="Estoqueur's Chappel +2",neck="Orunmila's Torque",ear1="Estq. Earring",ear2="Ethereal Earring",
body="Estoqueur's Sayon +2",hands="Atrophy Gloves +1",ring1="Prolix Ring",ring2="Defending Ring",
back="Estoqueur's Cape",waist="Pya'ekue Belt",legs="Estoqueur's Fuseau +2",feet="Estoqueur's Houseaux +2"}
sets.midcast.Refresh = set_combine(sets.midcast.Enhancing, {legs="Estoqueur's Fuseau +2"})
sets.midcast.Stoneskin = {neck="Stone Gorget",ear2="Earthcry Earring",waist="Siegel Sash",legs="Shedir Seraweels"}
sets.midcast.Aquaveil = set_combine(sets.midcast['Enhancing Magic'], {waist="Emphatikos Rope",legs="Shedir Seraweels"})
sets.midcast['Enfeebling Magic'] = {main="Twebuliij",sub="Mephitis Grip",ammo="Kalboron Stone",
head="Viti. Chapeau +1",neck="Weike Torque",ear1="Lifestorm Earring",ear2="Psystorm Earring",
body="Atrophy Tabard +1",hands=HMAcc,ring1="Sangoma Ring",ring2="Perception Ring",
back="Refraction Cape",waist="Demonry Sash",legs="Artsieq Hose",feet="Vitivation Boots +1"}
sets.midcast['Dia III'] = {head="Viti. Chapeau +1"}
sets.midcast['Diaga'] = set_combine(sets.midcast.EnfeeblingMagic, {waist="Tarutaru Sash"})
sets.midcast.MNDPotency = {main="Twebuliij",sub="Mephitis Grip",ammo="Oreiad's Tathlum",
head="Viti. Chapeau +1",neck="Phalaina Locket",ear1="Lifestorm Earring",ear2="Psystorm Earring",
body="Estoqueur's Sayon +2",hands=HMAcc,ring1="Aqua Ring",ring2="Sirona's Ring",
back="Refraction Cape",waist="Demonry Sash",legs="Artsieq Hose",feet="Uk'uxkaj Boots"}
sets.midcast.MNDPotency.Acc = set_combine(sets.midcast.MNDAccuracy, {body="Estoqueur's Sayon +2",feet="Uk'uxkaj Boots"})
sets.midcast.MNDAccuracy = {main="Twebuliij",sub="Mephitis Grip",ammo="Kalboron Stone",
head="Viti. Chapeau +1",neck="Weike Torque",ear1="Lifestorm Earring",ear2="Psystorm Earring",
body="Artsieq Jubbah",hands=HMAcc,ring1="Sangoma Ring",ring2="Perception Ring",
back="Refraction Cape",waist="Demonry Sash",legs="Artsieq Hose",feet="Vitivation Boots +1"}
sets.midcast.INTPotency = {main="Twebuliij",sub="Mephitis Grip",ammo="Oreiad's Tathlum",
head="Atro. Chapeau +1",neck="Weike Torque",ear1="Lifestorm Earring",ear2="Psystorm Earring",
body="Estoqueur's Sayon +2",hands=HMAcc,ring1="Spiral Ring",ring2="Diamond Ring",
back="Refraction Cape",waist="Wanion Belt",legs="Artsieq Hose",feet="Uk'uxkaj Boots"}
sets.midcast.INTPotency.Acc = set_combine(sets.midcast.INTAccuracy, {body="Estoqueur's Sayon +2",feet="Uk'uxkaj Boots"})
sets.midcast.INTAccuracy = {main="Twebuliij",sub="Mephitis Grip",ammo="Impatiens",
head="Atro. Chapeau +1",neck="Orunmila's Torque",ear1="Estq. Earring",ear2="Ethereal Earring",
body="Artsieq Jubbah",hands="Gende. Gages +1",ring1="Prolix Ring",ring2="Perception Ring",
back="Swith Cape",waist="Witful Belt",legs="Artsieq Hose",feet="Vitivation Boots +1"}
sets.midcast['ElementalEnfeeble'] = {main="Twebuliij",sub="Mephitis Grip",ammo="Kalboron Stone",
head="Atro. Chapeau +1",neck="Weike Torque",ear1="Lifestorm Earring",ear2="Psystorm Earring",
body="Artsieq Jubbah",hands=HMAcc,ring1="Sangoma Ring",ring2="Perception Ring",
back="Refraction Cape",waist="Wanion Belt",legs="Artsieq Hose",feet="Vitivation Boots +1"}
sets.midcast['Elemental Magic'] = {main="Lehbrailg +2",sub="Mephitis Grip",ammo="Witchstone",
head="Hagondes Hat +1",neck="Eddy Necklace",ear1="Friomisi Earring",ear2="Crematio Earring",
body="Seidr Cotehardie",hands=HMAtk,ring1="Acumen Ring",ring2="Diamond Ring",
back="Refraction Cape",waist="Sekhmet Corset",legs="Hagondes Pants +1",feet="Umbani Boots"}
sets.midcast['Elemental Magic'].Acc = {main="Lehbrailg +2",sub="Mephitis Grip",ammo="Kalboron Stone",
head="Atro. Chapeau +1",neck="Imbodla Necklace",ear1="Lifestorm Earring",ear2="Psystorm Earring",
body="Artsieq Jubbah",hands=HMAtk,ring1="Sangoma Ring",ring2="Diamond Ring",
back="Refraction Cape",waist="Wanion Belt",legs="Hagondes Pants +1",feet="Vitivation Boots +1"}
sets.midcast['Elemental Magic'].TH = {main="Lehbrailg +2",sub="Mephitis Grip",ammo="Witchstone",
head="Hagondes Hat +1",neck="Eddy Necklace",ear1="Friomisi Earring",ear2="Crematio Earring",
body="Seidr Cotehardie",hands=HMAtk,ring1="Acumen Ring",ring2="Diamond Ring",
back="Refraction Cape",waist="Tarutaru Sash",legs="Hagondes Pants +1",feet="Umbani Boots"}
sets.midcast.Blizzard = set_combine(sets.midcast['Elemental Magic'], {main="Ngqoqwanb"})
sets.midcast.Blizzard.Acc = set_combine(sets.midcast['Elemental Magic'].Acc, {main="Ngqoqwanb"})
sets.midcast.Blizzard.TH = set_combine(sets.midcast['Elemental Magic'].TH, {main="Ngqoqwanb"})
sets.midcast.Impact = set_combine(sets.midcast['ElementalEnfeeble'], {head=empty,body="Twilight Cloak"})
sets.midcast['Dark Magic'] = {main="Twebuliij",sub="Mephitis Grip",ammo="Kalboron Stone",
head="Viti. Chapeau +1",neck="Weike Torque",ear1="Lifestorm Earring",ear2="Psystorm Earring",
body="Atrophy Tabard +1",hands=HMAcc,ring1="Sangoma Ring",ring2="Diamond Ring",
back="Refraction Cape",waist="Wanion Belt",legs="Artsieq Hose",feet="Vitivation Boots +1"}
sets.midcast.Stun = {main="Twebuliij",sub="Mephitis Grip",ammo="Impatiens",
head="Atro. Chapeau +1",neck="Orunmila's Torque",ear1="Estq. Earring",ear2="Ethereal Earring",
body="Vitivation Tabard",hands="Gende. Gages +1",ring1="Prolix Ring",ring2="Diamond Ring",
back="Swith Cape",waist="Witful Belt",legs="Artsieq Hose",feet="Battlecast Gaiters"}
--sets.midcast.Stun = set_combine(sets.midcast.DarkMagic, {})
--sets.midcast.Drain = set_combine(sets.midcast.DarkMagic, {ring2="Excelsis Ring"})
--sets.midcast.Aspir = sets.midcast.Drain
-- Sets for special buff conditions on spells.
sets.midcast.EnhancingDuration = {hands="Atrophy Gloves +1",back="Estoqueur's Cape",feet="Estoqueur's Houseaux +2"}
sets.buff.ComposureOther = {head="Estoqueur's Chappel +2",
body="Estoqueur's Sayon +2",hands="Atrophy Gloves +1",
back="Estoqueur's Cape",legs="Estoqueur's Fuseau +2",feet="Estoqueur's Houseaux +2"}
sets.buff.Saboteur = {hands="Estoqueur's Gantherots +2"}
-- Sets to return to when not performing an action.
-- Resting sets
sets.resting = {main="Bolelabunga",sub="Genbu's Shield",ammo="Impatiens",
head="Viti. Chapeau +1",neck="Twilight Torque",ear1="Novia Earring",ear2="Ethereal Earring",
body="Atrophy Tabard +1",hands="Serpentes Cuffs",ring1="Defending Ring",ring2="Shadow Ring",
back="Shadow Mantle",waist="Fucho-no-obi",legs="Nares Trews",feet="Serpentes Sabots"}
-- Idle sets (default idle set not needed since the other three are defined, but leaving for testing purposes)
sets.idle.Town = {main="Bolelabunga",sub="Genbu's Shield",ammo="Impatiens",
head="Viti. Chapeau +1",neck="Twilight Torque",ear1="Novia Earring",ear2="Ethereal Earring",
body="Atrophy Tabard +1",hands="Serpentes Cuffs",ring1="Defending Ring",ring2="Shadow Ring",
back="Kumbira Cape",waist="Fucho-no-obi",legs="Nares Trews",feet="Serpentes Sabots"}
sets.idle.Field = {main="Bolelabunga",sub="Genbu's Shield",ammo="Impatiens",
head="Viti. Chapeau +1",neck="Twilight Torque",ear1="Novia Earring",ear2="Ethereal Earring",
body="Atrophy Tabard +1",hands="Serpentes Cuffs",ring1="Defending Ring",ring2="Shadow Ring",
back="Kumbira Cape",waist="Fucho-no-obi",legs="Nares Trews",feet="Serpentes Sabots"}
sets.idle.Weak = {main="Bolelabunga",sub="Genbu's Shield",ammo="Impatiens",
head="Viti. Chapeau +1",neck="Twilight Torque",ear1="Novia Earring",ear2="Ethereal Earring",
body="Atrophy Tabard +1",hands="Serpentes Cuffs",ring1="Defending Ring",ring2="Shadow Ring",
back="Kumbira Cape",waist="Fucho-no-obi",legs="Nares Trews",feet="Serpentes Sabots"}
-- Defense sets
sets.defense.PDT = {main="Shikargar",sub="Genbu's Shield",ammo="Impatiens",
head="Lithelimb Cap",neck="Twilight Torque",ear1="Brutal Earring",ear2="Ethereal Earring",
body="Karmesin Vest",hands="Umuthi Gloves",ring1="Defending Ring",ring2="K'ayres Ring",
back="Shadow Mantle",waist="Fucho-no-obi",legs="Osmium Cuisses",feet="Battlecast Gaiters"}
sets.defense.RefreshPDT = {main="Shikargar",sub="Genbu's Shield",ammo="Impatiens",
head="Viti. Chapeau +1",neck="Twilight Torque",ear1="Brutal Earring",ear2="Ethereal Earring",
body="Atrophy Tabard +1",hands="Umuthi Gloves",ring1="Defending Ring",ring2="K'ayres Ring",
back="Shadow Mantle",waist="Fucho-no-obi",legs="Osmium Cuisses",feet="Battlecast Gaiters"}
sets.defense.MDT = {main="Shikargar",sub="Genbu's Shield",ammo="Impatiens",
head="Atrophy Chapeau +1",neck="Twilight Torque",ear1="Novia Earring",ear2="Ethereal Earring",
body="Atrophy Tabard +1",hands="Vitivation Gloves +1",ring1="Defending Ring",ring2="Shadow Ring",
back="Refraction Cape",waist="Wanion Belt",legs="Atrophy Tights +1",feet="Umbani Boots"}
-- Engaged sets
-- Variations for TP weapon and (optional) offense/defense modes. Code will fall back on previous
-- sets if more refined versions aren't defined.
-- If you create a set with both offense and defense modes, the offense mode should be first.
-- EG: sets.engaged.Dagger.Accuracy.Evasion
-- Normal melee group
sets.engaged = {main="Excalibur", sub="Genbu's Shield",ammo="Paeapua",
head="Lithelimb Cap",neck="Asperity Necklace",ear1="Bladeborn Earring",ear2="Steelflash Earring",
body="Karmesin Vest",hands="Umuthi Gloves",ring1="K'ayres Ring",ring2="Rajas Ring",
back="Atheling Mantle",waist="Shetal Stone",legs="Osmium Cuisses",feet="Battlecast Gaiters"}
sets.engaged.Acc = {main="Excalibur", sub="Genbu's Shield",ammo="Jukukik Feather",
head="Lithelimb Cap",neck="Iqabi Necklace",ear1="Bladeborn Earring",ear2="Steelflash Earring",
body="Karmesin Vest",hands="Umuthi Gloves",ring1="K'ayres Ring",ring2="Rajas Ring",
back="Letalis Mantle",waist="Shetal Stone",legs="Osmium Cuisses",feet="Battlecast Gaiters"}
sets.engaged.Acc.Daytime = set_combine(sets.engaged.Acc, {ammo="Tengu-no-Hane"})
sets.engaged.TH = {main="Excalibur", sub="Genbu's Shield",ammo="Paeapua",
head="Lithelimb Cap",neck="Asperity Necklace",ear1="Bladeborn Earring",ear2="Steelflash Earring",
body="Karmesin Vest",hands="Umuthi Gloves",ring1="K'ayres Ring",ring2="Rajas Ring",
back="Atheling Mantle",waist="Tarutaru Sash",legs="Osmium Cuisses",feet="Battlecast Gaiters"}
sets.engaged.DW = set_combine(sets.engaged, {sub="Buramenk'ah",ear1="Brutal Earring",ear2="Suppanomimi"})
sets.engaged.DW.Acc = set_combine(sets.engaged.Acc, {sub="Buramenk'ah",ear1="Brutal Earring",ear2="Suppanomimi"})
sets.engaged.DW.Acc.Daytime = set_combine(sets.engaged.Acc.Daytime, {sub="Buramenk'ah",ear1="Brutal Earring",ear2="Suppanomimi"})
sets.engaged.DW.TH = set_combine(sets.engaged.TH, {sub="Buramenk'ah",ear1="Brutal Earring",ear2="Suppanomimi"})
-- Defensive melee group
sets.engaged.DT = set_combine(sets.engaged, {head="Lithelimb Cap",neck="Twilight Torque",
hands="Umuthi Gloves",ring1="K'ayres Ring",ring2="Defending Ring",legs="Osmium Cuisses",feet="Battlecast Gaiters"})
sets.engaged.Acc.DT = set_combine(sets.engaged.Acc, {head="Lithelimb Cap",neck="Twilight Torque",
hands="Umuthi Gloves",ring1="K'ayres Ring",ring2="Defending Ring",legs="Osmium Cuisses",feet="Battlecast Gaiters"})
sets.engaged.Acc.DT.Daytime = set_combine(sets.engaged.Acc.Daytime, {head="Lithelimb Cap",neck="Twilight Torque",
hands="Umuthi Gloves",ring1="K'ayres Ring",ring2="Defending Ring",legs="Osmium Cuisses",feet="Battlecast Gaiters"})
sets.engaged.TH.DT = set_combine(sets.engaged.TH, {head="Lithelimb Cap",neck="Twilight Torque",
hands="Umuthi Gloves",ring1="K'ayres Ring",ring2="Defending Ring",legs="Osmium Cuisses",feet="Battlecast Gaiters"})
sets.engaged.DW.DT = set_combine(sets.engaged.DW, {head="Lithelimb Cap",neck="Twilight Torque",
hands="Umuthi Gloves",ring1="K'ayres Ring",ring2="Defending Ring",legs="Osmium Cuisses",feet="Battlecast Gaiters"})
sets.engaged.DW.Acc.DT = set_combine(sets.engaged.DW.Acc, {head="Lithelimb Cap",neck="Twilight Torque",
hands="Umuthi Gloves",ring1="K'ayres Ring",ring2="Defending Ring",legs="Osmium Cuisses",feet="Battlecast Gaiters"})
sets.engaged.DW.Acc.DT.Daytime = set_combine(sets.engaged.DW.Acc.Daytime, {head="Lithelimb Cap",neck="Twilight Torque",
hands="Umuthi Gloves",ring1="K'ayres Ring",ring2="Defending Ring",legs="Osmium Cuisses",feet="Battlecast Gaiters"})
sets.engaged.DW.TH.DT = set_combine(sets.engaged.DW.TH, {head="Lithelimb Cap",neck="Twilight Torque",
hands="Umuthi Gloves",ring1="K'ayres Ring",ring2="Defending Ring",legs="Osmium Cuisses",feet="Battlecast Gaiters"})
sets.FrontlineWeapons = {main="Excalibur", sub="Genbu's Shield"}
sets.FrontlineWeapons.DW = {main="Excalibur", sub="Buramenk'ah"}
end
-------------------------------------------------------------------------------------------------------------------
-- Job-specific hooks that are called to process player actions at specific points in time.
-------------------------------------------------------------------------------------------------------------------
-- Set eventArgs.handled to true if we don't want any automatic gear equipping to be done.
function job_midcast(spell, action, spellMap, eventArgs)
if spell.action_type == 'Magic' then
-- Default base equipment layer of fast recast.
equip(sets.midcast.FastRecast)
end
end
-- Run after the default midcast() is done.
-- eventArgs is the same one used in job_midcast, in case information needs to be persisted.
function job_post_midcast(spell, action, spellMap, eventArgs)
if spell.skill == 'Enfeebling Magic' and state.Buff.Saboteur then
equip(sets.buff.Saboteur)
elseif spell.skill == 'Enhancing Magic' then
if buffactive.composure and spell.target.type == 'PLAYER' then
if spell.english == 'Phalanx II' then
equip(sets.buff.EnhancingDuration)
else
equip(sets.buff.ComposureOther)
end
else
equip(sets.midcast.EnhancingDuration)
end
end
end
-- Set eventArgs.handled to true if we don't want any automatic gear equipping to be done.
function job_aftercast(spell, action, spellMap, eventArgs)
if not spell.interrupted then
if state.Buff[spell.english] ~= nil then
state.Buff[spell.english] = true
end
end
end
-------------------------------------------------------------------------------------------------------------------
-- Customization hooks for idle and melee sets, after they've been automatically constructed.
-------------------------------------------------------------------------------------------------------------------
-- Custom spell mapping.
function job_get_spell_map(spell, default_spell_map)
if spell.action_type == 'Magic' then
if (default_spell_map == 'Cure' or default_spell_map == 'Curaga') then
if state.CombatMode == 'Frontline' then
return "FrontlineCure"
else
return "BacklineCure"
end
elseif MNDPotencySpells:contains(spell.english) then
return 'MNDPotency'
elseif spell.english == 'Silence' then
return 'MNDAccuracy'
elseif spell.english == 'Blind' then
return 'INTPotency'
elseif INTAccuracySpells:contains(spell.english) then
return 'INTAccuracy'
elseif EnhancingSpells:contains(spell.english) then
return 'Enhancing'
elseif IceSpells:contains(spell.english) then
return 'Blizzard'
end
end
end
-------------------------------------------------------------------------------------------------------------------
-- General hooks for other events.
-------------------------------------------------------------------------------------------------------------------
-- Called when a player gains or loses a buff.
-- buff == buff gained or lost
-- gain == true if the buff was gained, false if it was lost.
function job_buff_change(buff, gain)
if state.Buff[buff] ~= nil then
state.Buff[buff] = gain
end
end
function get_custom_wsmode(spell, action, spellMap, default_wsmode)
if default_wsmode == 'Acc' and classes.Daytime then
return 'DaytimeAcc'
end
end
function job_time_change(new_time, old_time)
classes.CustomMeleeGroups:clear()
if classes.Daytime then
classes.CustomMeleeGroups:append('Daytime')
end
end
-------------------------------------------------------------------------------------------------------------------
-- User code that supplements self-commands.
-------------------------------------------------------------------------------------------------------------------
-- Called by the 'update' self-command, for common needs.
-- Set eventArgs.handled to true if we don't want automatic equipping of gear.
function job_update(cmdParams, eventArgs)
if weapons then
equip(weapons)
weapons = nil
eventArgs.handled = true
end
end
function job_state_change(stateField, newValue, oldValue)
if stateField == 'CombatMode' then
if newValue == 'Frontline' then
weapons = sets.FrontlineWeapons[state.CombatForm] or sets.FrontlineWeapons
send_command('wait 0.1; gs disable main sub')
else
enable('main', 'sub')
end
end
end
-- Set eventArgs.handled to true if we don't want the automatic display to be run.
function display_current_job_state(eventArgs)
local defenseString = ''
if state.Defense.Active then
local defMode = state.Defense.PhysicalMode
if state.Defense.Type == 'Magical' then
defMode = state.Defense.MagicalMode
end
defenseString = 'Defense: '..state.Defense.Type..' '..defMode..', '
end
local meleeString = ''
if state.OffenseMode == 'Normal' then
--meleeString = 'Melee: Weapons locked, '
end
add_to_chat(122,'Combat ['..state.CombatMode..'], '..meleeString..'Casting ['..state.CastingMode..'], '..meleeString..
'Idle ['..state.IdleMode..'], '..defenseString..'Kiting: '..on_off_names[state.Kiting])
eventArgs.handled = true
end
-------------------------------------------------------------------------------------------------------------------
-- Utility functions specific to this job.
-------------------------------------------------------------------------------------------------------------------
-- Select default macro book on initial load or subjob change.
function select_default_macro_book()
-- Default macro set/book
set_macro_page(1, 5)
-- Default macro set/book
if player.sub_job == 'BLM' then
set_macro_page(2, 5)
elseif player.sub_job == 'NIN' then
set_macro_page(4, 5)
elseif player.sub_job == 'DNC' then
set_macro_page(5, 5)
elseif player.sub_job == 'DRK' then
set_macro_page(7, 5)
elseif player.sub_job == 'PLD' then
set_macro_page(8, 5)
end
end
Carbuncle.Riaka
サーバ: Carbuncle
Game: FFXI
Posts: 43
By Carbuncle.Riaka 2014-11-07 18:19:47
Can really use some help getting gearswap to work. I downloaded a blu.lua and changed my gear over but it won't load in game for some reason. My other plug ins work.
Am I supposed to be saving all my job .lua to the data folder in the gearswap folder?
Cerberus.Conagh
サーバ: Cerberus
Game: FFXI
Posts: 3189
By Cerberus.Conagh 2014-11-07 18:42:20
Can really use some help getting gearswap to work. I downloaded a blu.lua and changed my gear over but it won't load in game for some reason. My other plug ins work.
Am I supposed to be saving all my job .lua to the data folder in the gearswap folder?
Yes.
Carbuncle.Riaka
サーバ: Carbuncle
Game: FFXI
Posts: 43
By Carbuncle.Riaka 2014-11-07 18:49:11
So what am I doing wrong to make it not load in game....
Cerberus.Conagh
サーバ: Cerberus
Game: FFXI
Posts: 3189
By Cerberus.Conagh 2014-11-07 19:04:50
is it named as such
Riaka_SAM.lua
Name_job.lua is the format
サーバ: Fenrir
Game: FFXI
Posts: 69
By Fenrir.Duvelamilla 2014-11-13 10:29:25
I am in the process of trying to change my BRD over to Motes BRD Lua. I had found a different Lua before hearing about all of Motes so I am trying to eventually change all my jobs over to it. However with the 1st Lua I found there was a command to actually manually use my Daurabla it was
status_change(player.status)
elseif command == 'C18' then -- Daurdabla Toggle --
if Daurdabla == 'ON' then
Daurdabla = 'OFF'
add_to_chat(123,'Daurdabla: [OFF]')
else
Daurdabla = 'ON'
add_to_chat(158,'Daurdabla: [ON]')
end
I really prefer that over having to cast 3 songs then recast them to over write them but I REALLY suck at coding.. is there a way I can incorporate this in the Mote you made?
Also I was able to make a list of songs such as ""Fowl Aubade","Shining Fantasia","Herb Pastoral","Scop's Operetta","Puppet's Operetta","Gold Capricco","Warding Round","Goblin Gavotte","Chocobo Mazurka","Raptor Mazurka" that would automatically be cast with harp but again I can not figure out how to change it to make it do it with Motes. Any help would be GREATLY appreciated. I had PMed him through here but have not yet received a reply, so i thought I would reach out to some of you other who might be able to help.
Bahamut.Shirai
By Bahamut.Shirai 2014-11-13 14:20:58
I've got a weird one, thanks to the help of some folks over in the Summoner forums I've optimized my my Elemental Siphon rules so that they add in the right equipment depending on the circumstances I use Siphon under.
I've got it working like a charm apart from one little detail: My gearswap for some reason does not recognize the element of my elementals. <_<
To give an example, if I summon Titan on earthsday and use /ja "Elemental Siphon" <me> gearswap neatly equips the zodiac ring instead of the Glob in my Siphon set, however on Earth Spirit, it doesn't.
Which library needs to be accessed to fix this?
Or are there some rules I can add to my own GS?
Thanks in advance!
[edit]
My SMN LUA
http://pastebin.com/s08YpDDQ
[edit 2]
Thank you for the answer below.
By Acacia 2014-11-13 15:43:10
I've got a weird one, thanks to the help of some folks over in the Summoner forums I've optimized my my Elemental Siphon rules so that they add in the right equipment depending on the circumstances I use Siphon under.
I've got it working like a charm apart from one little detail: My gearswap for some reason does not recognize the element of my elementals. <_<
To give an example, if I summon Titan on earthsday and use /ja "Elemental Siphon" <me> gearswap neatly equips the zodiac ring instead of the Glob in my Siphon set, however on Earth Spirit, it doesn't.
Which library needs to be accessed to fix this?
Or are there some rules I can add to my own GS?
Thanks in advance!
[edit]
My SMN LUA
http://pastebin.com/s08YpDDQThat's because of a bug in GearSwap, I sent a pull request with the fix so hopefully it will be pushed live soon.
[+]
Cerberus.Conagh
サーバ: Cerberus
Game: FFXI
Posts: 3189
By Cerberus.Conagh 2014-11-16 21:44:02
This is more to do with AutoRA but it's Lua and you can use alot of the functionality in gearswap..
Code player.vitals['TP'] > 1000
Now on RNG I'm trying to make this work, however I seem to crop up to an issue with flurry 2 on.
It seems to not register I'm at 1k tp and shoots again, but when I don't have flurry on it works perfectly fine 99.99% of the time.
I surmise this is due to the way SE sends Packet Chunks which include TP updates which is what Vitals works off of?
Is there a counter measure or a way around this that anyone knows of?
Just looking for someone to explain this addon a bit for me. It looks like it is an alternative to Spellcast.
Is it going to be replacing Spellcast? In which ways is it better or worse. I don't know any programming but I've slowly learned more and more about spellcast and the 'language' used in gearswap is confusing to me.
It says it uses packets so it potentially could be more detectable? but does that also eliminate any lag that spellcast may encounter?
I plan on redoing my PUP xml to include pet casting sets thanks to the new addon petschool. I'm just not sure if it's worth it to just wait until gearswap gets more popular or to go ahead and do it in spellcast.
If anyone could give me more info I'd greatly appreciate it.
|
|