Originally Posted by
Flippant
get_sets() should only ever be called once, so no, it should never be reset unless your entire file is reloaded. And no, you don't have to call it in order to change the value of pet_main.name.
but if you have a get sets like this
Code:
function get_sets()
test = {name="blabla"}
sets.Engaged = {
main=test,
sub="Tenax Strap",
body="Cmb.Cst. Cloak",
hands="Cmb.Cst. Mitts",
legs="Cmb.Cst. Slacks",
feet="Cmb.Cst. Shoes",
waist="Mrc.Cpt. Belt",
left_ear="Ardent Earring",
left_ring="Rajas Ring",
right_ring="Bastokan Ring",
back="Invisible Mantle",
}
sets.Idle = {
main=test,
sub="Tenax Strap",
body="Cmb.Cst. Cloak",
hands="Cmb.Cst. Mitts",
legs="Cmb.Cst. Slacks",
feet="Cmb.Cst. Shoes",
left_ear="Ardent Earring",
left_ring="Rajas Ring",
right_ring="Bastokan Ring",
back="Invisible Mantle",
}
sets.Resting = {
main=test,
sub="Tenax Strap",
body="Cmb.Cst. Cloak",
hands="Cmb.Cst. Mitts",
legs="Cmb.Cst. Slacks",
feet="Cmb.Cst. Shoes",
waist="Mrc.Cpt. Belt",
left_ear="Ardent Earring",
left_ring="Rajas Ring",
right_ring="Bastokan Ring",
back="Invisible Mantle",
}
end
even if you change test.name it will never change the sets tables with out calling get_sets() again
but with the above get_sets() it will reset all sets to the way thay were when you first loaded your file because there is no way to modify a function once the lua file is running
this is because once you build the table unless you rebuild it you cant dynamically change it no mater what you do
unless you directly modify the table like this
sets.Engaged.main = "blabla"
and just so you know
pet_main = {name="Eminent Staff"}
and
pet_main = "Eminent Staff"
in gearswap are basically the same thing