Item Search
     
BG-Wiki Search
+ Reply to Thread
Page 16 of 22 FirstFirst ... 6 14 15 16 17 18 ... LastLast
Results 301 to 320 of 421
  1. #301

    i have a question but dont have much to tell. last night my gearswap started getting some kind of error, so this morning i looked it up and it happened to someone else and they fixed it by reinstalling windower. i reinstalled it this morning and now my gearswap isnt working at all, i have all the mote files and my lua files but gearswap isnt doing anything.

  2. #302

    figured it out, even though i uninstalled windower 4 somehow the game saved my old gearswap file so i mistook it for the new gearswap file, which was empty

  3. #303
    i should really shut up
    You can safely ignore me I am a troll

    Join Date
    Sep 2011
    Posts
    6,758
    BG Level
    8
    FFXI Server
    Asura

    EDIT: Figured it out after awhile. I am pretty dumb.

  4. #304
    Relic Horn
    Join Date
    Mar 2012
    Posts
    3,126
    BG Level
    7
    FFXIV Character
    Scrappy Doo
    FFXIV Server
    Sargatanas
    FFXI Server
    Asura

    https://pastebin.com/SfRMq83s

    can anybody tell me why the "Defense mode PDT" doesnt seem to trigger or do anything? I can get it to cycle between defense mode pdt and defense mode normal but it never swaps out of my normal tp set

    the mdt defense mode, acc mode seem to work fine

  5. #305

    Is there any code out there that i can put into my gearswap lua's that lets me change macro book pages based on what weapon i have in my main hand?

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

    It's totally doable to do that
    The commands are the following:

    /macro book X
    /macro set X

    In place of "X" you need to put the macro book and macro set you want to swap to.
    Now as to how to put them into gearswap, you would have to use the command "send_command", like this:

    send_command('input /macro book X;input /macro set X')

    Need to test it but it should work.
    As to how to "detect" your weapon has been changed, first you need to check the slot, and you can do it like this:

    if player.equipment.main == "equipment name" then ...

    Concatenate multiple "ifs" like this, and put different numbers in different sendcommand lines.
    I'll make an example right here

    if player.equipment.main == "Lionheart" then
    send_command('input /macro book 3;input /macro set 1')
    elseif player.equipment.main == "Epeolatry" then
    send_command('input /macro book 4;input /macro set 1')
    elseif player.equipment.main == "Aettir" then
    send_command('input /macro book 5;input /macro set 1')
    end


    The only question left open at this point is where to put this concatenated series of checks.
    It kinda depends on how you want it to work.
    Are we talking about a situation where you press a macro to change your weapon? Then it's gonna be super easy. But in this scenario you wouldn't even need gearswap to begin with, so I bet you just want to swap your weapon manually whenever you feel like it, and you want Gearswap to detect that and swap your macrobook/set accordingly.
    This is gonna be more complicated, it's kinda beyond my knowledge.
    Gearswap mostly functions with an "events" logic. If a certain event happen, then you can do a series of checks/action. Examples of events are: player starts an action, player is midcasting an action, the action completes, the player engages/disengages, the player receives/loses a buff or debuff, and so on.
    I don't think there is an event for "the player's main weapon equipment is swapped", so I'm not sure how you could solve that.

    Maybe someone else will post some ideas.
    dlsmd I summon you!!! xD xD

  7. #307
    New Spam Forum
    Join Date
    Oct 2010
    Posts
    169
    BG Level
    3
    FFXIV Character
    Neviskio Mordekaiser
    FFXIV Server
    Ragnarok
    FFXI Server
    Ragnarok
    WoW Realm
    Crushridge

    Heya, I'm using the arislan DNC and related files lua, I got an issue with presto/steps. Whenever I try to do a step the lua will try to use presto under certain conditions but I keep getting a line 366 nil value issue. Could anyone have a look at the lua? I returned recently and can't remember shit about this, been a week trying to fix it and couldn't find a solution yet.

    https://pastebin.com/LGNuZZSm

    it seems to happen even with arislan defaults.

    my macro is just /ja box step or whatever step I'm using. If I don't spam it, it seems to work but I seem to be tapping it slightly twice and it complains...-

    edit: actually the error is in gearswap/flow line 366? no idea wtf is going wrong

  8. #308

    Sweaty Dick Punching Enthusiast

    Join Date
    Sep 2006
    Posts
    1,385
    BG Level
    6
    FFXI Server
    Asura

    Last I played was in 2015, and I just reactivated my account.

    Will my stuff still work? Updated windower today.

  9. #309
    Campaign
    Join Date
    Jul 2007
    Posts
    6,633
    BG Level
    8

    I have to help a friend with his Lua.
    I need to execute some lines of codes in his precast, AFTER his "default" routines of checks/equips.
    Only problem is: I can't find it o.O
    His Lua is probably based on one of those Mote's stuff, which I have no bloody clue how they work.

    Posting it here hoping dlsmd or someone else can help me out.

    https://pastebin.com/ahMtuG4x


    In my luas, which I make myself from zero, I follow a pretty simple logic.
    Get sets where I define my various sets
    Function Precast
    Function Midcast
    Function Aftercast

    That's it. Of course I have a plethora of other custom things about status change, buff change, self commands, special functions etc, but the core is exactely like I described above.
    In this friend's Lua... I dunno, I see the sets, I just don't see where they get equipped.
    The closest thing I found is Function Job_Precast, it's similar in logic to my Precast, but I don't see the line where the sets get equipped D:

    Please someone help me out

  10. #310

    Quote Originally Posted by Sechs View Post
    I have to help a friend with his Lua.
    I need to execute some lines of codes in his precast, AFTER his "default" routines of checks/equips.
    Only problem is: I can't find it o.O
    His Lua is probably based on one of those Mote's stuff, which I have no bloody clue how they work.

    Posting it here hoping dlsmd or someone else can help me out.

    https://pastebin.com/ahMtuG4x


    In my luas, which I make myself from zero, I follow a pretty simple logic.
    Get sets where I define my various sets
    Function Precast
    Function Midcast
    Function Aftercast

    That's it. Of course I have a plethora of other custom things about status change, buff change, self commands, special functions etc, but the core is exactely like I described above.
    In this friend's Lua... I dunno, I see the sets, I just don't see where they get equipped.
    The closest thing I found is Function Job_Precast, it's similar in logic to my Precast, but I don't see the line where the sets get equipped D:

    Please someone help me out
    you never will find the code you are looking for because its part of motes include not your friends code

  11. #311
    BG Content
    Join Date
    Jul 2007
    Posts
    21,134
    BG Level
    10
    FFXI Server
    Lakshmi
    Blog Entries
    1

    Mote:'s includes were fine until they went unsupported and since have been a plague.

  12. #312
    Campaign
    Join Date
    Jul 2007
    Posts
    6,633
    BG Level
    8

    Do you know in which part of Mote's lua is that part I'm talking of?
    How would you go in my situation if you wanted to process some lines after the stuff has been equipped by mote's processes?

  13. #313

    Quote Originally Posted by Sechs View Post
    Do you know in which part of Mote's lua is that part I'm talking of?
    How would you go in my situation if you wanted to process some lines after the stuff has been equipped by mote's processes?
    not without you telling us exactly what you want to do

  14. #314
    Campaign
    Join Date
    Jul 2007
    Posts
    6,633
    BG Level
    8

    The lines I wrote for my friend work and I already tested them, problem is that I can't place those lines in the "right place". Atm those custom lines I wrote get executed before Mote's library do their stuff. It has to be the other way around, my lines need to be executed after Mote's stuff already decided what to equip.
    It's in the precast for a Weaponskill btw.

    Let's take for example the logic of my own Luas.

    In my precast I check for various things and equip stuff accordingly. It checks the spell/action being executed and according to the spell name/JA name, the category or several other things, the right set gets equipped.
    A simple example of one of my precasts here:
    Code:
    function precast(spell,action)
    	if spell.english:endswith('Maneuver') then
    		equip(sets.precast.Maneuver)
    	elseif sets.precast[spell.english] then
    		equip(sets.precast[spell.english])
    	elseif sets.precast[spell.type] then
    		equip(sets.precast[spell.type])
    	elseif sets.precast[spell.action_type] then
    		equip(sets.precast[spell.action_type])
    	elseif sets.precast.WS[spell.english] then
    		equip(sets.precast.WS[spell.english][WeaponskillMode])
    	end
    	if (spell.english == "Stringing Pummel" or spell.english == "Victory Smite" or spell.english == "Raging Fists" or spell.english == "Howling fist" or spell.english == "Tornado Kick") and player.tp > TPthreshold then
    		equip(sets.precast.WS.maxTP[WeaponskillMode])
    	end
    end
    I pretty much follow this logic on all of my Luas, of course on some jobs things are more complex.
    But what I wanted to show is that there's two clear parts in that Precast.
    The first part is the big, the "core" part, that handles pretty much every "normal" situation.
    The last part is a small, separate "If", and I use it to handle a specific exception.


    I want to do exactely the same for my friend. The lines I wrote for him work, I already tested them, but I can't make them being executed AFTER mote's stuff equip the gear.
    The result I'm currently getting is that my lines get executed, gear gets equipped, then that gear gets "overwritten" by Mote's library equipping their stuff.
    It has to be the other way around ><

  15. #315
    New Spam Forum
    Join Date
    Nov 2009
    Posts
    190
    BG Level
    3
    FFXI Server
    Sylph

    The docs talk about setting eventArgs.handled = true if you want to stop any default processing. Try messing with that.

  16. #316
    Campaign
    Join Date
    Jul 2007
    Posts
    6,633
    BG Level
    8

    Solved it by using job_post_precast as (briefly) described in those documentations.
    Thanks Subadai!

  17. #317
    You wouldn't know that though because you've demonstrably never picked up a book nor educated yourself on the matter. Let me guess, overweight housewife?
    Join Date
    Mar 2006
    Posts
    22,966
    BG Level
    10
    FFXIV Character
    Allyra Arianos
    FFXIV Server
    Sargatanas
    WoW Realm
    Windrunner

    Hi guys. I'm using Funk's brd lua which is great, but I have a question. His lua has an ability to auto pianissimo if you target another player with a song, which I love, but it only seems to work with <t> and not <st>. Anyone know if there's an easy way to fix it so it accepts <st>? Thanks in advance!

    Full lua:
    Code:
    function get_sets()
        sets.precast = {}
        sets.precast.JA = {}
        
        	-- Precast Sets
        	sets.precast.JA.Nightingale = {feet="Bihu Slippers +1"}
        
       	sets.precast.JA.Troubadour = {body="Bihu Justaucorps +3"}
        
        	sets.precast.JA['Soul Voice'] = {legs="Bihu Cannions +1"}
        
    	--###############
    	--# 64% Fast Cast
    	--# Main: 7%
    	--# Head: 10%
    	--# Body: 14%
    	--# Hands: 7%
    	--# Legs: 6%
    	--# Neck: 4%
    	--# Right Ear: 2%
    	--# Left Ring: 4%
    	--# Back: 10%
    	--###############
    sets.precast.FC = {
    main="Kali",
    head="Nahtirah Hat",
    body="Inyanga Jubbah",
    hands="Gende. Gages",
    legs="Kaykaus Tights",
    neck="Bathy Collar",
    right_ear="Loquacious Earring",
    left_ring="Kishar Ring",
    back={ name="Intarabus's Cape", augments={'CHR+20','Mag. Acc+20 /Mag. Dmg.+20','Mag. Acc.+10','"Fast Cast"+10','Damage taken-5%',}},
    }
    	
        	--###############
    	--# +51% Fast Cast
        	--# -30% Song Spellcasting Time
    	--# Main: 7%
    	--# Ear1: 1%
    	--# Ear2: 2%
    	--# Body: 14%
    	--# Hands: 7% +3%
    	--# Ring2: 4%
    	--# Back: 10%
    	--# Legs: 6%
    	--# Feet: 13%
    	--# Head: 14%
    	--###############
    sets.precast.FC.Song = {
    main="Kali",
    sub="Ammurapi Shield",
    head="Fili Calot +1",
    neck="Bathy Collar",
    left_ear="Loquacious Earring",
    right_ear="Moonshade Earring",
    body="Inyanga Jubbah",
    hands="Gende. Gages",
    right_ring="Kishar Ring",
    back={ name="Intarabus's Cape", augments={'CHR+20','Mag. Acc+20 /Mag. Dmg.+20','Mag. Acc.+10','"Fast Cast"+10','Damage taken-5%',}},
    legs="Kaykaus Tights",
    waist="Fucho-no-obi",
    feet="Telchine Pigaches",
    }
    
        	--###############
    	--# 64% Fast Cast
    	--###############
    sets.precast.FC.Normal = {
    main="Kali",
    head="Nahtirah Hat",
    body="Inyanga Jubbah",
    hands="Gende. Gages",
    legs="Kaykaus Tights",
    neck="Bathy Collar",
    right_ear="Loquacious Earring",
    right_ring="Kishar Ring",
    back={ name="Intarabus's Cape", augments={'CHR+20','Mag. Acc+20 /Mag. Dmg.+20','Mag. Acc.+10','"Fast Cast"+10','Damage taken-5%',}},
    }
            
    	--###############
    	--# 63% Fast Cast
    	--#-17% Cure Spellcasting Time
    	--###############
    sets.precast.Cure = {
    main="Kali",
    sub="Ammurapi Shield",
    head="Nahtirah Hat",
    neck="Bathy collar",
    left_ear="Loquacious Earring",
    right_ear="Moonshade Earring",
    body="Inyanga Jubbah",
    hands="Gende. Gages",
    right_ring="Kishar Ring",
    back={ name="Intarabus's Cape", augments={'CHR+20','Mag. Acc+20 /Mag. Dmg.+20','Mag. Acc.+10','"Fast Cast"+10','Damage taken-5%',}},
    legs="Kaykaus Tights",
    feet="Brioso Slippers +2",
    }
    
    	--###############
    	--# 64% Fast Cast
    	--#-08% Enhancing Magic Casting Time
    	--###############
    sets.precast.EnhancingMagic = {
    main="Kali",
    sub="Ammurapi Shield",
    head="Nahtirah Hat",
    body="Inyanga Jubbah",
    hands="Gende. Gages",
    waist="Witful Belt",
    legs="Kaykaus Tights",
    neck="Bathy Collar",
    right_ear="Loquacious Earring",
    right_ring="Kishar Ring",
    back={ name="Intarabus's Cape", augments={'CHR+20','Mag. Acc+20 /Mag. Dmg.+20','Mag. Acc.+10','"Fast Cast"+10','Damage taken-5%',}},
    }
        
        sets.precast.WS = {}
        sets.precast.WS['Rudra\'s Storm'] = {
        main="Carnwenhan",
        sub="Genmei Shield",
            range={ name="Linos", augments={'Accuracy+15','"Dbl.Atk."+2','Quadruple Attack +3',}},
        head={ name="Lustratio Cap", augments={'Accuracy+15','DEX+5','Crit. hit rate+2%',}},
        body="Ashera Harness",
        hands={ name="Lustratio Mittens", augments={'Accuracy+15','DEX+5','Crit. hit rate+2%',}},
        legs={ name="Lustratio Subligar", augments={'Accuracy+15','DEX+5','Crit. hit rate+2%',}},
        feet="Lustratio Leggings",
        neck="Caro Necklace",
        waist="Grunfeld Rope",
        left_ear="Ishvara Earring",
        right_ear={ name="Moonshade Earring", augments={'Accuracy+4','TP Bonus +250',}},
        left_ring="Karieyh Ring +1",
        right_ring="Petrov Ring",
        back={ name="Intarabus's Cape", augments={'DEX+20','Accuracy+20 Attack+20','Accuracy+10','"Store TP"+10','Phys. dmg. taken-10%',}},
    
    }
        
        -- Midcast Sets
        sets.midcast = {}
            
        sets.midcast.Haste = {}
    
    sets.midcast.Debuff = {    
    main="Kali",
    sub="Ammurapi Shield",
    range="Eminent Flute",
    ammo=empty,
    head="Brioso Roundlet +3",
    body="Brioso Justau. +1",
    hands="Brioso Cuffs +1",
    legs="Brioso Cannions +1",
    feet="Brioso Slippers +2",
    neck="Moonbow Whistle",
    waist="Luminary Sash",
    left_ear="Moonshade Earring",
    right_ear="Loquacious Earring",
    left_ring="Stikini Ring",
    right_ring="Stikini Ring",
    back={ name="Intarabus's Cape", augments={'CHR+20','Mag. Acc+20 /Mag. Dmg.+20','Mag. Acc.+10','"Fast Cast"+10','Damage taken-5%',}},
    }
        
    sets.midcast.Buff = {
    main="Kali",
    sub="Ammurapi Shield",	
    ammo=empty,
    head="Fili Calot +1",
    body="Fili Hongreline +1",
    hands="Fili Manchettes +1",
    legs="Inyanga Shalwar +2",
    feet="Brioso Slippers +2",
    neck="Moonbow Whistle",
    waist="Luminary Sash",
    left_ear="Loquacious Earring",
    right_ear="Moonshade Earring",
    left_ring="Defending Ring",
    right_ring="Inyanga Ring",
    back={ name="Intarabus's Cape", augments={'CHR+20','Mag. Acc+20 /Mag. Dmg.+20','Mag. Acc.+10','"Fast Cast"+10','Damage taken-5%',}},
    }
        
    sets.midcast.DBuff = {range="Terpander",ammo=empty}
        
    sets.midcast.GBuff = {range="Eminent Flute",ammo=empty}
        
    sets.midcast.Duration = {
    main="Kali",
    body="Fili Hongreline +1",
    neck="Moonbow Whistle",
    legs="Inyanga Shalwar +2",
    feet="Brioso Slippers +2"
    }
        
    sets.midcast.Lullaby = {
    main="Kali",
    sub="Ammurapi Shield",
    range="Marsyas",
    ammo=empty,
    head="Brioso Roundlet +3",
    body="Fili Hongreline +1",
    hands="Brioso Cuffs +1",
    legs="Inyanga Shalwar +2",
    feet="Brioso Slippers +2",
    neck="Moonbow Whistle",
    waist="Luminary Sash",
    left_ear="Loquacious Earring",
    right_ear="Moonshade Earring",
    left_ring="Stikini Ring",
    right_ring="Stikini Ring +1",
    back={ name="Intarabus's Cape", augments={'CHR+20','Mag. Acc+20 /Mag. Dmg.+20','Mag. Acc.+10','"Fast Cast"+10','Damage taken-5%',}},
    }
    
    --########################
    --#Song Specific Equipment
    --########################
    
    sets.midcast.Ballad = {
    legs="Fili Rhingrave +1"
    }
            
    sets.midcast.Scherzo = {
    feet="Fili Cothurnes +1"
    }
            
    sets.midcast.Paeon = {
    head="Brioso Roundlet +3"
    }
    
    sets.midcast.Minuet = {
    body="Fili Hongreline +1"
    }
    	
    sets.midcast.Honor = {
    range="Marsyas"
    }
    
    sets.midcast.Madrigal = {
    back="Intarabus's Cape"
    }
    	
    sets.midcast.Prelude = {
    back="Intarabus's Cape"
    }
    		
    sets.midcast.March = {
    hands="Fili Manchettes +1" 
    }
    
    --sets.midcast.Sirvente = {
    --head="Bihu Roundlet +1"
    --}
    
    --sets.midcast.Dirge = {
    --hands="Bihu Cuffs +1"
    --}
    
    sets.midcast.Carol = {
    hands="Mousai Gages +1"
    }
    
    sets.midcast.Etude = {
    head="Mousai Turban"
    }
    
    sets.midcast.Threnody = {
    body="Mou. Manteel +1"
    }
    
    sets.midcast.Minne = {
    legs="Mousai Seraweels"
    }
    
    sets.midcast.Mambo = {
    feet="Mousai Crackows"
    }
    
        
        sets.midcast.Base = sets.midcast.Haste
                
        sets.midcast.Cure = {
        main="Chatoyant Staff",
        sub="Vivid Strap",
        ammo="Oreiad's Tathlum",
        head={ name="Vanya Hood", augments={'Healing magic skill +20','"Cure" spellcasting time -7%','Magic dmg. taken -3',}},
        body={ name="Kaykaus Bliaut", augments={'MP+60','"Cure" spellcasting time -5%','Enmity-5',}},
        hands="Inyan. Dastanas +2",
        legs="Kaykaus Tights",
        feet={ name="Vanya Clogs", augments={'Healing magic skill +20','"Cure" spellcasting time -7%','Magic dmg. taken -3',}},
        neck="Incanter's Torque",
        waist="Bishop's Sash",
        left_ear="Mendi. Earring",
        right_ear="Beatific Earring",
        left_ring="Haoma's Ring",
        right_ring="Sirona's Ring",
        back="Tempered Cape +1",
    	}
            
        sets.midcast.Stoneskin = {
    	main="Odium",
        sub="Genmei Shield",
        range="Eminent Flute",
    	ammo=empty,
        head="Nahtirah Hat",
        body="Gende. Bilaut +1",
        hands={ name="Gende. Gages +1", augments={'Phys. dmg. taken -4%', 'Magic dmg. taken -4%', 'Song spellcasting time -3%',}},
        legs="Haven Hose",
        feet={ name="Bihu Slippers +1", augments={'Enhances "Nightingale" effect',}},
        neck="Stone Gorget",
        waist="Siegel Sash",
        left_ear="Earthcry Earring",
        right_ear="Enchntr. Earring +1",
        left_ring="Sirona's Ring",
        right_ring="Haoma's Ring",
        back={ name="Intarabus's Cape", augments={'CHR+20','Mag. Acc+20 /Mag. Dmg.+20','Mag. Acc.+10','"Fast Cast"+10','Damage taken-5%',}},
    	}
        
        
        --Aftercast Sets
    	--###############
    	--#-30% Damage Taken
    	--#-22% Physical Damage Taken (51)
    	--#-16% Magical Damage Taken (45)
    	--###############
        sets.aftercast = {
    main="Odium",
        sub="Genmei Shield",
        range={ name="Linos", augments={'Mag. Evasion+15','Phys. dmg. taken -4%','HP+19',}},
        head="Inyanga Tiara +2",
        body="Ashera Harness",
        hands="Mousai Gages +1",
        legs="Brioso Cannions +1",
        feet="Fili Cothurnes +1",
        neck="Loricate Torque +1",
        waist="Flume Belt +1",
        left_ear="Etiolation Earring",
        right_ear="Ethereal Earring",
        left_ring="Defending Ring",
        right_ring="Inyanga Ring",
        back={ name="Intarabus's Cape", augments={'HP+60','Eva.+20 /Mag. Eva.+20','Mag. Evasion+10','Enmity-10','Magic dmg. taken-10%',}},
    	}
    	
        sets.aftercast.Regen = {
    main="Odium",
        sub="Genmei Shield",
        range={ name="Linos", augments={'Mag. Evasion+15','Phys. dmg. taken -4%','HP+19',}},
        head="Inyanga Tiara +2",
        body="Ashera Harness",
        hands="Mousai Gages +1",
        legs="Brioso Cannions +1",
        feet="Fili Cothurnes +1",
        neck="Loricate Torque +1",
        waist="Flume Belt +1",
        left_ear="Etiolation Earring",
        right_ear="Ethereal Earring",
        left_ring="Defending Ring",
        right_ring="Inyanga Ring",
        back={ name="Intarabus's Cape", augments={'HP+60','Eva.+20 /Mag. Eva.+20','Mag. Evasion+10','Enmity-10','Magic dmg. taken-10%',}},
    	}
        
        sets.aftercast.PDT = { 	}
        
        sets.aftercast.Engaged = {
            main="Carnwenhan",
        sub="Genmei Shield",
        range={ name="Linos", augments={'Accuracy+15','"Dbl.Atk."+2','Quadruple Attack +3',}},
        head="Aya. Zucchetto +2",
        body="Ashera Harness",
        hands="Aya. Manopolas +2",
        legs="Aya. Cosciales +2",
        feet="Aya. Gambieras +2",
        neck="Bard's Charm",
        waist="Windbuffet Belt +1",
        left_ear="Telos Earring",
        right_ear="Cessance Earring",
        left_ring="Ilabrat Ring",
        right_ring="Petrov Ring",
        back={ name="Intarabus's Cape", augments={'DEX+20','Accuracy+20 Attack+20','Accuracy+10','"Store TP"+10','Phys. dmg. taken-10%',}},
    }
            
        sets.aftercast._tab = {'Regen','PDT'}
        
        sets.aftercast._index = 1
        
        sets.aftercast.Idle = sets.aftercast[sets.aftercast._tab[sets.aftercast._index]]
        
        DaurdSongs = T{"Army's Paeon II", "Army's Paeon III", "Army's Paeon IV", "Army's Paeon V", "Army's Paeon VI", }
        
        
        timer_reg = {}
        pianissimo_cycle = false
    end
    
    function pretarget(spell)
        if spell.type == 'BardSong' and spell.target.type and spell.target.type == 'PLAYER' and not buffactive.pianissimo and not spell.target.charmed and not pianissimo_cycle then
            cancel_spell()
            pianissimo_cycle = true
            send_command('input /ja "Pianissimo" <me>;wait 1.5;input /ma "'..spell.name..'" '..spell.target.name..';')
            return
        end
        if spell.name ~= 'Pianissimo' then
            pianissimo_cycle = false
        end
    end
    
    function precast(spell)
        if spell.type == 'BardSong' then
                equip_song_gear(spell)
                equip(sets.precast.FC.Song)
        elseif spell.action_type == 'Magic' then
            equip(sets.precast.FC.Normal) 
            if string.find(spell.english,'Cur') and spell.name ~= 'Cursna' then
                equip(sets.precast.Cure)
            end
            if spell.skill == 'Enhancing Magic' then
                equip(sets.precast.EnhancingMagic)
            end
        elseif spell.prefix == '/weaponskill' then
            if sets.precast.WS[spell.name] then
                equip(sets.precast.WS[spell.name])
            end
        end
        
        if sets.precast.FC[tostring(spell.element)] then equip(sets.precast.FC[tostring(spell.element)]) end
        if sets.precast.JA[spell.english] then equip(sets.precast.JA[spell.english]) end
        -- if player.status == 'Engaged' then equip({range=nil}) end
    end
    
    function midcast(spell)
        if spell.type == 'BardSong' then
            equip_song_gear(spell)
        elseif string.find(spell.english,'Waltz') and spell.english ~= 'Healing Waltz' then
            equip(sets.midcast.Base,sets.midcast.Waltz)
        elseif string.find(spell.english,'Cur') then
            equip(sets.midcast.Base,sets.midcast.Cure)
        elseif spell.english=='Stoneskin' then
            equip(sets.midcast.Base,sets.midcast.Stoneskin)
        end
    end
    
    function aftercast(spell)
        if midaction() then return end
    --[[    if spell.type and spell.type == 'BardSong' and spell.target and spell.target.type:upper() == 'SELF' then
            local t = os.time()
            
            -- Eliminate songs that have already expired
            local tempreg = {}
            for i,v in pairs(timer_reg) do
                if v < t then tempreg[i] = true end
            end
            for i,v in pairs(tempreg) do
                timer_reg[i] = nil
            end
            
            local dur = calculate_duration(spell.name)
            if timer_reg[spell.name] then
                if (timer_reg[spell.name] - t) <= 120 then
                    send_command('timers delete "'..spell.name..'"')
                    timer_reg[spell.name] = t + dur
                    send_command('timers create "'..spell.name..'" '..dur..' down')
                end
            else
                local maxsongs = 2
                if player.equipment.range == 'Daurdabla' then
                    maxsongs = maxsongs+2
                end
                if buffactive['Clarion Call'] then
                    maxsongs = maxsongs+1
                end
                if maxsongs < table.length(timer_reg) then
                    maxsongs = table.length(timer_reg)
                end
                
                if table.length(timer_reg) < maxsongs then
                    timer_reg[spell.name] = t+dur
                    send_command('timers create "'..spell.name..'" '..dur..' down')
                else
                    local rep,repsong
                    for i,v in pairs(timer_reg) do
                        if t+dur > v then
                            if not rep or rep > v then
                                rep = v
                                repsong = i
                            end
                        end
                    end
                    if repsong then
                        timer_reg[repsong] = nil
                        send_command('timers delete "'..repsong..'"')
                        timer_reg[spell.name] = t+dur
                        send_command('timers create "'..spell.name..'" '..dur..' down')
                    end
                end
            end
        end]]
        if player.status == 'Engaged' then
           equip(sets.aftercast.Engaged)
        else
            equip(sets.aftercast.Idle)
        end
    end
    
    function status_change(new,old)
     if new == 'Engaged' then
            equip(sets.aftercast.Engaged)
            disable('main','sub','ammo')
        elseif T{'Idle','Resting'}:contains(new) then
            equip(sets.aftercast.Idle)
    	enable('main','sub','ammo')
      end
    end
    
    function self_command(cmd)
        if cmd == 'unlock' then
            enable('main','sub','ammo')
        elseif cmd == 'midact' then
            midaction(false)
        elseif cmd == 'idle' then
            sets.aftercast._index = sets.aftercast._index%(#sets.aftercast._tab) + 1
            windower.add_to_chat(8,'Aftercast Set: '..sets.aftercast._tab[sets.aftercast._index])
            sets.aftercast.Idle = sets.aftercast[sets.aftercast._tab[sets.aftercast._index]]
            equip(sets.aftercast.Idle)
        end
    end
    
    function equip_song_gear(spell)
        if DaurdSongs:contains(spell.english) then
            equip(sets.midcast.Base,sets.midcast.DBuff)
        else
            if spell.target.type == 'MONSTER' then
                equip(sets.midcast.Base,sets.midcast.Debuff,sets.midcast.GBuff)
                if buffactive.troubadour or buffactive['elemental seal'] then
                    equip(sets.midcast.Duration)
                end
                if string.find(spell.english,'Lullaby') then equip(sets.midcast.Duration,sets.midcast.Lullaby) end
    	    if string.find(spell.english,'Threnody') then equip(sets.midcast.Threnody) end
            else
                equip(sets.midcast.Base,sets.midcast.Buff,sets.midcast.GBuff)
              if string.find(spell.english,'March') then equip(sets.midcast.March) end
              if string.find(spell.english,'Minuet') then equip(sets.midcast.Minuet) end
              if string.find(spell.english,'Madrigal') then equip(sets.midcast.Madrigal) end
              if string.find(spell.english,'Ballad') then equip(sets.midcast.Ballad) end
              if string.find(spell.english,'Scherzo') then equip(sets.midcast.Scherzo) end
              if string.find(spell.english,'Prelude') then equip(sets.midcast.Prelude) end
              if string.find(spell.english,'Paeon') then equip(sets.midcast.Paeon) end
    	  if string.find(spell.english,'Sirvente') then equip(sets.midcast.Sirvente) end
    	  if string.find(spell.english,'Dirge') then equip(sets.midcast.Dirge) end
    	  if string.find(spell.english,'Carol') then equip(sets.midcast.Carol) end
    	  if string.find(spell.english,'Mambo') then equip(sets.midcast.Mambo) end
    	  if string.find(spell.english,'Minne') then equip(sets.midcast.Minne) end
    	  if string.find(spell.english,'Etude') then equip(sets.midcast.Etude) end
              if spell.english=="Honor March" then equip(sets.midcast.Honor) end
            end
        end
    end
    
    function calculate_duration(name)
        local mult,ext = 1,0
        if player.equipment.range == "Daurdabla" then mult = mult + 0.3 end
        if player.equipment.range == "Eminent Flute" then mult = mult + 0.4 end
        if player.equipment.range == "Marsyas" then mult = mult + 0.5 end
    
        if player.equipment.neck == "Moonbow Whistle +1" then mult = mult + 0.3 end
        if player.equipment.feet == "Brioso Slippers +2" then mult = mult + 0.15 end
        if player.equipment.body == "Fili Hongreline +1" then mult = mult + 0.12 end
        if player.equipment.legs == "Inyanga Shalwar +2" then mult = mult + 0.17 end
        if player.equipment.main == "Carnwenhan" then mult = mult + 0.5 end
        
        if string.find(name,'March') and player.equipment.hands == "Fili Manchettes +1" then mult = mult + 0.1 end
        if string.find(name,'Minuet') and player.equipment.body == "Fili Hongreline +1" then mult = mult + 0.1 end
        if string.find(name,'Madrigal') and player.equipment.head == "Fili Calot +1" then mult = mult + 0.1 end
        if string.find(name,'Madrigal') and player.equipment.back == "Intarabus's Cape" then mult = mult + 0.1 end
        if string.find(name,'Ballad') and player.equipment.legs == "Fili Rhingrave +1" then mult = mult + 0.1 end
        if string.find(name,'Scherzo') and player.equipment.feet == "Fili Cothurnes +1" then mult = mult + 0.1 end
        if string.find(name,'Prelude') and player.equipment.back == "Intarabus's Cape" then mult = mult + 0.1 end
        if string.find(name,'Paeon') and player.equipment.head == "Brioso Roundlet +3" then mult = mult + 0.2 end
        
        if buffactive.Troubadour then
            mult = mult*2
        end
        if string.find(name,'Scherzo') and buffactive['Soul Voice'] then
            mult = mult*2
        elseif string.find(name,'Scherzo') and buffactive.marcato then
            mult = mult*1.5
        end
        
        if buffactive['Clarion Call'] then
            ext = 20
        end
        
        return mult*120 + ext
    end
    
    function reset_timers()
        for i,v in pairs(timer_reg) do
            send_command('timers delete "'..i..'"')
        end
        timer_reg = {}
    end
    
    windower.register_event('zone change',reset_timers)
    windower.register_event('logout',reset_timers)

  18. #318

    Quote Originally Posted by Ksandra View Post
    Hi guys. I'm using Funk's brd lua which is great, but I have a question. His lua has an ability to auto pianissimo if you target another player with a song, which I love, but it only seems to work with <t> and not <st>. Anyone know if there's an easy way to fix it so it accepts <st>? Thanks in advance!
    it might be that <st> does not get sent to pretarget
    however i am not sure

  19. #319
    You wouldn't know that though because you've demonstrably never picked up a book nor educated yourself on the matter. Let me guess, overweight housewife?
    Join Date
    Mar 2006
    Posts
    22,966
    BG Level
    10
    FFXIV Character
    Allyra Arianos
    FFXIV Server
    Sargatanas
    WoW Realm
    Windrunner

    Quote Originally Posted by dlsmd View Post
    it might be that <st> does not get sent to pretarget
    however i am not sure
    yeah idk

    My husband has a lua that's this massive file with all jobs in it. The bard section has a pianissimo part and it works with <st>, but just pasting it into mine doesn't make it work since the coding is set up differently.

    I'll bother him later for him to show what his says to see what I would need to do f anything.

  20. #320

    Quote Originally Posted by Ksandra View Post
    yeah idk

    My husband has a lua that's this massive file with all jobs in it. The bard section has a pianissimo part and it works with <st>, but just pasting it into mine doesn't make it work since the coding is set up differently.

    I'll bother him later for him to show what his says to see what I would need to do f anything.
    thats why i am not sure but that is the only thing i could say it is because your code
    Code:
    function pretarget(spell)
        if spell.type == 'BardSong' and spell.target.type and spell.target.type == 'PLAYER' and not buffactive.pianissimo and not spell.target.charmed and not pianissimo_cycle then
            cancel_spell()
            pianissimo_cycle = true
            send_command('input /ja "Pianissimo" <me>;wait 1.5;input /ma "'..spell.name..'" '..spell.target.name..';')
            return
        end
        if spell.name ~= 'Pianissimo' then
            pianissimo_cycle = false
        end
    end
    does not check for spell.target.raw before uses pianissimo

Quick Reply Quick Reply

  • Decrease Size
    Increase Size
  • Remove Text Formatting
  • Insert Link Insert Image Insert Video
  • Wrap [QUOTE] tags around selected text
  • Insert NSFW Tag
  • Insert Spoiler Tag

Similar Threads

  1. Gearswap Help Thread!
    By JSHidaka in forum FFXI: Everything
    Replies: 6035
    Last Post: 2018-05-06, 17:15
  2. Randomerest Question Thread III: This Time It's Random
    By isladar in forum FFXI: Everything
    Replies: 868
    Last Post: 2009-08-18, 12:03