|
Gearswap Support Thread
By Avebian 2014-07-10 13:26:39
Is it possible to Combine two variables like spell.type and spell.skill?
I want combine 'White Magic' and 'Enfeebling Magic' So spells like slow, para, etc equip one set, and the blackmagic enfeebs another. Tried everything I can think of with no luck.
VIP
サーバ: Fenrir
Game: FFXI
Posts: 764
By Fenrir.Motenten 2014-07-10 13:51:07
Vafruvant said: Small question: is there a way to have a specific set for cures when they are cast on yourself?
Try spell.target.type == 'SELF'.
Avebian said: Is it possible to Combine two variables like spell.type and spell.skill?
It depends on what you mean by 'combine', and how you've designed your sets; but regardless, yes.
One possible problem you might be having, based on what you wrote: spell.type will have 'WhiteMagic', not 'White Magic', while spell.skill will have 'Enfeebling Magic', not 'EnfeeblingMagic'. The space was added to skills, but not to types.
One possible example:
Code
sets.midcast['Enfeebling Magic']['WhiteMagic'] = {}
function midcast(spell)
local equipSet = sets.midcast
if equipSet[spell.skill] then
equipSet = equipSet[spell.skill]
if equipSet[spell.type] then
equipSet = equipSet[spell.type]
end
end
equip(equipSet)
end
By Avebian 2014-07-10 13:59:49
Ah the space, thanks for that. Got it working with
if spell.skill == 'Enfeebling Magic' and spell.type == 'WhiteMagic' then
サーバ: Asura
Game: FFXI
Posts: 363
By Asura.Vafruvant 2014-07-11 00:00:35
Vafruvant said: Small question: is there a way to have a specific set for cures when they are cast on yourself?
Try spell.target.type == 'SELF'. I tried that, and it actually stopped swapping anything for cures, but that much I remedied. I changed the precast to midcast and it at least swapped into my normal cure set. The self-specific cure set still isn't functional. Here's the revised code, and my two sets: Code sets.midcast.Cure = {ammo="Brigantia Pebble",neck="Nesanica Torque",ear1="Hospitaler Earring",legs="Blitzer Poleyn",ring1="Sirona's Ring"}
sets.midcast.Cure.Self = set_combine(sets.midcast.Cure, {head="Shabti Armet",ear2="Oneiros Earring",hands="Buremte Gloves",waist="Chuq'aba Belt"}) Code function midcast(spell,action)
if spell.english:startswith('Cure') and spell.target.type == 'SELF' then
equip(sets.midcast.Cure.Self)
end
end
サーバ: Asura
Game: FFXI
Posts: 363
By Asura.Vafruvant 2014-07-11 12:35:15
As an aside, my WHM lua is putting on my aftercast gear before the spell completely casts. By using "showswaps" alongside Battlemod, it switches into the aftercast gear before the spell goes off, leaving me with a net 0% Cure Potency. Obviously this is a problem, being WHM lol. I was wondering if this was a common problem with an easy solution. Thanks!
VIP
サーバ: Fenrir
Game: FFXI
Posts: 764
By Fenrir.Motenten 2014-07-11 12:41:52
Sounds like an issue with your overall gearswap file, then. Can't answer based on the snippets provided; please link to a copy of the entire file on pastebin or similar.
サーバ: Asura
Game: FFXI
Posts: 363
By Asura.Vafruvant 2014-07-11 13:07:18
Sounds like an issue with your overall gearswap file, then. Can't answer based on the snippets provided; please link to a copy of the entire file on pastebin or similar. No problem, here's the pastebin: http://pastebin.com/K1yBCFpH
It's mostly copied from your WHM file, with primarily only gear tweaks.
Lakshmi.Zerowone
サーバ: Lakshmi
Game: FFXI
Posts: 6949
By Lakshmi.Zerowone 2014-07-11 13:22:10
As an aside, my WHM lua is putting on my aftercast gear before the spell completely casts. By using "showswaps" alongside Battlemod, it switches into the aftercast gear before the spell goes off, leaving me with a net 0% Cure Potency. Obviously this is a problem, being WHM lol. I was wondering if this was a common problem with an easy solution. Thanks!
According to Byrth you are going to want to put your rules from the precast function into the midcast as well.
The reason why you want the mirroring in the midcast is because there are times when the gearswap is so fast it switches to after cast before the action has reached midcast. However, if you have specific midcast rules for certain actions you do not want to place the correlating precast rules in midcast.
ex1: for WS and JAs that only have precast rules you want to copy and paste their specific rules from the precast function into the midcast function.
ex2: CorsairShot or Quick Draw: In precast you would want a condition to equip Mirke to activate the augment. For Midcast you would want all your MAB/MAcc gear equipped to enhance potency.
Also, when using showswaps if the precast and midcast gear is the same it will not appear in the log. It will just show precast and after cast.
サーバ: Asura
Game: FFXI
Posts: 363
By Asura.Vafruvant 2014-07-11 13:43:40
As an aside, my WHM lua is putting on my aftercast gear before the spell completely casts. By using "showswaps" alongside Battlemod, it switches into the aftercast gear before the spell goes off, leaving me with a net 0% Cure Potency. Obviously this is a problem, being WHM lol. I was wondering if this was a common problem with an easy solution. Thanks!
According to Byrth you are going to want to put your rules from the precast function into the midcast as well.
The reason why you want the mirroring in the midcast is because there are times when the gearswap is so fast it switches to after cast before the action has reached midcast. However, if you have specific midcast rules for certain actions you do not want to place the correlating precast rules in midcast.
ex1: for WS and JAs that only have precast rules you want to copy and paste their specific rules from the precast function into the midcast function.
ex2: CorsairShot or Quick Draw: In precast you would want a condition to equip Mirke to activate the augment. For Midcast you would want all your MAB/MAcc gear equipped to enhance potency.
Also, when using showswaps if the precast and midcast gear is the same it will not appear in the log. It will just show precast and after cast. I don't understand what the point of having a fast cast set would be, then. I have my capped cure casting time gear on precast, which does equip, it shows equipping the midcast but it just switches out before the spell goes off. It isn't a precast/midcast problem, it is a midcast/aftercast problem.
Lakshmi.Zerowone
サーバ: Lakshmi
Game: FFXI
Posts: 6949
By Lakshmi.Zerowone 2014-07-11 16:06:53
With regard to the point of using a fast cast set read the part in bold italics.
But it sounds like your function midcast has an issue. Wouldn't know how to help ya without seeing the code.
By Silverfox6868 2014-07-11 18:28:54
Need help
with obi
not changing
http://pastebin.com/T1fSbUwA
By Miang 2014-07-11 18:42:32
Pretty sure things like Code if Dark == world.weather_element or Dark == world.day_element then need to be Code if world.weather_element == 'Dark' or world.day_element == 'Dark' then
The quotes around the word 'Dark' are needed, otherwise it's looking for a variable called Dark, which isn't set, so has a value of nil.
By Silverfox6868 2014-07-11 19:37:40
That doesnt work either wtf with these damn obis
By Santi 2014-07-11 20:47:49
My time dependent gear isn't changing by itself anymore. Gearswap also can't detect whether its day or night.
Did something change to where I have to alter my lua? Or is this a bug?
Lakshmi.Zerowone
サーバ: Lakshmi
Game: FFXI
Posts: 6949
By Lakshmi.Zerowone 2014-07-11 21:35:52
try this one: http://pastebin.com/Q2vMERzz
lines 220, 248 and 255 for examples. Should work.
Use //gs showswaps to verify etc.
Phoenix.Yocuz
サーバ: Phoenix
Game: FFXI
Posts: 40
By Phoenix.Yocuz 2014-07-11 21:37:13
-- Fast Cast set
sets.precast.FC =
{
ammo="Incantor Stone"
head="Creed Armet +2",
body="Reverence Surcoat +1",
hands="Buremte Gloves",
legs="Enif Cosciales",
Right_ring = "Prolix Ring",
Left_ear = "Loquac. Earring"
}
getting an error says its from this line of code the
sets.precast.Fc =
says expected '}' to close at line 43
please help
Lakshmi.Zerowone
サーバ: Lakshmi
Game: FFXI
Posts: 6949
By Lakshmi.Zerowone 2014-07-11 21:43:50
Would need to see the code above it, that section looks clean but there could be an issue with a missing closing } above that section.
Phoenix.Yocuz
サーバ: Phoenix
Game: FFXI
Posts: 40
By Phoenix.Yocuz 2014-07-11 21:47:38
function get_sets()
magicT = "Normal"
enga = 0
-- Smart PLD
smartPLD = true
curepos = true
-- Pourcentage of HP you want to autoequip Twilight set
HPofReraise = 10
----------------- SMART PLD VARIABLES ----------------------
--- Add here the name of the monsters move you wanna autoequip PDT set
PDTTrigger = S{"Ripper Fang", "Chomp Rush", "Scythe Tail", "Cyclotail", "Delta Thrust", "Torpefying Charge", "Head Butt", "Tortoise Stomp", "Painful Whip", "Recoil Dive", "Gnash", "Deathgnash", "Seismic Tail", "Big Scissors", "Megascissors", "Drill Branch", "Pinecone Bomb"}
--- Add here the name of the monsters move you wanna autoequip MDT set
MDTTrigger = S{"Whirling Inferno", "Foul Breath", "Tarichutoxin", "Aqua Fortis", "Regurgitation", "Calcifying Mist", "Aqua Breath", "Earth Breath", "Tetsudo Tremor", "Palsynyxis", "Aqua Ball", "Leeching Current", "Seaspray", "Venom Shower", "Bubble Shower", "Marine Mayhem", "Tidal Guillotine", "Leafstorm"}
--- Add here the name of the monsters you want Smart PLD on
MonsterTrigger = S{"Ark Angel EV", "Ark Angel MR", "Ark Angel TT", "Ark Angel GK", "Ark Angel MR", "Pandemonium Warden"}
-- JA Precast
sets.precast = {}
-- Relic Augmented JA
sets.precast['Iron Will'] = {head="Cab. Coronet +1"}
sets.precast['Fealty'] = {body="Cab. Surcoat +1"}
sets.precast['Chivalry'] = {hands="Cab. Gauntlets +1"}
sets.precast['Invincible'] = {legs="Cab. Breeches +1"}
sets.precast['Guardian'] = {feet="Cab. Leggings +1"}
-- Other JA
sets.precast['Cover'] = {head="Rev. Coronet +1"}
sets.precast['Holy Circle'] = {feet="Rev. Leggings +1"}
sets.precast['Divine Emblem'] = {feet="Creed Sabatons +2"}
-- Fast Cast set
sets.precast.FC =
{
ammo="Incantor Stone"
head="Creed Armet +2",
body="Reverence Surcoat +1",
hands="Buremte Gloves",
legs="Enif Cosciales",
Right_ring = "Prolix Ring",
Left_ear = "Loquac. Earring"
}
Bismarck.Inference
サーバ: Bismarck
Game: FFXI
Posts: 417
By Bismarck.Inference 2014-07-11 21:48:08
You're missing a comma after Incantor Stone
[+]
Phoenix.Yocuz
サーバ: Phoenix
Game: FFXI
Posts: 40
By Phoenix.Yocuz 2014-07-11 21:53:04
ah ty now i had more problems but i fixed the missing commas
sigh now its saying i have a nil value >.<
Bismarck.Inference
サーバ: Bismarck
Game: FFXI
Posts: 417
By Bismarck.Inference 2014-07-11 21:56:49
Make sure every complex set has it's more basic parts defined, much like how you have sets.precast={}, you can't have sets.TP.Sword without sets.TP={}, can't have sets.TP.Sword.High without sets.TP.Sword={}, etc. You can chose to put gear in the more basic sets if you desire, but they at least have to exist.
[+]
Phoenix.Yocuz
サーバ: Phoenix
Game: FFXI
Posts: 40
By Phoenix.Yocuz 2014-07-11 22:08:14
inf u are amazing u helped me figure it out i didnt have a midcast defined u *** rock
Phoenix.Yocuz
サーバ: Phoenix
Game: FFXI
Posts: 40
By Phoenix.Yocuz 2014-07-11 22:12:32
lol now that it loaded i got another error figures!!
Phoenix.Yocuz
サーバ: Phoenix
Game: FFXI
Posts: 40
By Phoenix.Yocuz 2014-07-11 22:19:46
GearSwap: Lua error (runtime) gearswap/flow.lua93:
user event error ... windower4/addons/gearswap/data/yocuz/yocuz_pld.lua:576: attempt to compare number with nil
if player.hpp <= HPtoReraise then
equip(sets.AutoRR)
add_to_chat(501, '*-*-*-*-*-*-*-*-* [ HP < '..HPtoReraise..' - Twilight set ON ] *-*-*-*-*-*-*-*-*')
end
end)
Bismarck.Inference
サーバ: Bismarck
Game: FFXI
Posts: 417
By Bismarck.Inference 2014-07-11 22:24:42
Upload whole file on pastebin :
http://pastebin.com/
and post the link here, I'd need to see how you define that but my guess would be its not a number (where you defined HPtoReraise you did HPtoReraise == 'something' rather than just HPtoReraise = 10) but would be better to just look at the whole thing rather than blind guessing.
Phoenix.Yocuz
サーバ: Phoenix
Game: FFXI
Posts: 40
By Phoenix.Yocuz 2014-07-11 22:28:38
http://pastebin.com/XjGQndXk
this is the pastebin im still filling in my sets some are blank
Bismarck.Inference
サーバ: Bismarck
Game: FFXI
Posts: 417
By Bismarck.Inference 2014-07-11 22:30:56
I don't even see HPtoReraise anywhere else besides that rule. Somewhere near the beginning just type HPtoReraise = 50 or whatever number you want it to be.
Phoenix.Yocuz
サーバ: Phoenix
Game: FFXI
Posts: 40
By Phoenix.Yocuz 2014-07-11 22:32:49
it is all the way at the top already set to 10
Phoenix.Yocuz
サーバ: Phoenix
Game: FFXI
Posts: 40
By Phoenix.Yocuz 2014-07-11 22:33:13
on line 9
Phoenix.Yocuz
サーバ: Phoenix
Game: FFXI
Posts: 40
By Phoenix.Yocuz 2014-07-11 22:33:49
ffs says of not to lol
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.
|
|