• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

Logging

gizzzmo

New Member
Joined
Dec 29, 2009
Messages
91
Reaction score
0
Ok, so there's people X-logging in trainer and their character stays online even though they've logged out.

How may I remove it so if they x-logg, that their character will log out as well instead of staying in trainers intill server restart..
 
config.lua
Code:
stopAttackingAtExit = true
idleWarningTime = 14 * 60 * 1000
idleKickTime = 15 * 60 * 1000

If that doesn't work then your training area has "no-logout zone" and you have to edit that through the map editor.

OR

data/globalevents/globalevents.xml
PHP:
<globalevent name="AFK Kick" interval="1" event="script" value="afk.lua"/>

data/globalevents/scripts/afk.lua
Code:
local kick = 15 -- Minutes
function onThink(cid, interval)
	for _, cid in ipairs(getPlayersOnline()) do
		if(getPlayerIdleTime(cid) >= kick * 60 * 1000) then
			doRemoveCreature(cid)
		end
		return true
	end
end
 
Last edited:
Back
Top