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

Heal summoned monster

andii95

New Member
Joined
Aug 21, 2009
Messages
413
Reaction score
2
Location
Sweden
I want a script that makes it able to heal the summon when saying "heal" for example.
Meaby make it heal from min: xxx to max: xxx
Something like that, nothing advanced.
Thanks :)
 
After the spell function oncast add
Code:
local heal = 	{ --- heailing formula edit it as you want
					getPlayerMagLevel(cid) * 5 + getPlayerLevel(cid) * 2 ,			-- min		
						
					getPlayerMagLevel(cid) * 6 + getPlayerLevel(cid) * 3 			-- max
				}
				

	if #getCreatureSummons(cid) < 1 then
		doPlayerSendCancel(cid,"You don't have any summons.")
		return false 
	end
	for _,pid in ipairs(getCreatureSummons(cid)) do 
		doCreatureAddHealth(pid,math.random(heal[1],heal[2]))
		doSendMagicEffect(getThingPos(pid),12)
	end
	doSendMagicEffect(getThingPos(cid),12)
	return true
end
 
Back
Top