First, geturl is as2 and earlier practices. as3 is like this.
Use URL of as3
Import Flash.net. navigatetoURL;
Import Flash.net. URLRequest;
// Usage
VaR TargetUrl: URLRequest = new URLRequest ("lingo: moviedo (\" withlingo \")");
NavigatetoURL (TargetUrl );
Flash uses geturl to interact with ctor script in three ways: lingo statement, directly calling event handler, and passing string to D.
Lingo statements
// Flash as2.0
Geturl ("lingo: moviehandlername (arg1, arg2, argn )");
//Flash as3.0
VaRTargetUrl: URLRequest = new URLRequest ("lingo: moviehandlername (arg1, arg2, argn )");
NavigatetoURL (TargetUrl );
-- Director (movie script)
On moviehandlername a, B, c
Put a & B & C -- puts: arg1 arg2 argn
End
Event
// Flash as2.0
Geturl ("Event: handlername, arg1, arg2, argn ");
//Flash as3.0
VaRTargetUrl: URLRequest = new URLRequest ("Event: handlername, arg1, arg2, argn ");
NavigatetoURL (TargetUrl );
-- Director (behavior script attached to flash sprite)
On handlername me, a, B, c
Put a & B & C -- puts: arg1 arg2 argn
End
String
// Flash as2.0
Geturl ("anything you want can go here ");
//Flash as3.0
VaRTargetUrl: URLRequest = new URLRequest ("anything you want can go here ");
NavigatetoURL (TargetUrl );
-- Director (behavior script attached to flash sprite)
On geturl me, STR
Put str -- puts: Anything you want can go here
End
Or
// Flash as2.0
Geturl ("anything you want can go here ");
//Flash as3.0
VaRTargetUrl: URLRequest = new URLRequest ("anything you want can go here ");
NavigatetoURL (TargetUrl );
-- Director (movie script)
On geturl Str
Put str -- puts: Anything you want can go here
End
-------------------------------------------
This method is compared with the method used to call as in lingo. The latter is indeed called and the process is complete.
In this way, I just throw a "Call request" to lingo, even if the request is thrown out. If you haven't done it, you don't know.
After testing, it seems that no matter how many times you throw it, you can only do it once within one frame of lingo. Others will be discarded and will not accumulate until the next time.