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

function problem

foxkbt

Member
Joined
Sep 29, 2009
Messages
290
Reaction score
7
Location
Salvador
i using one function to return one value to name of a item equiped in hands
but dosent work i dont know why

PHP:
function getSuperAttack(cid)
local weapon = {3963, 3964, 3965}
local item = getPlayerItemById(cid, TRUE, weapon)
local dir = getPlayerSlotItem(cid, CONST_SLOT_LEFT) 
local esq = getPlayerSlotItem(cid, CONST_SLOT_RIGHT)
	if (isInArray(item.uid, dir.itemid)) or (isInArray(item.uid, esq.itemid)) then
		local name = getItemName(item.uid):match('(.-) health')
		local Health = getItemName(item.uid):match(''..name..' health (.-)/')
		local maxHealth = getItemName(item.uid):match(''..name..' health '..Health..'/(.-) weapon')
		local nameWeapon = getItemName(item.uid):match(''..name..' health '..Health..'/'..maxHealth..' weapon (.-)/')
		return getItemName(item.uid):match(''..name..' health '..Health..'/'..maxHealth..' weapon '..nameWeapon..'/(.-) armor')
	end
end

help me plx
rep++
 
Back
Top