Great, thanks! I know what I'm stuck doing this week![]()
Great, thanks! I know what I'm stuck doing this week![]()
Where exactly do we putto make use of this?Code:require 'organizer-lib'
Also when you do that the first way with the freeze command does it freeze both your bag and wardrobe at the same time?
@ Scythe My disable back feature works fine, might be an issue on ur PC/file
You could put it anywhere in your gearswap file.
The freeze command takes bags as arguments, so you can specify which bags you'd like to freeze. It defaults to freezing all of them.
ahh ok so we can jsut list more than 1 and it would work. thanks
Just wondering, I've always used //gs o but everyone always says //gs org.
Do they do the same thing or is there a slight difference?
Can provide some insight for adjusting stratagem recast timer and current stratagem count after getting the SCH 550 job point gift?
I have fiddled around and it accurately shows the recast for the first stratagem, but anymore after that and it jumbles up how many current strats I have.
Well i'm a returning player and finally got enough jp for utsusemi san, I'm having trouble getting gearswap to recognize it as A utsusemi spell though, I've updated the spell mapping can some help me figure out what else i might be missing
Check that your resources is up to date. in your res folder look for the spells file and search for utsusemi
Thanks it is update, well Utsusemi San is there any other suggestions?
Check and make sure the Utsu line in Mote-Mappings is just like
['Utsusemi: Ichi']='Utsusemi',['Utsusemi: Ni']='Utsusemi',['Utsusemi: San']='Utsusemi',
Here is a new NIN tool Map
nin_tool_map[string.mgsub(spell.en, ": Ichi|: Ni|: San", "")].tool.name --is the normal tool for spellCode:nin_tool_map = { ['Katon'] = {tool = res.items[1161],tool_b = res.items[5308],u_tool = res.items[2971],u_tool_b = res.items[5867]}, ['Hyoton'] = {tool = res.items[1164],tool_b = res.items[5309],u_tool = nin_tool_map['Katon'].u_tool,nin_tool_map['Katon'].u_tool_b}, ['Huton'] = {tool = res.items[1167],tool_b = res.items[5310],u_tool = nin_tool_map['Katon'].u_tool,u_tool_b = nin_tool_map['Katon'].u_tool_b}, ['Doton'] = {tool = res.items[1170],tool_b = res.items[5311],u_tool = nin_tool_map['Katon'].u_tool,u_tool_b = nin_tool_map['Katon'].u_tool_b}, ['Raiton'] = {tool = res.items[1173],tool_b = res.items[5312],u_tool = nin_tool_map['Katon'].u_tool,u_tool_b = nin_tool_map['Katon'].u_tool_b}, ['Suiton'] = {tool = res.items[1176],tool_b = res.items[5313],u_tool = nin_tool_map['Katon'].u_tool,u_tool_b = nin_tool_map['Katon'].u_tool_b}, ['Utsusemi'] = {tool = res.items[1179],tool_b = res.items[5314],u_tool = res.items[2972],u_tool_b = res.items[5868]}, ['Tonko'] = {tool = res.items[1194],tool_b = res.items[5319],u_tool = nin_tool_map['Utsusemi'].u_tool,u_tool_b = nin_tool_map['Utsusemi'].u_tool_b}, ['Monomi'] = {tool = res.items[2553],tool_b = res.items[5417],u_tool = nin_tool_map['Utsusemi'].u_tool,u_tool_b = nin_tool_map['Utsusemi'].u_tool_b}, ['Myoshu'] = {tool = res.items[2642],tool_b = res.items[5863],u_tool = nin_tool_map['Utsusemi'].u_tool,u_tool_b = nin_tool_map['Utsusemi'].u_tool_b}, ['Migawari'] = {tool = res.items[2970],tool_b = res.items[5866],u_tool = nin_tool_map['Utsusemi'].u_tool,u_tool_b = nin_tool_map['Utsusemi'].u_tool_b}, ['Kakka'] = {tool = res.items[2644],tool_b = res.items[5865],u_tool = nin_tool_map['Utsusemi'].u_tool,u_tool_b = nin_tool_map['Utsusemi'].u_tool_b}, ['Gekka'] = {tool = res.items[8803],tool_b = res.items[6265],u_tool = nin_tool_map['Utsusemi'].u_tool,u_tool_b = nin_tool_map['Utsusemi'].u_tool_b}, ['Yain'] = {tool = res.items[8804],tool_b = res.items[6266],u_tool = nin_tool_map['Utsusemi'].u_tool,u_tool_b = nin_tool_map['Utsusemi'].u_tool_b}, ['Jubaku'] = {tool = res.items[1182],tool_b = res.items[5315],u_tool = res.items[2973],u_tool_b = res.items[5869]}, ['Hojo'] = {tool = res.items[1185],tool_b = res.items[5316],u_tool = nin_tool_map['Jubaku'].u_tool,u_tool_b = nin_tool_map['Jubaku'].u_tool_b}, ['Kurayami'] = {tool = res.items[1188],tool_b = res.items[5317],u_tool = nin_tool_map['Jubaku'].u_tool,u_tool_b = nin_tool_map['Jubaku'].u_tool_b}, ['Dokumori'] = {tool = res.items[1191],tool_b = res.items[5318],u_tool = nin_tool_map['Jubaku'].u_tool,u_tool_b = nin_tool_map['Jubaku'].u_tool_b}, ['Aisha'] = {tool = res.items[2555],tool_b = res.items[5734],u_tool = nin_tool_map['Jubaku'].u_tool,u_tool_b = nin_tool_map['Jubaku'].u_tool_b}, ['Yurin'] = {tool = res.items[2643],tool_b = res.items[5864],u_tool = nin_tool_map['Jubaku'].u_tool,u_tool_b = nin_tool_map['Jubaku'].u_tool_b}, }
nin_tool_map[string.mgsub(spell.en, ": Ichi|: Ni|: San", "")].tool_b.name -- is the normal tool bag for spell
nin_tool_map[string.mgsub(spell.en, ": Ichi|: Ni|: San", "")].u_tool.name -- is the multi tool for spell
nin_tool_map[string.mgsub(spell.en, ": Ichi|: Ni|: San", "")].u_tool_b.name -- is the multi tool bag for spell
Having issues with Mote's SCH gearswap:
Have adjusted the equipment, but the original is giving the same error message too:
http://pastebin.com/6ZBvQqat
Its saying:
lua runtime error: gearswap /flow.lua:295:
gearswap has detected an error in the user function self_command:
...SCH.lua:432: attempt to index field 'Defense' (a nil value)
Any ideas how to resolve this?
I change the file name to BLM.lua, switched to blm to see if it loaded and it did, no issues at all, however when using it on SCH it doesn't work!
I've got mote's includes
Still using Mote's libs. Currently trying to use Itemizer to move Hybrid Mode sets back and forth between my bag and Mog Case since I don't usually need them. I expanded the state-change function that came with the RDM.lua I've been working from to include those modes.
The official command reference doesn't actually explain how pairs is supposed to behave. Even worse, according to the error messages I've been getting, the value of stupidThing refuses to be anything but nil--even though it should be getting assigned something.Code:function job_state_change(stateField, newValue, oldValue) if stateField == 'Offense Mode' then if newValue == 'Magic' then enable('main','sub','range') else disable('main','sub','range') end elseif stateField == 'Hybrid Mode' then if oldValue ~= 'Normal' then oldSet = sets.engaged.oldValue else oldSet = sets.engaged end if newValue ~= 'Normal' then newSet = sets.engaged.newValue else newSet = sets.engaged end itemize_sets(oldSet, newSet) elseif stateField == 'Casting Mode' then if newValue ~= 'Healing' then disable('main','sub','range') end end end function itemize_sets(putset, getset) --put unneeded stuff away for krap,shyt in pairs(putset) do local stupidThing = 'blah' if type(shyt) == "table" then stupidThing = shyt.name elseif type(shyt) == "string" then stupidThing = shyt else --these were to test if shyt was even getting through at all. evidently, it isn't, but... stupidThing = 'White Drop' end --these send_commands never work. stupidThing isn't holding a value at all. send_command('put "' .. stupidThing .. '" case') end --get needed stuff out for krap,shyt in pairs(getset) do local stupidThing = 'blah' if type(shyt) == "table" then stupidThing = shyt.name elseif type(shyt) == "string" then stupidThing = shyt else stupidThing = 'White Drop' end send_command('get "' .. stupidThing .. '"') end end
All I want is to get the strings back out of the table one at a time so I can run them through Itemizer. Once that works, I get to try to implement case statements in this barbaric language. Any help would be greatly appreciated.
This makes absolutely no sense. That script doesn't even do anything with 'Defense' that far down, and there's no reason it should work for BLM but not SCH. I'm no expert, but it sounds like the Lua interpreter itself is shitting the bed. Hard.
try this
Code:function itemize_sets(putset, getset) --check to make sure whats being given if putset ~= nil then print("putset = "..putset)--should show as "putset = table########" end if getset ~= nil then print("getset = "..getset)--should show as "getset = table########" end --saves your butt if one is nil if putset == nil or getset == nil then return end --put unneeded stuff away for i,v in pairs(putset) do local put if type(v) == "table" then put = v.name else put = v end --print(put)--uncomment to see what the gear it is trying to put send_command('put "'..put..'" case') end --get needed stuff out for i,v in pairs(getset) do local get if type(v) == "table" then get = v.name else get = v end --print(get)--uncomment to see what the gear it is trying to put send_command('get "'..get..'"') end end
When I do it like this, I get an error message bitching about trying to concatenate a table value into a string, which makes me wonder just how badly Luacore got gutted in comparison to an actual Lua interpreter. Changing the lines to simply confirm putset/getset are there works--however, getset is inexplicably nil 2/3 of the times I try, and the other 1/3 of the time, get ends up being nil. I'm about ready to scrap this and just go bang my head against the lack of anything resembling a case statement. I'd already have that one figured out if there was a working load() function, actually.
Dumb question--what's the difference between using include() and using require to load libs?
There is no difference inside a gearswap user file. I have both Include and Require so both Spellcast and Lua people feel comfortable, but neither of them are actually the normal Lua require function.
I've never run into a situation where Luacore works differently than any the Lua manuals would expect.
include() is a gearswap require() that also looks in the geaswap sub dir while require() only looks in libs,and the specific addons folder
i think for some reason newSet is not updating
try this and tell me the out put
Code:function job_state_change(stateField, newValue, oldValue) if stateField == 'Offense Mode' then if newValue == 'Magic' then enable('main','sub','range') else disable('main','sub','range') end elseif stateField == 'Hybrid Mode' then if oldValue ~= 'Normal' then oldSet = sets.engaged.oldValue else oldSet = sets.engaged end if newValue ~= 'Normal' then newSet = sets.engaged.newValue else newSet = sets.engaged end print(oldSet,newSet) elseif stateField == 'Casting Mode' then if newValue ~= 'Healing' then disable('main','sub','range') end end end
Without trying it I can tell you the output is going to be an error message complaining about trying to print tables.
EDIT: Using print(type(oldSet)) and print(type(newSet)) reveals that once again newSet is nil. It shouldn't be, because I have sets defined for each Hybrid Mode. Which raises a new question: Can anyone confirm whether changing HybridMode actually does anything at all, ever?
I've run into several differences just today, particularly load() accepting only functions and not strings, along with implicit conversions just not happening. You're an open-source guy, right?