• 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!

Lua When they die back to level 1

sonny11

New Member
Joined
Dec 22, 2007
Messages
137
Reaction score
0
When my characters are above like level 500+

if they die they seem to revert back to level 1.

How do i fix that?
 
Execute SQL query in phpMyAdmin: (all players have to be offline)
SQL:
UPDATE players SET loss_experience = 100, loss_mana = 100, loss_skills = 100, loss_containers = 100, loss_items = 100;
 
Thanks, do i have to change deathLostPercent = 5 in config.lua?

ALSO, why is it that half of my players have loss_experience = 50 and half of them dont? all the samples have 100.. strange

EDIT: i executed that in phpmyadmin like 15 mins ago, and half of them are already back to 50! (yes server was offline)

EDIT: it goes back to 50 is because they get the promotion. BUT when it is 100. THEY DONT LOSE ANY EXP!
 
Last edited:
It's back to 50 because of this code in login.lua:
Lua:
	local loss = getConfigValue('deathLostPercent')
	if(loss ~= nil) then
		doPlayerSetLossPercent(cid, PLAYERLOSS_EXPERIENCE, loss * 10)
	end
5 * 10 = 50
 
Back
Top