Scooch
Jun 13 2004, 02:03 AM
Hello, I am getting back into AC tools and just wanted to make sure this plug-in will work. What I want it to do is log me off if I die or after 30 minutes.
SetActiveWindow Asheron's Call
While 1=1
ProcessMessages
Delay 500
End
Procedure LogOut When _myvitae > 4
Keys ~{ESC}
End
Procedure LogOut1
Delay 30000
Keys ~{ESC}
End
Triane
Jun 13 2004, 08:48 AM
| CODE |
SetActiveWindow Asheron's Call
Constants StartingVitae = 0 End
SetConst StartingVitae = _myvitae
While 1=1 ProcessMessages Delay 500 End
Procedure VitaeMod when _myvitae <> $StartingVitae If _myvitae < $StartingVitae // (it went down) SetConst $StartingVitae = _myvitae Else // (It went up) Call LogOut1 End End
Procedure LogOut1 when {elapsedmsec} > 1800000 // 30 mins in msec Keys ~{ESC} Stop End |
This will log you out after 30 mins, and will also work properly if the toon starts the macro with vitae and loses some of it before dying.
-Triane
Scooch
Jun 13 2004, 02:06 PM
tyvm
Edit: If I wanted to change the log out time to 15 minutes would I just divide 1800000 in half?
Bear
Jun 13 2004, 05:23 PM
Yes, to find out Msec's the Formula is:
(15 Minutes * 60 Seconds) * 1000 = total Msec's.
arcgremlin
Oct 17 2004, 11:20 PM
triane
if someone starts with 9 vitea
and is macroing with yout log out thing
and gets the vitea down to say 0
and then dies
they'll still have vitea < starting vitea
so would this mean your macro would then, not log them out?
or is that what this is for:
If _myvitae < $StartingVitae
SetConst $StartingVitae = _myvitae
it is seeing that your vitea went down
so it is changing $startingvitae to whatever it changed to
so to prevent what i first stated?
or am i wrong
sry i'mjust trying to learn this whole thing =P
Triane
Oct 17 2004, 11:48 PM
If your vitae changes, it does one of two things:
If it went down, it lowers the bar for checking to see if it changes but carries on.
...otherwise...
If it goes up, it logs you off.
-Triane
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please
click here.