Closed GLiTcH2 closed 7 months ago
use an external member.
local parameter = false
local checkboxItem = UIMenuCheckboxItem.New("checkboxItem", parameter, 1, "description")
checkboxItem.OnCheckboxChanged = function(menu, item, checked)
parameter = checked
end
this way the checkboxitem will depend on the external declared parameter state and not a fixed true or false
Thank you so much!! That worked perfectly.
I am new to lua coding so forgive my ignorance, I have been fiddling with the example menu provided. I just need a very small simple menu so I managed to strip out everything except two menu items, with a lot of trial and error I got the menu to finally work with no errors lol. Anyways the checkbox item does not maintain it's checked state, It's un-checked by default but when I manually check it and close the menu then open the menu back up it goes right back to it's un-checked state. What do I need to do to have it keep it's checked state?