Item Search
     
BG-Wiki Search
Page 37 of 302 FirstFirst ... 27 35 36 37 38 39 47 87 ... LastLast
Results 721 to 740 of 6036

Thread: Gearswap Help Thread!     submit to reddit submit to twitter

  1. #721
    BG Content
    Join Date
    Jul 2007
    Posts
    22,393
    BG Level
    10
    FFXI Server
    Lakshmi
    Blog Entries
    1

    Code:
    sets.WS = {}
    sets.WS.Exenterator = {}
    sets.WS.Exenterator[1] = { ... stuff ... }
    sets.WS.Exenterator[2] = { ... stuff ... }
    You can't assign values to a table until you've declared that table. So, in english:
    Code:
    sets.WS (key string "WS" inside the sets table) = new empty table
    sets.WS.Exenterator (key string "Exenterator" inside the sets.WS table) = new empty table
    sets.WS.Exenterator[1] (key numerical 1 inside the Exenterator table) = new table with stuff in it
    sets.WS.Exenterator[2] (key numerical 2 inside the Exenterator table) = new table with stuff in it
    It could all be condensed into one declaration to avoid empty table declarations, but it's harder to read imop:
    Code:
    sets.WS = { Exenterator = { [1] = new table with stuff in it, [2] = new table with stuff in it } }

  2. #722
    Sea Torques
    Join Date
    Jul 2010
    Posts
    516
    BG Level
    5
    FFXI Server
    Bahamut

    Ok, that makes sense. Thanks!

    Edit: Er, well, maybe it does. I went through my Lua console printing the various tables at different points in the script.

    Code:
    sets.WS = {}
    At this point Lua knows that sets is a table (printing sets will give some random table identifier like 0x113c78), and WS is simply a string serving as a key to which there is no value assigned.

    Code:
    sets.WS.Exenterator = {}
    Now sets.WS is a table (printing confirms) and Exenterator is simply a string serving as a key.

    Code:
    sets.WS.Exenterator[1] = stuff
    sets.WS.Exenterator[2] = stuff
    Now sets.WS.Exenterator is a table with two key/value pairs. (1 and 2 are keys, stuff and stuff are values). Exenterator is still a string serving as a key in the sets.WS table (printing Exenterator doesn't give a table identifier) with no associated value.

    But if I look at this
    Code:
    sets.WS = { Exenterator = { [1] = new table with stuff in it, [2] = new table with stuff in it }}
    it looks like sets is a table with key WS (still a string) and value Exenterator. Exenterator is a table with keys 1 and 2, and values new table with stuff in it, new table with stuff in it.

    Exenterator can't simultaneously be a string and a table, though.

  3. #723
    Old Merits
    Join Date
    Sep 2010
    Posts
    1,094
    BG Level
    6
    FFXI Server
    Ragnarok

    Was Augment handling for delve gear(Mikinaak) ever worked out? I'm not sure if I'm doing this wrong, or it just doesn't work for those.

  4. #724
    BG Content
    Join Date
    Jul 2007
    Posts
    22,393
    BG Level
    10
    FFXI Server
    Lakshmi
    Blog Entries
    1

    Quote Originally Posted by Martel View Post
    Was Augment handling for delve gear(Mikinaak) ever worked out? I'm not sure if I'm doing this wrong, or it just doesn't work for those.
    I worked out the system and implemented it, but didn't have any duplicate pieces of armor to test with so I couldn't really debug it. I opened an issue and will probably get to it . . . at some point.

  5. #725
    Old Merits
    Join Date
    Sep 2010
    Posts
    1,094
    BG Level
    6
    FFXI Server
    Ragnarok

    Well, I have r15 dex and str mikinaak greaves if there's anything you'd like me to test for you.

  6. #726
    Hydra
    Join Date
    Feb 2014
    Posts
    131
    BG Level
    3
    FFXI Server
    Quetzalcoatl

    Hey guys, probably something I've overlooked, but how do you get verbose output to log files for gearswap? The instructions mention logging is enabled by default near the top of gearswap, but I don't have any logs being created. I'm assuming that is rererring to gearswap.lua, which has some mention of debugging being on/off, depending on whether or not a "bootstrap.lua" exists. (it does not)

    Just having some trouble finding information.

    Thanks!

  7. #727
    BG Content
    Join Date
    Jul 2007
    Posts
    22,393
    BG Level
    10
    FFXI Server
    Lakshmi
    Blog Entries
    1

    That's actually a debugging option (for me) that I leave in there because I'm too lazy to delete it each time. My logging shouldn't really be anything that you want to see. It's going to mostly be incredibly spammy.

    To answer your question, you enable it by making a file named bootstrap.lua and dropping it into your data folder. Again, though, it's not a useful option for users. Heck, I haven't even used it myself to debug stuff in a few versions.

  8. #728
    Sea Torques
    Join Date
    Jul 2010
    Posts
    516
    BG Level
    5
    FFXI Server
    Bahamut

    Is there a command for changing the value of variables directly from the chat line?

  9. #729
    BG Content
    Join Date
    Jul 2007
    Posts
    22,393
    BG Level
    10
    FFXI Server
    Lakshmi
    Blog Entries
    1

    No, use self command.

  10. #730
    Sea Torques
    Join Date
    Jul 2010
    Posts
    516
    BG Level
    5
    FFXI Server
    Bahamut

    Thanks, I didn't want to make a command for it if there already was one. I guess you could do something like this to mimic spellcast's "sc set variable value" command.
    Code:
    function self_command(command)
    
       if string.find(command, "set ") == 1 then
    
          splitCommand = {}
    
          _ = 1
    
          for i in string.gmatch (command, "%S+") do
             splitCommand[_]= i
             _ = _ +1
          end
    
       if string.find(command, "first_var") == 5 then first_var = splitCommand[3]
       elseif string.find(command, "second_var") then second_var = splitCommand[3] end
       ...
    
       end
    end

  11. #731
    BG Content
    Join Date
    Jul 2007
    Posts
    22,393
    BG Level
    10
    FFXI Server
    Lakshmi
    Blog Entries
    1

    Or something like:
    Code:
    function self_command(command)
        if command:sub(1,4) == 'set ' then
            split_command = string.split(command,' ')
            _G[split_command[2]] = tonumber(split_command[3]) or split_command[3]
        end
    end

  12. #732
    Sea Torques
    Join Date
    Jul 2010
    Posts
    516
    BG Level
    5
    FFXI Server
    Bahamut

    Oh, cool. That's way better. >.<

    I looked all over on the Reference Manual and didn't see the string.split() function.

  13. #733
    BG Content
    Join Date
    Jul 2007
    Posts
    22,393
    BG Level
    10
    FFXI Server
    Lakshmi
    Blog Entries
    1

    string.split is a function from stringhelper, Arcon's string manipulation library.

  14. #734
    Melee Summoner
    Join Date
    Dec 2009
    Posts
    26
    BG Level
    1
    FFXI Server
    Leviathan
    WoW Realm
    Hellscream

    Having trouble getting gs to recognize any of the newest gear (from Feb 2014 patch). Things like reforged relic/+1, Skirmish +1 gear, and Skirmish +2 weapons are simply ignored.

    Trying to investigate, I didn't find any of these items in the windower resources file... would adding them fix this or is that totally irrelevant? If they are needed, how would one manually add the items (item IDs etc) to resources? I think gearswap amazing, but I have no clue what I'm doing.

    To workaround, I've put a lot of the items in macros but that is far from ideal.

    (To give you an idea of my understanding of gearswap: I followed "Gearswap for Dummies" and applied it to my WHM. For now, most of it is beyond me but the file does work (yay) . . .minus the new items).

  15. #735
    BG Content
    Join Date
    Jul 2007
    Posts
    22,393
    BG Level
    10
    FFXI Server
    Lakshmi
    Blog Entries
    1

    It sounds like your resources aren't updating for whatever reason. Try doing //updateresources. If that doesn't work . . . I don't know, post back.

  16. #736
    Sea Torques
    Join Date
    Aug 2007
    Posts
    725
    BG Level
    5
    FFXI Server
    Ramuh

    Using mote scripts, as blm/sch can't cast Sleepga 2/Sleepga, what could the issue be?

  17. #737
    Melee Summoner
    Join Date
    Dec 2009
    Posts
    26
    BG Level
    1
    FFXI Server
    Leviathan
    WoW Realm
    Hellscream

    Quote Originally Posted by Byrthnoth View Post
    It sounds like your resources aren't updating for whatever reason. Try doing //updateresources. If that doesn't work . . . I don't know, post back.
    Wonder why they aren't updating automatically. . . in any case, thanks. Several files updated and I imagine things will work fine now.

  18. #738
    Salvage Bans
    Join Date
    Mar 2010
    Posts
    769
    BG Level
    5
    FFXI Server
    Leviathan

    I keep getting the error: "attempt to call global 'ear1' (a nil value)."

    Any help with this?

  19. #739
    Old Merits
    Join Date
    Sep 2010
    Posts
    1,094
    BG Level
    6
    FFXI Server
    Ragnarok

    Looks like its reading ear1 as a variable, rather than an equip slot. And ear1 isn't set to anything, so it returns nil. Kinda hard to say what's actually causing that without seeing the file though.

  20. #740
    BG Content
    Join Date
    Jul 2007
    Posts
    22,393
    BG Level
    10
    FFXI Server
    Lakshmi
    Blog Entries
    1

    It means that you have ear1() somewhere.

Page 37 of 302 FirstFirst ... 27 35 36 37 38 39 47 87 ... LastLast

Similar Threads

  1. Replies: 6547
    Last Post: 2014-07-08, 22:45