Jump to content
Pysk

Script soll AFK erkennen

Recommended Posts

Hallo.

Ich würde gerne ein Script so ändern das es erkennt wenn man AFK ist.

Das Script gibt alle 20 Minuten online Zeit ein Item. wenn ein Spieler einen Shop afmacht und autotrade nutzt bekommt er das Item nicht. Das ist auch gut so.

Wenn sich der Spieler einfach hinsetzt egal ob mit oder ohne Chatfenster belkommt er das Item trotzdem da der Server nicht weis das er einem Spieler nach 10 Minuten AFK nix mehr geben soll.

Wie kann ich das nun bewerkstelligen?

-	script	ScriptName	-1,{
OnPCLoginEvent:
AddTimer(1200000, "ScriptName::OnTimerEnd");
End();
OnTimerEnd:
if(!CheckVending())
	GetItem(21000, 1);
AddTimer(1200000, "ScriptName::OnTimerEnd");
End();
OnPCLogoutEvent:
DelTimer("ScriptName::OnTimerEnd");
End();
}

Link to comment
Share on other sites

Entweder du machst nen src hack, oder du schreibst dir einfach die position des spielers in ne variable und prüfst diese einfach :)

Das problem ist, dass man gerne mal 10 minuten an einem fleck steht aber nicht afk ist..

Link to comment
Share on other sites

Das tut nichts zu sache. wer sich 10 Minuten nicht bewegt, nix schreibt und nix tut ist für mich afk ^^

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use and Privacy Policy.