![]() |
actionplayer question
For the control npc on my server
I want something to happen when the player logs out. it's not actionplayeroffline, (which you think would work since actionplayeronline works for the login) What is the flag triggered to the server when a player logs out? Also is there a refrence to serverside commands and flags in a file that someone can post? |
There isn't one, you just need to do a allplayerscount check in a loop and all that. Well, atleast untill the new version, where I'd assume something like this, if not already available, could easily be added via script.
|
Something like this is a good way to check
PHP Code:
|
Quote:
|
I made a nice who logged out npc before. I dont care who logs out though, so I took it down.
|
And then I made it again (not a copy just typed my own up... much like the one I put on bravo)
But Slash and I are cool so... <3 |
Quote:
|
Quote:
|
Hrm -- You shouldn't be too bothered by the players logging out -- By all case, it would case a lot of lag checking the entire list repeatedly... Perhaps make the timeout equal 5 instead of 1, if at all useful.
|
In the new scripting engine on clientside you have the event actionplayerlogout, the player object is deleted 5 seconds after the player logs out instead of immediatelly removing it. That needed to be added to make the scripted playerlist work.
Something similar will be added to npcserver sometime, although there it is a little bit more complex because both gserver and npcserver would need to keep the player object in the memory so that you can still do modifications on the player which are also saved on hard disk. |
| All times are GMT +2. The time now is 09:51 PM. |
Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.