it should be
Thaumas Coat
it should be
Thaumas Coat
I have this line of code in my blu lua and it should work to change from my normal tp set into my high haste set but the problem that i'm having is that even without caped haste it's putting me into my high haste set.
Code:if buffactive.March==2 or buffactive.March==1 and buffactive.Haste or buffactive[580] and buffactive.Haste or buffactive['Mighty Guard'] and buffactive[580] then equipSet = equipSet["HighHaste"] end
I want it to check buffactive in groups to see if it meets a level of caped haste and if so equip my haste set so for instance buffs haste and mighty guard = caped haste same for Haste and Indi-Haste etc
You're probably running into trouble with operator precedence. The and statements are evaluated before the or statements.
Don't try to fit that all into one if (...) condition, too many combinations.
Try something like this - a function with some safe assumptions on the potency of haste buffs you're getting.
Code:if effectiveHaste(0) >= 43.5 then --If Haste at Magical Haste Cap equipSet = equipSet["HighHaste"] endCode:function effectiveHaste(equiphaste) jahaste = 0 magichaste = 0 if equiphaste > 25 then equiphaste = 25 end --JA. Caps at 25 if buffactive['Haste Samba'] then jahaste = jahaste + 5 end if jahaste > 25 then jahaste = 25 end -- Magical. Caps at 43.5 if buffactive[33] then --Assume Haste2 since we have flutter magichaste = magichaste + 30 end if buffactive.march then --12 per march as worst case, really scrub brd magichaste = magichaste + 12*buffactive.march end if buffactive[580] then --Indihaste, assume Dunna/+5 at least magichaste = magichaste + 35 end if buffactive['Mighty Guard'] then magichaste = magichaste + 15 end if buffactive.embrava then magichaste = magichaste + 22 end if magichaste > 43.5 then magichaste = 43.5 end totalHaste = equiphaste + jahaste + magichaste if totalHaste > 80 then totalHaste = 80 end return totalHaste end
If you dont do what radec suggests you definitely need to add some parenthesis.
if buffactive.March==2 or ( buffactive.March==1 and buffactive.Haste ) or ( buffactive[580] and buffactive.Haste ) or ( buffactive['Mighty Guard'] and buffactive[580] ) then
if i ever use code like this i have problems without parenthesis.
not only you will have issues gearswap will as well
because the way it was posted it will get garbled and turn into a false no matter what buffs you have (well unless you have buffactive.March==2)
the way it was posted
it looks like this to the system (this is called a cascading failure)Code:if buffactive.March==2 or buffactive.March==1 and buffactive.Haste or buffactive[580] and buffactive.Haste or buffactive['Mighty Guard'] and buffactive[580] then
an or causes the processing to break as if it was another ifCode:if buffactive.March==2 or (buffactive.March==1 and (buffactive.Haste or (buffactive[580] and (buffactive.Haste or (buffactive['Mighty Guard'] and buffactive[580]))))) then
you need to use () to separate the things you want to check when doing something like this
--basicaly () tell the system to run this check first to get its results then do the whole if line with the results
example:
if check1 or check2 and check3 then --no good -- if any of the check's are false it would make the if false
if check1 or (check2 and check3) then --good --if check2 and check3 are both true then the () is true else it is false
just remember that all an if/elseif checks for is the the outcome is true or false. if true run the code in the if, if false do not
please change
magichaste = magichaste + 12*buffactive.march
to
magichaste = magichaste + (12*buffactive.march)
just to be safe
i would change those 3 variables to local varables
aka
local jahaste = 0
local magichaste = 0
local totalHaste = equiphaste + jahaste + magichaste
you are keeping things in memory that you just dont need to
Thanks for the reply's, I have change what i was using to the above code and it's now working as i wanted it to :D
I have recently come back to the game after being gone for several years. Back in the day I used Windower and had a summoning skill up script so I could cap my skills at 75. Now I am level 99 and of course my skills are seriously lacking.
I have download/install the Gearswap add on into my windower. I then took the skillup.lua file and put it in my gearswap > data folder (it said to put in gearswap > data > character folder, but I do not have a character folder, inside the data folder is simply a readme type file). I have searched and tried to figure out how to execute it and I finally found somewhere that said to type /toggle_console to bring up the console screen. From there I typed gs 1 skillup.lua, as that is what it said to do, and it says "command not found" I have tried everything I can think of to get it load so I am here for help.
What am I missing or doing wrong here? I tried also simply typing in "gs c start summoning" and nothing happens either, I summoned an avatar and nothing. Are there other files I need to add to my gearswap folder? Some other place to enter the execute command? I am at a loss here! Any help is appreciated.
The command you want is "gs load skillup.lua" - you can use "gs l skillup.lua" as a shortcut, but looks like that's be confused as "gs (one) skillup.lua" above.
i wrote this Gearswap-Skillup https://github.com/smd111/Gearswap-Skillup
the command to load it is (in chat)"//gs l skillup.lua" aka "//gs (lower case L) skillup.lua"
it has a menu system
and i recommend using SMN/GEO if you can
I just learnt to read ^^
question that's been frustrating me-
My RNG lua is set up with different pre/mid sets based upon which RMEA I currently have equipped (with different amounts of snapshot on the weapons themselves, this justifies differing preshot sets, and differing delays/styles justify differing midshot sets). My question is this- I would like to put a check in for times when I'm using a specific weapon AND AM3 is up (looking to build an AM3 set for my Gandiva, if the specifics help). However, I don't want to equip this set when using, say Fomalhaut and AM3 is up.
I'm comfortable with buff checks for gearsets (the "if buffactive['buffname'] then equipset(the sets/iterations)" logic), but what is the cleanest way to have something do that same buff check only when certain equipment is on?
well it looks like the forum is fixed
So I made up this rule to toggle backwards on my tp/dt sets. It works forwards and then backwards, but can't look back from the first set to the last set. Throws a concatenate error.
Any advice?
Code:elseif command == 'toggle backwards' then if DT == true then DT_ind = DT_ind -1 if DT_ind > #sets.DT.index then DT_ind = 1 end send_command('@input /echo <----- DT Set changed to ' .. sets.DT.index[DT_ind] .. ' ----->') ChangeGear(sets.DT[sets.DT.index[DT_ind]]) elseif DT == false then TP_ind = TP_ind -1 TizonaAM3_ind = TizonaAM3_ind -1 if TP_ind > #sets.TP.index then TP_ind = 1 end if TizonaAM3_ind > #sets.TizonaAM3.index then TizonaAM3_ind = 1 end if TizonaAM3 == true then ChangeGear(sets.TizonaAM3[sets.TizonaAM3.index[TizonaAM3_ind]]) send_command('@input /echo <----- Tizona TP Set changed to ' .. sets.TizonaAM3.index[TizonaAM3_ind] .. ' ----->') else ChangeGear(sets.TP[sets.TP.index[TP_ind]]) send_command('@input /echo <----- TP Set changed to ' .. sets.TP.index[TP_ind] .. ' ----->') end end
Your conditions are going to want to be like this instead, copy/paste/change for each _Ind
"If index less than 1, use highest index" rather than "If index greater than highest index, use 1"Code:if DT_ind < 1 then DT_ind = #sets.DT.index end