Yoko

All sides of Injection
It is currently 2020-09-22 03:52:29

All times are UTC+02:00




Post new topic  Reply to topic  [ 2 posts ] 
Author Message
 Post subject: Need help for a command
PostPosted: 2009-03-01 11:42:19 
Offline

Joined: 2009-03-01 11:33:52
Posts: 1
Hi everybody,
i need a little bit of help for something.

In this exemple:

repeat

if uo.warmode() == uo.warmode(true) then
uo.warmode(false)
endif

UO.useskill('Meditation')
wait(800)

until HERE

I need a command who will be true on a keypress.
exemple: until key press "space"

i want to use a key to interrupt a loop in my script by pressing a key ingame. Thank you

another script exemple:

While not key press "space"
wait(1000)
wend


Top
   
 Post subject:
PostPosted: 2009-03-02 12:05:56 
Offline

Joined: 2009-01-27 15:09:57
Posts: 3
Location: Czech Republic
well I'm using global variables to solve such problems... you can use client macro such as:
say ',exec releaseScript'

and having a function
Code:
sub releaseLoop()
UO.SetGlobal("releaseLoop",STR(not VAL(UO.GetGlobal("releaseLoop"))))
UO.Print("releaseLoop: "+UO.GetGlobal("releaseLoop"))
end sub


in a loop, you'll have:

Code:
repeat
...whatever...
until VAL(UO.GetGlobal("releaseLoop")) == 1
UO.SetGlobal("releaseLoop","0")

_________________
Game Master of Moria, the Czech UO shard.


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 2 posts ] 

All times are UTC+02:00


Who is online

Users browsing this forum: No registered users and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Limited