Jump to content
Sign in to follow this  
zutto

Need help on Do -> until

Recommended Posts

zutto

yeap

i have number X and Y

y is 100

x is 200

my problem is

do

;Craphere

untill <-- this part

i want it to be +4 x or -4 x [x - 4 or x + 4 {or less than 4, 3 or 2 just between the 4 and X :)} ]

same for y

but i cant figure out way..

tell if you didnt understand some part ;o i am not good at explaining..

give me bit ideas :D

Share this post


Link to post
Share on other sites
SpookMeister

You are right... you are not good at explaining.


[u]Helpful tips:[/u]If you want better answers to your questions, take the time to reproduce your issue in a small "stand alone" example script whenever possible. Also, make sure you tell us 1) what you tried, 2) what you expected to happen, and 3) what happened instead.[u]Useful links:[/u]BrettF's update to LxP's "How to AutoIt" pdfValuater's Autoit 1-2-3 Download page for the latest versions of Autoit and SciTE[quote]<glyph> For example - if you came in here asking "how do I use a jackhammer" we might ask "why do you need to use a jackhammer"<glyph> If the answer to the latter question is "to knock my grandmother's head off to let out the evil spirits that gave her cancer", then maybe the problem is actually unrelated to jackhammers[/quote]

Share this post


Link to post
Share on other sites
SpookMeister

But perhaps you mean

Do
; some code
Until $z >= $x - 4 AND $z <= $x + 4
Edited by SpookMeister

[u]Helpful tips:[/u]If you want better answers to your questions, take the time to reproduce your issue in a small "stand alone" example script whenever possible. Also, make sure you tell us 1) what you tried, 2) what you expected to happen, and 3) what happened instead.[u]Useful links:[/u]BrettF's update to LxP's "How to AutoIt" pdfValuater's Autoit 1-2-3 Download page for the latest versions of Autoit and SciTE[quote]<glyph> For example - if you came in here asking "how do I use a jackhammer" we might ask "why do you need to use a jackhammer"<glyph> If the answer to the latter question is "to knock my grandmother's head off to let out the evil spirits that gave her cancer", then maybe the problem is actually unrelated to jackhammers[/quote]

Share this post


Link to post
Share on other sites
zutto

But perhaps you mean

Do
; some code
Until $z >= $x - 4 AND $z <= $x + 4
hmh, my head is so into other things, but that might work, ty

Share this post


Link to post
Share on other sites
zutto

hmh, my head is so into other things, but that might work, ty

err after bit thinking, it wont work :D

better explanation:

i got the X = 100 and y = 200

Z is the number i am looking if its inside the place where i want

not x+4 or x-4, between 96 and 104 :| now i got it right, but still looking for ideas

Share this post


Link to post
Share on other sites
SpookMeister

Z is the number i am looking if its inside the place where i want

That is what I gave you...

Perhaps you could make an example script that shows what you are trying to do we could help more.


[u]Helpful tips:[/u]If you want better answers to your questions, take the time to reproduce your issue in a small "stand alone" example script whenever possible. Also, make sure you tell us 1) what you tried, 2) what you expected to happen, and 3) what happened instead.[u]Useful links:[/u]BrettF's update to LxP's "How to AutoIt" pdfValuater's Autoit 1-2-3 Download page for the latest versions of Autoit and SciTE[quote]<glyph> For example - if you came in here asking "how do I use a jackhammer" we might ask "why do you need to use a jackhammer"<glyph> If the answer to the latter question is "to knock my grandmother's head off to let out the evil spirits that gave her cancer", then maybe the problem is actually unrelated to jackhammers[/quote]

Share this post


Link to post
Share on other sites
zutto

That is what I gave you...

Perhaps you could make an example script that shows what you are trying to do we could help more.

i found way by thinking bit deeper ^^

answer is : pythagorean theorem.... distance = sqrt(dx^2 + dy^2)

ty for helping anyway :D

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×