Sleep Tracking Rdm

Language: JP EN DE FR
New Items
2023-11-19
users online
Forum » Windower » General » sleep tracking rdm
sleep tracking rdm
Offline
Posts: 363
By ksoze 2020-08-11 03:38:43
Link | Quote | Reply
 
Hey guys,

trying out some lua to track my rdm sleeps.

got some inspiration from this thread
https://www.ffxiah.com/forum/topic/50423/lullaby-gearswap-diddy/

I noticed that it uses

player.job_points.brd.marcato_effect

etc for calculating the durations

for rdm we have a merits enfeelbling magic duration also but if i check player.merits there is no such data available.

So question is, how do i know the enfeebling magic duration from my merits or is there a smarter way of knowing my duration of my sleeps witout calculating everyting.
 Asura.Yottaxa
Offline
Server: Asura
Game: FFXI
user: Yottaxa
Posts: 137
By Asura.Yottaxa 2020-08-11 04:55:30
Link | Quote | Reply
 
Dumb question but doesnt the addon “debuff” track like everything? (Only vaguely messed around with it)
Offline
Posts: 363
By ksoze 2020-08-11 05:14:56
Link | Quote | Reply
 
yes it does, but the timing is not correct and the lullaby lua groups all the sleeps which is pretty neat
 Shiva.Arislan
Offline
Server: Shiva
Game: FFXI
user: Arislan
Posts: 1052
By Shiva.Arislan 2020-08-11 07:45:12
Link | Quote | Reply
 
I've adapted Sammeh's code to work w/ RDM sleeps... here's the function from my lua:
Code
function user_setup()
    state.SleepMode = M{['description']='Sleep Mode', 'Normal', 'MaxDuration'}
    state.NM = M(false, 'NM?')
end

Code
function set_sleep_timer(spell)
    local self = windower.ffxi.get_player()

    if spell.en == "Sleep II" then
        base = 90
    elseif spell.en == "Sleep" or spell.en == "Sleepga" then
        base = 60
    end

    if state.Buff.Saboteur then
        if state.NM.value then
            base = base * 1.25
        else
            base = base * 2
        end
    end

    -- Merit Points Duration Bonus
    base = base + self.merits.enfeebling_magic_duration*6

    -- Relic Head Duration Bonus
    if not ((buffactive.Stymie and buffactive.Composure) or state.SleepMode.value == 'MaxDuration') then
        base = base + self.merits.enfeebling_magic_duration*3
    end

    -- Job Points Duration Bonus
    base = base + self.job_points.rdm.enfeebling_magic_duration

    --Enfeebling duration non-augmented gear total
    gear_mult = 1.40
    --Enfeebling duration augmented gear total
    aug_mult = 1.25
    --Estoquer/Lethargy Composure set bonus
    --2pc = 1.1 / 3pc = 1.2 / 4pc = 1.35 / 5pc = 1.5
    empy_mult = 1 --from sets.midcast.Sleep

    if ((buffactive.Stymie and buffactive.Composure) or state.SleepMode.value == 'MaxDuration') then
        if buffactive.Stymie then
            base = base + self.job_points.rdm.stymie_effect
        end
        empy_mult = 1.35 --from sets.midcast.SleepMaxDuration
    end

    totalDuration = math.floor(base * gear_mult * aug_mult * empy_mult)

    -- Create the custom timer
    if spell.english == "Sleep II" then
        send_command('@timers c "Sleep II ['..spell.target.name..']" ' ..totalDuration.. ' down spells/00259.png')
    elseif spell.english == "Sleep" or spell.english == "Sleepga" then
        send_command('@timers c "Sleep ['..spell.target.name..']" ' ..totalDuration.. ' down spells/00253.png')
    end
    add_to_chat(1, 'Base: ' ..base.. ' Merits: ' ..self.merits.enfeebling_magic_duration.. ' Job Points: ' ..self.job_points.rdm.stymie_effect.. ' Set Bonus: ' ..empy_mult)

end


There are some values that you need to input manually, like gear multiplier, augmented gear multipler and empyrean bonus multiplier (lines 30-35).
Offline
Posts: 363
By ksoze 2020-08-11 07:49:56
Link | Quote | Reply
 
@Arislan really appreciate that mate!
Log in to post.