function onUse(cid, item, fromPosition, itemEx, toPosition)
local cidPosition = getCreaturePosition(cid)
if (item.actionid == 5788 and
#####this is where what I did starts####
if(isVip(accountName))then
time = getAccountVipTime(accountName)
if(time > 0)then
####this is where what i did finishes####
) then
if cidPosition.x < toPosition.x then
doTeleportThing(cid, {x=toPosition.x+1,y=toPosition.y,z=toPosition.z}, TRUE)
doCreatureSay(cid, "BIENVENIDO VIP!", TALKTYPE_ORANGE_1)
else
doTeleportThing(cid, {x=toPosition.x-1,y=toPosition.y,z=toPosition.z}, TRUE)
doCreatureSay(cid, "BIENVENIDO VIP!", TALKTYPE_ORANGE_1)
end
return TRUE
else
doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "sOLO LOS VIP SON PERMITIDOS AQUI! SI QUIERES VIP, TENDRAS QUE COMPRARLO EN LA PAGINA WEB.")
return TRUE
end
return FALSE
end