Jump to content
  • 0

How add multi choice choices on this script? Im a beginner thnks


ksjsjsjs

Question

function doAction()
    local ret = gg.alert('Here some action', 'OK', 'Cancel', 'Exit')
    if ret == 3 then os.exit() end

 

 

gg.setVisible(false)
while true do
    if gg.isVisible() then
        gg.setVisible(false)
        doAction()
    end
    gg.sleep(100)
end
 

 

Link to comment
Share on other sites

3 answers to this question

Recommended Posts

On 3/28/2019 at 9:50 PM, ksjsjsjs said:

function doAction()
    local ret = gg.alert('Here some action', 'OK', 'Cancel', 'Exit')
    if ret == 3 then os.exit() end

 

 

gg.setVisible(false)
while true do
    if gg.isVisible() then
        gg.setVisible(false)
        doAction()
    end
    gg.sleep(100)
end
 

 

You use gg.alert and it cannot get any buttons like checkbox . You need gg.multiChoise .

Link to comment
Share on other sites

On 3/29/2019 at 1:50 AM, ksjsjsjs said:

function doAction()
    local ret = gg.alert('Here some action', 'OK', 'Cancel', 'Exit')
    if ret == 3 then os.exit() end

 

 

gg.setVisible(false)
while true do
    if gg.isVisible() then
        gg.setVisible(false)
        doAction()
    end
    gg.sleep(100)
end
 

 

function doAction()
    local ret = gg.alert('Here some action', 'OK', 'Cancel', 'Exit')
    if ret == 3 then os.exit() end

end

 

 

gg.setVisible(false)
while true do
    if gg.isVisible() then
        gg.setVisible(false)
        doAction()
    else
    gg.sleep(100)

 end
end
 

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.