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

Request: Error, Monster Script.

darkk

New Member
Joined
May 1, 2009
Messages
15
Reaction score
0
Location
Las Vegas, US
Hello, I want to use this Script,


Rhux made this Script.
With this script the monster cant Die. when you kill it, it will recover the Max Hp Again.
Code:
function onKill(cid, target)
local config = {
monstername = "X Monster",
text = " X TEXT"
}
	if getCreatureName(target) == config.monstername then
		doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, config.text)
		local maxhealth = getCreatureMaxHealth(target)
		doCreatureAddHealth(target, maxhealth,1)
		doSendMagicEffect(getCreaturePosition(target),49)
		doSendAnimatedText(getCreaturePosition(target),maxhealth,120)
		return FALSE
	end
	return TRUE
end


The problem is, when i kill the Monster
it Never Die/Revive, and it Send me the Text again, again, again D:
What can I do?



And this is the Image,
46746333.jpg


Thanks :peace:
 
Last edited:
because script is executed and after it you declared a false return..

replace return FALSE with return TRUE, and the return TRUE by return FALSE
 
because script is executed and after it you declared a false return..

replace return FALSE with return TRUE, and the return TRUE by return FALSE
onKill is executed for the player when he/she kills any monster/player - all other monsters wouldn't die then.
 
Back
Top