megahyperion Posted January 18, 2005 Share Posted January 18, 2005 Is there a way to use more then 1 AdLibEnable or at least run 2 seperate functions on their own timers ? Link to comment Share on other sites More sharing options...
Helge Posted January 18, 2005 Share Posted January 18, 2005 You could do something like this : AdlibEnable("myAdlib",100) Func myAdlib() _func1() _func2() EndFunc Func _func1() ;my function #1 EndFunc Func _func2() ;my function #2 EndFunc Is that's what you're thinking about ? Good luck anyway ! Link to comment Share on other sites More sharing options...
Griff Posted January 18, 2005 Share Posted January 18, 2005 I think he wanted to have them with different times for each one, its a bit of a bodge, but heres one way of doing it. In this case, _func1 goes every 100ms, and _func2 every 500ms $i = 1 AdlibEnable("myAdlib",100) Func myAdlib() _func1() if $i = 5 then $i = 1 _func2() else $i = $i+1 endif EndFunc Func _func1() ;my function #1 EndFunc Func _func2() ;my function #2 EndFunc Link to comment Share on other sites More sharing options...
mags Posted January 19, 2005 Share Posted January 19, 2005 I think he wanted to have them with different times for each one, its a bit of a bodge, but heres one way of doing it. In this case, _func1 goes every 100ms, and _func2 every 500ms$i = 1 AdlibEnable("myAdlib",100) Func myAdlib() _func1() if $i = 5 then $i = 1 _func2() else $i = $i+1 endif EndFunc Func _func1() ;my function #1 EndFunc Func _func2() ;my function #2 EndFunc<{POST_SNAPBACK}>I posted some days ago something that could be useful. May require some tweaking, though. http://www.autoitscript.com/forum/index.php?showtopic=7336Happy coding!!! Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now