Item Search
     
BG-Wiki Search
Closed Thread
Page 165 of 302 FirstFirst ... 115 155 163 164 165 166 167 175 215 ... LastLast
Results 3281 to 3300 of 6036

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

  1. #3281

    Quote Originally Posted by Sechs View Post
    I want to imbue a "//cancel spellname" into Gearswap for Vallation/Valiance.
    They do not overwrite themselves or each other, so if I already have one of them active and I want to refresh it, I would have to cancel the previous buff first.
    But this needs to happen only when the JA is really off the cooldown and goes through (i.e. it's ready and it doesn't get blocked by Amnesia or Paralyze) and/or when the buff is active.
    Checking for buffactive is safe in this context, because it won't be fast enough that the client-server update thing would affect it, but what would be the smartest route for me to follow?

    I have several things in mind but looking for suggestions and ideas first.
    to use a string var as part of another string you need to use ..
    i.e, to cancel a buff using the spell.name do this(this will only work if the spell name is the same as the buff)
    send_command('//Cancle '..spell.name)

  2. #3282
    Campaign
    Join Date
    Jul 2007
    Posts
    6,633
    BG Level
    8

    For this special situation I don't think I need to use a string var within the string command. I can just use "//cancel Vallation", since both JAs (Vallation and Valiance) give the same buff.
    I was more thinking about how to organize the logic behind it.
    I assume this has to be in the precast.

    Code:
    ..
    If spell.english == 'Vallation' or spell.english == 'Valiance' then
    send_command('@input /cancel Vallation')
    equip(sets.precast[spell.english])
    ..
    I could add a further check "if buffactive" but then I thought it would have been an useless additional line so decided to skip it.


    My main concern here are the following 5 situations:
    1. I attempt to use Vallation/Valiance while the Global Cooldown is not ready
    2. I attempt to use Vallation/Valiance while casting a spell
    3. I attempt to use Vallation/Valiance when the JA is not ready yet
    4. I attempt to use Vallation/Valiance with Amnesia up
    5. I attempt to use Vallation/Valiance but Paralysys eats it


    I should be already fine for 2). I have a rule that avoids processing precast if I'm currently casting.
    I'm afraid for the other 4 situations though Precast would be processed by Gearswap, and Vallation would be cancelled.
    Correct?
    If I'm right then, I need to think about how to avoid cancelling Vallation in situations 1), 3), 4) and 5).
    Would "if not spell.interrupted" be enough to handle these 4 situations?

  3. #3283
    Melee Summoner
    Join Date
    Jul 2014
    Posts
    44
    BG Level
    1
    FFXI Server
    Phoenix

    Im using motenten's lua for my drg but i can switch offense modes. It stayes on normal. Anyone here know what i need to change?

  4. #3284
    Sea Torques
    Join Date
    Jul 2009
    Posts
    679
    BG Level
    5
    FFXI Server
    Leviathan

    (DRG) Healing Breath with pet_precast/pet_midcast?

    Can Healing Breath potency swaps ever work reliably with pet_precast/pet_midcast? I have my function swaps like so:

    Code:
    function midcast(spell)
    	if spell.action_type == 'Magic' then
    		equip(sets.breath.HBTrigger)
    	end
    end
    
    function aftercast(spell)
    	-- if you don't check for pet_midaction() here, you'll have a conflict with pet_aftercast
    	-- if our spell got interrupted, obviously our pet won't use its breath ability
    	if not pet_midaction() or spell.interrupted then
    		equip_aftercast()
    	end
    end
    
    function equip_aftercast()
    	if player.status == 'Engaged' then
    		equip(sets.tp)
    	elseif player.status == 'Idle' then
    		equip(sets.idle)
    	end
    end
    
    function pet_precast(spell)
    	-- not sure if both precast and midcast need to have the swaps, but midcast does for sure
    	equip(sets.breath.Potency)
    end
    
    function pet_midcast(spell)
    	equip(sets.breath.Potency)
    end
    
    function pet_aftercast(spell)
    	equip_aftercast()
    end
    Most of the time, this works. My hbtrigger gear swaps in reliably every time, but even in low latency areas, my potency gear occasionally fails to swap in at the correct time. I'd say its reliable about 98% of the time when its just me and a bunny, but when there's a moderate amount of action going on, it drops to about 50%.

    Do I need to give up on this and just start using delay & equip commands, or is there some way for this to work 100% of the time?

  5. #3285

    Quote Originally Posted by Cymmina View Post
    Can Healing Breath potency swaps ever work reliably with pet_precast/pet_midcast? I have my function swaps like so:

    Code:
    function midcast(spell)
    	if spell.action_type == 'Magic' then
    		equip(sets.breath.HBTrigger)
    	end
    end
    
    function aftercast(spell)
    	-- if you don't check for pet_midaction() here, you'll have a conflict with pet_aftercast
    	-- if our spell got interrupted, obviously our pet won't use its breath ability
    	if not pet_midaction() or spell.interrupted then
    		equip_aftercast()
    	end
    end
    
    function equip_aftercast()
    	if player.status == 'Engaged' then
    		equip(sets.tp)
    	elseif player.status == 'Idle' then
    		equip(sets.idle)
    	end
    end
    
    function pet_precast(spell)
    	-- not sure if both precast and midcast need to have the swaps, but midcast does for sure
    	equip(sets.breath.Potency)
    end
    
    function pet_midcast(spell)
    	equip(sets.breath.Potency)
    end
    
    function pet_aftercast(spell)
    	equip_aftercast()
    end
    Most of the time, this works. My hbtrigger gear swaps in reliably every time, but even in low latency areas, my potency gear occasionally fails to swap in at the correct time. I'd say its reliable about 98% of the time when its just me and a bunny, but when there's a moderate amount of action going on, it drops to about 50%.

    Do I need to give up on this and just start using delay & equip commands, or is there some way for this to work 100% of the time?
    first there is no pet_precast

  6. #3286
    RIDE ARMOR
    Join Date
    Jul 2013
    Posts
    22
    BG Level
    1
    FFXI Server
    Siren

    Could someone show me how to setup a function to equip Oneiros Ring if the latent is active? Thanks in advance.

  7. #3287

    Quote Originally Posted by Fall View Post
    Could someone show me how to setup a function to equip Oneiros Ring if the latent is active? Thanks in advance.
    if player.mp >= 100 then

  8. #3288

    Hi there, I'm just coming back to FFXI to find Spellcast unsupported, so I'm trying to figure out GearSwap, but none of my swaps are working. What am I doing wrong here?

    Spoiler: show
    Code:
    -------------------  Gear Sets  ----------------------
    function get_sets() 
        -------------------  Engaged Sets  ----------------------
        sets.engaged = {}
        sets.engaged.reward={
        ammo="Pet Food Zeta",
        head="Bison Warbonnet",
        body="Bst. Jackcoat +1",
        hands="Ogre Gloves",
        legs={ name="Mst. Trousers +2", augments={'Enhances "Familiar" effect',}},
        feet={ name="Mst. Gaiters +2", augments={'Enhances "Beast Healer" effect',}},
        neck="Promise Badge",
        waist="Crudelis Belt",
        right_ear="Celestial Earring",
        left_ring="Solemn Ring",
        }
        sets.engaged.petcmd={
        hands="Frn. Manoplas +2",
        feet="Ferine Ocreae +2",
        }
        sets.engaged.tp={
            main={ name="Astolfo", augments={'AGI+11','Pet: Evasion+22',}},
            sub={ name="Astolfo", augments={'VIT+11','Pet: Phys. dmg. taken -11%',}},
            head="Zelus Tiara",
            body="Ferine Gausape +2",
            hands="Brego Gloves",
            legs="Calmecac Trousers",
            feet="Phorcys Schuhs",
            neck="Ferine Necklace",
            waist="Twilight Belt",
            left_ear="Brutal Earring",
            right_ear="Suppanomimi",
            left_ring="Keen Ring",
            right_ring="Epona's Ring",
            back="Atheling Mantle",
        }
        -------------------  Idle Combat Sets  ----------------------
        sets.idle = {}
        sets.idle.pettank={
            main={ name="Astolfo", augments={'AGI+11','Pet: Evasion+22',}},
            sub={ name="Astolfo", augments={'VIT+11','Pet: Phys. dmg. taken -11%',}},
            head={ name="Anwig Salade", augments={'Attack+3','Pet: Damage taken -10%','Attack+3','Pet: "Regen"+1',}},
            body="Ferine Gausape +2",
            hands="Frn. Manoplas +2",
            legs="Ferine Quijotes +2",
            feet="Ferine Ocreae +2",
            neck="Ferine Necklace",
            waist="Primal Belt",
            left_ear="Ferine Earring",
            right_ear="Ethereal Earring",
            back="Oneiros Cappa",
        }
        sets.idle.reward={
        main="Zoraal Ja's Axe",
        sub="Zoraal Ja's Axe",
        ammo="Pet Food Zeta",
        head="Bison Warbonnet",
        body="Bst. Jackcoat +1",
        hands="Ogre Gloves",
        legs={ name="Mst. Trousers +2", augments={'Enhances "Familiar" effect',}},
        feet={ name="Mst. Gaiters +2", augments={'Enhances "Beast Healer" effect',}},
        neck="Promise Badge",
        waist="Crudelis Belt",
        right_ear="Celestial Earring",
        left_ring="Solemn Ring",
        }
        sets.idle.petcmd={
        main="Charmer's Merlin",
        hands="Frn. Manoplas +2",
        feet="Ferine Ocreae +2",
        }
        -------------------  JA Sets  ----------------------
        sets.precast = {}
        sets.precast.JA = {}
        sets.precast.JA.call={
        hands={ name="Mst. Gloves +2", augments={'Enhances "Beast Affinity" effect',}},
        }
        sets.precast.JA.charm={
        head={ name="Mst. Helm +2", augments={'Enhances "Killer Instinct" effect',}},
        body="Bst. Jackcoat +1",
        hands={ name="Mst. Gloves +2", augments={'Enhances "Beast Affinity" effect',}},
        legs="Bst. Trousers +1",
        feet={ name="Mst. Gaiters +2", augments={'Enhances "Beast Healer" effect',}},
        }
        sets.precast.JA.waltz={
        ammo="Light Sachet",
        head="Ferine Cabasset +2",
        body={ name="Kirin's Osode", augments={'Attack+4',}},
        hands="Ample Gloves",
        legs="Ferine Quijotes +2",
        neck="Ferine Necklace",
        waist="Aristo Belt",
        left_ring="Dawnsoul Ring",
        right_ring="Airy Ring",
        back="Aisance Mantle",
    }
        -------------------  Weaponskill Sets  ----------------------
        sets.precast.WS={
        head="Nocturnus Helm",
        body="Ferine Gausape +2",
        hands="Frn. Manoplas +2",
        legs="Ferine Quijotes +2",
        feet="Alcide's Leggings",
        neck="Ferine Necklace",
        waist="Cuchulain's Belt",
        left_ear="Ghillie Earring",
        right_ear="Ghillie Earring",
        left_ring="Keen Ring",
        right_ring="Demonry Ring",
        back="Atheling Mantle",
        }
        sets.precast.WS.Soil={
        head="Nocturnus Helm",
        body="Ferine Gausape +2",
        hands="Frn. Manoplas +2",
        legs="Ferine Quijotes +2",
        feet="Alcide's Leggings",
        neck="Soil Gorget",
        waist="Soil Belt",
        left_ear="Ghillie Earring",
        right_ear="Ghillie Earring",
        left_ring="Keen Ring",
        right_ring="Demonry Ring",
        back="Atheling Mantle",
        }
        sets.precast.WS.Aqua={
        head="Nocturnus Helm",
        body="Ferine Gausape +2",
        hands="Frn. Manoplas +2",
        legs="Ferine Quijotes +2",
        feet="Alcide's Leggings",
        neck="Aqua Gorget",
        waist="Aqua Belt",
        left_ear="Ghillie Earring",
        right_ear="Ghillie Earring",
        left_ring="Keen Ring",
        right_ring="Demonry Ring",
        back="Atheling Mantle",
    }
        -------------------  Trigger Gear Sets  ----------------------
        gear = {}
        gear.axe={
        main={ name="Astolfo", augments={'AGI+11','Pet: Evasion+22',}},
        sub={ name="Astolfo", augments={'VIT+11','Pet: Phys. dmg. taken -11%',}},
        }
        gear.H2H={
        main="Afflictors",
        }
        gear.dagger={
        main="Galkan Dagger",
        sub="Pallas's Shield",
        }
        gear.club={
        main="Rounsey Wand",
        sub="Pallas's Shield",
        }
        gear.scythe={
        main="Bounty Sickle",
        sub="Danger Grip",
        }
        gear.staff={
        main="Iridal Staff",
        sub="Danger Grip",
        }
            
    end
    
        -------------------  Gear Swap Rules  ----------------------
    
    function precast(spell)
        if spell.type == 'Waltz' then
            equip(sets.precast.JA.waltz)
        elseif spell.type == 'WeaponSkill' then
            equip(sets.precast.WS)
        elseif spell.name == 'Avalanche Axe' or spell.name == 'Calamity' or spell.name == 'Primal Rend' or spell.name == 'Rampage' or spell.name == 'Onslaught' or spell.name == 'Spinning Axe' then
            equip(sets.precast.WS.Soil)
        elseif spell.name == 'Decimation' or spell.name == 'Smash Axe' or spell.name == 'Ruinator' then
            equip(sets.precast.WS.Aqua)
        elseif spell.name == 'Call Beast' then
            equip(sets.precast.JA.call)
        elseif spell.name == 'Charm' then
            equip(sets.precast.JA.charm)
        elseif spell.type == 'PetCommand' and status == 'Engaged' then
            equip(sets.engaged.petcmd)
        elseif spell.type == 'PetCommand' and status == 'Idle' then
            equip(sets.idle.petcmd)
        elseif spell.name == 'Reward' and status == 'Engaged' then
            equip(sets.engaged.reward)
        elseif spell.type == 'Reward' and status == 'Idle' then
            equip(sets.idle.reward)
        end
    end
    
    function status_change(new,old)
        if new == 'Engaged' then
            equip(sets.engaged.TP)
        else
            equip(sets.idle.pettank)
        end
    end
    
    function aftercast(spell)
        if player.status == 'Engaged' then
            equip(sets.engaged.TP)
        else
            equip(sets.idle.pettank)
        end
    end

  9. #3289

    Quote Originally Posted by ToadieOdie View Post
    Hi there, I'm just coming back to FFXI to find Spellcast unsupported, so I'm trying to figure out GearSwap, but none of my swaps are working. What am I doing wrong here?
    what errors are showing in the windower console

    --edit--
    after reading through the file is seams that this is your error
    Code:
    -------------------  Weaponskill Sets  ----------------------
        sets.precast.WS={
        head="Nocturnus Helm",
        body="Ferine Gausape +2",
        hands="Frn. Manoplas +2",
        legs="Ferine Quijotes +2",
        feet="Alcide's Leggings",
        neck="Ferine Necklace",
        waist="Cuchulain's Belt",
        left_ear="Ghillie Earring",
        right_ear="Ghillie Earring",
        left_ring="Keen Ring",
        right_ring="Demonry Ring",
        back="Atheling Mantle",
        }
        sets.precast.WS.Soil={
        head="Nocturnus Helm",
    here is the fix
    Code:
        -------------------  Weaponskill Sets  ----------------------
        sets.precast.WS ={}
        sets.precast.WS.normal={
        head="Nocturnus Helm",
        body="Ferine Gausape +2",
        hands="Frn. Manoplas +2",
        legs="Ferine Quijotes +2",
        feet="Alcide's Leggings",
        neck="Ferine Necklace",
        waist="Cuchulain's Belt",
        left_ear="Ghillie Earring",
        right_ear="Ghillie Earring",
        left_ring="Keen Ring",
        right_ring="Demonry Ring",
        back="Atheling Mantle",
        }
        sets.precast.WS.Soil={
        head="Nocturnus Helm",
    and this will never work
    Code:
       elseif spell.type == 'WeaponSkill' then
            equip(sets.precast.WS)
        elseif spell.name == 'Avalanche Axe' or spell.name  == 'Calamity' or spell.name == 'Primal Rend' or spell.name == 'Rampage'  or spell.name == 'Onslaught' or spell.name == 'Spinning Axe' then
            equip(sets.precast.WS.Soil)
        elseif spell.name == 'Decimation' or spell.name == 'Smash Axe' or spell.name == 'Ruinator' then
            equip(sets.precast.WS.Aqua)
    so use this
    Code:
        elseif spell.name == 'Avalanche Axe' or spell.name == 'Calamity' or spell.name == 'Primal Rend' or spell.name == 'Rampage' or spell.name == 'Onslaught' or spell.name == 'Spinning Axe' then
            equip(sets.precast.WS.Soil)
        elseif spell.name == 'Decimation' or spell.name == 'Smash Axe' or spell.name == 'Ruinator' then
            equip(sets.precast.WS.Aqua)
        elseif spell.type == 'WeaponSkill' then
            equip(sets.precast.WS.normal)

  10. #3290

    Thank you, I've made the changes and I'll test it out soon.

    The weird thing, and most frustrating, was I wasn't getting any error message. I had no idea where to begin to troubleshoot.

  11. #3291

    Quote Originally Posted by ToadieOdie View Post
    Thank you, I've made the changes and I'll test it out soon.

    The weird thing, and most frustrating, was I wasn't getting any error message. I had no idea where to begin to troubleshoot.
    let me know how things are going

  12. #3292

    still not working, wont even equip the idle set after i made the changes and loaded the game fresh

  13. #3293

    Quote Originally Posted by ToadieOdie View Post
    still not working, wont even equip the idle set after i made the changes and loaded the game fresh
    use the commands(in this order)
    --displays console activity
    //console_displayactivity 1
    --creats a file in windower folder called console.log
    //console_log 1
    --reload gearswap
    //lua reload gearswap
    --shows function calls and gear that does not change
    //gs debug_mode
    --shows gear that changes
    //gs show_swaps

    then post the console.log file here

  14. #3294

    I did as you said and then ran around killing a few mobs and this is all i got in the console log file:

    21:57:27 > Unloaded addon: GearSwap.
    21:57:28 > Addon: GearSwap (author: Byrth, version: 0.892) loaded successfully.
    21:57:43 > GearSwap: Debug Mode set to true.
    21:57:53 > GearSwap: Show Swaps set to true.

    and still nothing swapped

  15. #3295

    now i know whats going on
    in the windower/addon/gearswap/data folder create a new folder with your chars name
    i.e. if the players name is billybob the folder should be windower/addon/gearswap/data/billybob

    then put your BST.lua in that folder
    the naming convention for files is
    <playername>_<mainjobshort>.lua --if you put the file alone in the data folder i.e. for Dancer use billybob_DNC.lua
    if you use a folder for each char you have use
    <mainjobshort>.lua --i.e. for Dancer use DNC.lua

  16. #3296

    well I feel stupid now. lol but that fixed the problem, thank you very much!

  17. #3297

    no problem some times we have brain farts

    by the way here is a mor efficiant way to do ws's in your precast
    Code:
    function precast(spell)
        if spell.type == 'Waltz' then
            equip(sets.precast.JA.waltz)
        elseif spell.type == 'WeaponSkill' then
            if spell.name == 'Avalanche Axe' or spell.name == 'Calamity' or spell.name == 'Primal Rend' or spell.name == 'Rampage' or spell.name == 'Onslaught' or spell.name == 'Spinning Axe' then
                equip(sets.precast.WS.Soil)
            elseif spell.name == 'Decimation' or spell.name == 'Smash Axe' or spell.name == 'Ruinator' then
                equip(sets.precast.WS.Aqua)
            else
                equip(sets.precast.WS.normal)
            end
        elseif spell.name == 'Call Beast' then
            equip(sets.precast.JA.call)
        elseif spell.name == 'Charm' then
            equip(sets.precast.JA.charm)
        elseif spell.type == 'PetCommand' and status == 'Engaged' then
            equip(sets.engaged.petcmd)
        elseif spell.type == 'PetCommand' and status == 'Idle' then
            equip(sets.idle.petcmd)
        elseif spell.name == 'Reward' and status == 'Engaged' then
            equip(sets.engaged.reward)
        elseif spell.type == 'Reward' and status == 'Idle' then
            equip(sets.idle.reward)
        end
    end

  18. #3298

    Thank you, I'll make the change. ^_^

  19. #3299

    actually here is a fully rewritten code to be efficient
    Spoiler: show
    Code:
    -------------------  Gear Sets  ----------------------
    function get_sets() 
        -------------------  Engaged Sets  ----------------------
        sets.Engaged = {}
        sets.Engaged.reward={
        ammo="Pet Food Zeta",
        head="Bison Warbonnet",
        body="Bst. Jackcoat +1",
        hands="Ogre Gloves",
        legs={ name="Mst. Trousers +2", augments={'Enhances "Familiar" effect',}},
        feet={ name="Mst. Gaiters +2", augments={'Enhances "Beast Healer" effect',}},
        neck="Promise Badge",
        waist="Crudelis Belt",
        right_ear="Celestial Earring",
        left_ring="Solemn Ring",
        }
        sets.Engaged.petcmd={
        hands="Frn. Manoplas +2",
        feet="Ferine Ocreae +2",
        }
        sets.Engaged.tp={
            main={ name="Astolfo", augments={'AGI+11','Pet: Evasion+22',}},
            sub={ name="Astolfo", augments={'VIT+11','Pet: Phys. dmg. taken -11%',}},
            head="Zelus Tiara",
            body="Ferine Gausape +2",
            hands="Brego Gloves",
            legs="Calmecac Trousers",
            feet="Phorcys Schuhs",
            neck="Ferine Necklace",
            waist="Twilight Belt",
            left_ear="Brutal Earring",
            right_ear="Suppanomimi",
            left_ring="Keen Ring",
            right_ring="Epona's Ring",
            back="Atheling Mantle",
        }
        -------------------  Idle Combat Sets  ----------------------
        sets.Idle = {}
        sets.Idle.pettank={
            main={ name="Astolfo", augments={'AGI+11','Pet: Evasion+22',}},
            sub={ name="Astolfo", augments={'VIT+11','Pet: Phys. dmg. taken -11%',}},
            head={ name="Anwig Salade", augments={'Attack+3','Pet: Damage taken -10%','Attack+3','Pet: "Regen"+1',}},
            body="Ferine Gausape +2",
            hands="Frn. Manoplas +2",
            legs="Ferine Quijotes +2",
            feet="Ferine Ocreae +2",
            neck="Ferine Necklace",
            waist="Primal Belt",
            left_ear="Ferine Earring",
            right_ear="Ethereal Earring",
            back="Oneiros Cappa",
        }
        sets.Idle.reward={
        main="Zoraal Ja's Axe",
        sub="Zoraal Ja's Axe",
        ammo="Pet Food Zeta",
        head="Bison Warbonnet",
        body="Bst. Jackcoat +1",
        hands="Ogre Gloves",
        legs={ name="Mst. Trousers +2", augments={'Enhances "Familiar" effect',}},
        feet={ name="Mst. Gaiters +2", augments={'Enhances "Beast Healer" effect',}},
        neck="Promise Badge",
        waist="Crudelis Belt",
        right_ear="Celestial Earring",
        left_ring="Solemn Ring",
        }
        sets.Idle.petcmd={
        main="Charmer's Merlin",
        hands="Frn. Manoplas +2",
        feet="Ferine Ocreae +2",
        }
        -------------------  JA Sets  ----------------------
        sets.precast = {}
        sets.precast.JA = {}
        sets.precast.JA.call={
        hands={ name="Mst. Gloves +2", augments={'Enhances "Beast Affinity" effect',}},
        }
        sets.precast.JA.charm={
        head={ name="Mst. Helm +2", augments={'Enhances "Killer Instinct" effect',}},
        body="Bst. Jackcoat +1",
        hands={ name="Mst. Gloves +2", augments={'Enhances "Beast Affinity" effect',}},
        legs="Bst. Trousers +1",
        feet={ name="Mst. Gaiters +2", augments={'Enhances "Beast Healer" effect',}},
        }
        sets.precast.JA.waltz={
        ammo="Light Sachet",
        head="Ferine Cabasset +2",
        body={ name="Kirin's Osode", augments={'Attack+4',}},
        hands="Ample Gloves",
        legs="Ferine Quijotes +2",
        neck="Ferine Necklace",
        waist="Aristo Belt",
        left_ring="Dawnsoul Ring",
        right_ring="Airy Ring",
        back="Aisance Mantle",
    }
        -------------------  Weaponskill Sets  ----------------------
        sets.precast.WS={
        head="Nocturnus Helm",
        body="Ferine Gausape +2",
        hands="Frn. Manoplas +2",
        legs="Ferine Quijotes +2",
        feet="Alcide's Leggings",
        neck="Ferine Necklace",
        waist="Cuchulain's Belt",
        left_ear="Ghillie Earring",
        right_ear="Ghillie Earring",
        left_ring="Keen Ring",
        right_ring="Demonry Ring",
        back="Atheling Mantle",
        }
        sets.precast.WS.Soil={
        head="Nocturnus Helm",
        body="Ferine Gausape +2",
        hands="Frn. Manoplas +2",
        legs="Ferine Quijotes +2",
        feet="Alcide's Leggings",
        neck="Soil Gorget",
        waist="Soil Belt",
        left_ear="Ghillie Earring",
        right_ear="Ghillie Earring",
        left_ring="Keen Ring",
        right_ring="Demonry Ring",
        back="Atheling Mantle",
        }
        sets.precast.WS.Aqua={
        head="Nocturnus Helm",
        body="Ferine Gausape +2",
        hands="Frn. Manoplas +2",
        legs="Ferine Quijotes +2",
        feet="Alcide's Leggings",
        neck="Aqua Gorget",
        waist="Aqua Belt",
        left_ear="Ghillie Earring",
        right_ear="Ghillie Earring",
        left_ring="Keen Ring",
        right_ring="Demonry Ring",
        back="Atheling Mantle",
    }
        -------------------  Trigger Gear Sets  ----------------------
        gear = {}
        gear.axe={
        main={ name="Astolfo", augments={'AGI+11','Pet: Evasion+22',}},
        sub={ name="Astolfo", augments={'VIT+11','Pet: Phys. dmg. taken -11%',}},
        }
        gear.H2H={
        main="Afflictors",
        }
        gear.dagger={
        main="Galkan Dagger",
        sub="Pallas's Shield",
        }
        gear.club={
        main="Rounsey Wand",
        sub="Pallas's Shield",
        }
        gear.scythe={
        main="Bounty Sickle",
        sub="Danger Grip",
        }
        gear.staff={
        main="Iridal Staff",
        sub="Danger Grip",
        }
            
    end
    
        -------------------  Gear Swap Rules  ----------------------
    
    function precast(spell)
        if spell.type == 'Waltz' then
            equip(sets.precast.JA.waltz)
        elseif spell.type == 'WeaponSkill' then
            if spell.name == 'Avalanche Axe' or spell.name == 'Calamity' or spell.name == 'Primal Rend' or spell.name == 'Rampage' or spell.name == 'Onslaught' or spell.name == 'Spinning Axe' then
                equip(sets.precast.WS.Soil)
            elseif spell.name == 'Decimation' or spell.name == 'Smash Axe' or spell.name == 'Ruinator' then
                equip(sets.precast.WS.Aqua)
            else
                equip(sets.precast.WS)
            end
        elseif spell.name == 'Call Beast' then
            equip(sets.precast.JA.call)
        elseif spell.name == 'Charm' then
            equip(sets.precast.JA.charm)
        elseif spell.type == 'PetCommand' then
            equip(sets[player.status].petcmd)
        elseif spell.name == 'Reward' then
            equip(sets[player.status].reward)
        end
    end
    
    function status_change(new,old)
        if new == 'Engaged' then
            equip(sets.Engaged.TP)
        else
            equip(sets.Idle.pettank)
        end
    end
    
    function aftercast(spell)
        if player.status == 'Engaged' then
            equip(sets.Engaged.TP)
        else
            equip(sets.Rdle.pettank)
        end
    end

  20. #3300

    Okay I have another question. In spellcast I had this code snipet:

    Code:
    			<if PetISValid="TRUE" Advanced='"$Fight"="0" AND "$PetRest"="0"'>
    				<action Type="Command" When="engaged">wait 1 3;input /pet "Fight" $target</action>
    			</if>
    			<else>
                                    <AddToChat Color="158">Pet Not Available</AddToChat>
    				<action Type="Command" When="engaged">wait 4 6;input /ja "Box Step" $target</action>
    			</else>
    $Fight was the cool down timer for the pet command and $PetRest was a toggled variable to indicate whether or not I wanted the pet to auto fight with me or not.

    The problem is, Spellcast no longer detects the pet and thus I am switching to GearSwap but it doesn't seem to detect my pet either. Here is the GearSwap code snippet:

    Code:
    function status_change(new,old)
        if new == 'Engaged' then
            equip(sets.engaged.tp)
            if petisvalid == 'TRUE' then
                send_command('wait 2 3;input /pet "Fight" <t>')
            else 
                add_to_chat(158,'Pet Not Available')
                send_command('wait 5 6;input /ja "Box Step" <t>')
            end
        else
            equip(sets.idle.pettank)
        end
    end
    Whether I have a pet or not, I get the message Pet Not Available but Box Step doesn't fire off. Does GearSwap currently detect the pet and am I even typing this up correctly? Are you even able to send an action command with GearSwap like you could with Spellcast? And I'm not even sure I understand how variables work in GearSwap, so I don't have cool down timer variables set up yet.

    Sorry for all the questions. I had to teach myself XML just to use Spellcast and now I'm trying to sort out Lua.

    =================================================

    I was able to correct the problem by writing it this way:

    Code:
    function status_change(new,old)
        if new == 'Engaged' then
            if pet.isvalid then
                send_command('@wait 2 3;input /pet "Fight" <t>')
            else 
                add_to_chat(158,'Pet not available')
                send_command('@wait 6 9;input /ja "Box Step" <t>')
            end
        end
    end

Similar Threads

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