BLU LUA Help

Eorzea Time
 
 
 
Language: JP EN FR DE
users online
Forum » FFXI » Jobs » Blue Mage » BLU LUA Help
BLU LUA Help
 Ragnarok.Endtanis
Offline
Server: Ragnarok
Game: FFXI
user: Endtanis
Posts: 16
By Ragnarok.Endtanis 2021-04-15 21:48:29
Link | Quote | Reply
 
Hi all,

I'm trying to adjust my LUA to work with AM3. I've searched the web and it references some older posts and I thought I have it right, but when I turn on debugmode, I can see it's not. My current code is as follows:
Code
sets.engaged.TizonaAM3 = {
		ammo="Ginsen",
		head="Malignance Chapeau",
		body="Malignance Tabard",
		hands="Malignance Gloves",
		legs="Malignance Tights",
		feet="Malignance Boots",
		neck={ name="Mirage Stole +2", augments={'Path: A',}},
		waist="Sailfi Belt +1",
		left_ear="Telos Earring",
		right_ear="Dedition Earring",
		left_ring="Chirich Ring +1",
		right_ring="Ilabrat Ring",
		back={ name="Rosmerta's Cape", augments={'DEX+20','Accuracy+20 Attack+20','Accuracy+10','"Dual Wield"+10','Damage taken-5%',}},
    }
	
	sets.engaged.AlmaceAM3 = {
		ammo="Ginsen",
		head="Malignance Chapeau",
		body="Malignance Tabard",
		hands="Malignance Gloves",
		legs="Malignance Tights",
		feet="Malignance Boots",
		neck={ name="Mirage Stole +2", augments={'Path: A',}},
		waist="Sailfi Belt +1",
		left_ear="Telos Earring",
		right_ear="Dedition Earring",
		left_ring="Chirich Ring +1",
		right_ring="Ilabrat Ring",
		back={ name="Rosmerta's Cape", augments={'DEX+20','Accuracy+20 Attack+20','Accuracy+10','"Dual Wield"+10','Damage taken-5%',}},
    }

function status_change()
	if buffactive["Aftermath: Lv.3"] then
		if player.equipment.main == 'Tizona' then
			equipSet = equipSet["TizonaAM3"]			
		elseif player.equipment.main == 'Almace' then
			equipSet = equipSet["AlmaceAM3"]
		end
	end
end

function buff_change(buff, gain)
    if state.Buff[buff] ~= nil then
       state.Buff[buff] = gain		
	end	
	if buff == "aftermath: lv.3" then -- AM3 Timer/Countdown --
		if gain then
			send_command('timers create "Aftermath: Lv.3" 180 down;wait 150;input /echo Aftermath: Lv.3 [WEARING OFF IN 30 SEC.];wait 15;input /echo Aftermath: Lv.3 [WEARING OFF IN 15 SEC.];wait 	5;input /echo Aftermath: Lv.3 [WEARING OFF IN 10 SEC.]')
		else
			send_command('timers delete "Aftermath: Lv.3"')
			add_to_chat(123,'AM3: [OFF]')
		end
	end
end	


I guess my question is, does Mote-Include have a function for AM3? If not, could someone help craft up proper code to get this to work?

Thanks in advance!
Offline
Posts: 464
By drakefs 2021-04-16 04:26:51
Link | Quote | Reply
 
You still need to let GS know to keep the set equipped.

something like (in a mote based lua)
Code
function customize_melee_set(meleeSet)
    if buffactive['Aftermath: Lv.3'] then
        if player.equipment.main == 'Tizona' then
            meleeSet = sets.engaged.TizonaAM3
        elseif player.equipment.main == 'Almace' then
            meleeSet = sets.engaged.AlmaceAM3
    end
    return meleeSet
end
[+]
 Cerberus.Darkvlade
Offline
Server: Cerberus
Game: FFXI
user: Darkvlade
Posts: 202
By Cerberus.Darkvlade 2021-04-16 08:14:38
Link | Quote | Reply
 
It could be something as simple as sets.engaged.Acc.AM, assuming your GS has a function built for it.

function update_melee_groups()
if player.equipment.main then
classes.CustomMeleeGroups:clear()

if player.equipment.main == "Tizona" and state.Buff['Aftermath: Lv.3'] then
classes.CustomMeleeGroups:append('AM')
end
end
end

(all credit goes to Selindrile)