• 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 Exploding Health Rune - how to make it for KNIGHTS only!

Snooczek

New Member
Joined
Apr 29, 2011
Messages
15
Reaction score
0
Location
Poland
Code:
local exhaust = createConditionObject(CONDITION_EXHAUST)
setConditionParam(exhaust, CONDITION_PARAM_TICKS, (getConfigInfo('timeBetweenExActions') - 100))

function onUse(cid, item, fromPosition, itemEx, toPosition, blah, var)
	local level = getPlayerLevel(cid)
	local mlevel = getPlayerMagLevel(cid)
	local health_minimum = (level * 5) + (mlevel * 5) - 50
	local health_maximum = (level * 5.9) + (mlevel * 5)
	local health_add = math.random(health_minimum, health_maximum)
	
	doCreatureAddHealth(cid, health_add)
	doSendMagicEffect(getThingPos(itemEx.uid), CONST_ME_HEARTS)
	doCreatureSay(itemEx.uid, "Aaaah...", TALKTYPE_ORANGE_1)
	return TRUE
	end

Guys, please! Tell me how to make it for KNIGHTS of level 200 and higher?
I tried many times to fix it but im not a good scripter - just a newbie. And i think that i'll find some help in here :)
 
Back
Top