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

A New Problem

Yony

New Member
Joined
Sep 7, 2007
Messages
318
Reaction score
0
Location
Israel
Well.. I'm using Avarian AAC and as many of you know for death list work you need to put a script in creaturescripts\scripts
So thats what I did.. It all worked perfect but I found the save script in the creaturescript forum... And I put it on my server..
Now I got problem.. I can't make them both work together..
When I try one of the scripts alone it works...
But when it come to put it together (I've tried everything.. put it in same script -login.lua-
make 2 scripts one the deathlist and one the save...
Nothing worked..

I think the problem is with creaturescripts.xml... But I dont have any idea what i have to write there.. (death list work but save not if I put them together)

Please help me...
 
Yes, u need to put them both in login.lua and then in creaturescripts.xml add just one line:
Code:
	<event type="login" name="PlayerLogin" script="login.lua"/>

P.S. I got like 6 scripts there and all are working :P
 
can you tell me how i put both scripts in login.lua? cuz i tried it and it didn't work..
 
PHP:
function onLogin(cid)

registerCreatureEvent(cid, "PlayerDeath")

	local getStatus = getPlayerStorageValue(cid, 3293)
	if(getStatus ~= TRUE) then
		local str = "*Welcome to Ildeadfishl Server!*\n\n\n*To report bugs or rule violations please use:\n!report (here write the statement).\n*To purchase a house use the servers website. \n*To create guild use our website too.\n*To see some help file use:\n!info\n*We wish You luck on Your new journeys with us!\n\nKind Regards,\nIldeadfishl Team."
		doPlayerPopupFYI(cid, str)
		setPlayerStorageValue(cid, 3293, TRUE)
	end	

	OLD_LEVELS[cid] = getPlayerLevel(cid)
	OLD_MAGLEVELS[cid] = getPlayerMagLevel(cid)
	OLD_FIST[cid] = getPlayerSkill(cid,SKILL_FIST)
	OLD_CLUB[cid] = getPlayerSkill(cid,SKILL_CLUB)
	OLD_AXE[cid] = getPlayerSkill(cid,SKILL_AXE)
	OLD_SWORD[cid] = getPlayerSkill(cid,SKILL_SWORD)
	OLD_DISTANCE[cid] = getPlayerSkill(cid,SKILL_DISTANCE)
	OLD_SHIELD[cid] = getPlayerSkill(cid,SKILL_SHIELD)
	OLD_FISHING[cid] = getPlayerSkill(cid,SKILL_FISHING)

local minutes = 10 * 60 * 1000 -- change the '10' to the interval of serversaves in minutes
	if(alryInitServSave == 0) then
		local eventServ = addEvent(autoSavePlayers, minutes, {})
		alryInitServSave = eventServ
	end
	return 1
end

function autoSavePlayers(parameters)
	savePlayers()
	local eventServ = addEvent(autoSavePlayers, minutes, parameters)
	alryInitServSave = eventServ
return TRUE
end

Something like that.
 
Back
Top