Page 1 of 1

global variable (or somthing like that)

Posted: 2004-05-29 09:53:38
by bink
i try to write some script working like that:

; ------------------------------------

var mode = 0

sub start()
mode = 1

while mode <> 0
uo.bandageself()
uo.wait(2000)
wend

end sub

sub stop()
mode = 0
end sub

; ------------------------------------

but that dont work :)
when i set mode = 0 in stop function that not change it in start function


thx for any adwise

Posted: 2004-05-29 12:04:32
by WeedDevil
uo.SetEasyUO("mode","0")

makes global variables

uo.geteasyuo("mode") retrieves its content

Posted: 2004-05-29 14:12:49
by Lord Ruslan Nightmare
uo.setglobal("varname","value")
uo.getglobal("varname")

Posted: 2004-05-31 19:20:18
by WeedDevil
O_o didnt really think about it ;) but your right of course