Oláa galera, venho pedir aqui a vocês para "incrementarem" um script que estou precisando...
Bom, eu estou usando o Vip System by Mock (http://www.xtibia.co...em-by-mock-100/)
e eu gostaria que o player vip ao logar aparecer por exemplo: Você ainda tem "tantos" dias vip.
O creaturescripts que ele usa ao login, é esse:
function onLogin(cid) local temple = { x =125, y = 52, z = 7} if vip.hasVip(cid) == true then if getPlayerStorageValue(cid,55555) ~= 1 then setPlayerStorageValue(cid,55555,1) end else if getPlayerStorageValue(cid,55555) == 1 then doTeleportThing(cid, temple) doPlayerSendTextMessage(cid, 22, "Your VIP Time over!") db.query("UPDATE `accounts` SET `vip_time` = 0 WHERE `id` = ".. getAccountIdByName(getPlayerName(cid)) ..";") setPlayerPromotionLevel(cid, 1) setPlayerStorageValue(cid, 55555, 0) end end return true end
Olha, eu tenho aqui um script que eu usava antes, nele tem essa mensagem que eu queria botar no do MOCK, se servir como alguma dica:
function onLogin(cid) local vip = isVip(cid) if getVipTime(cid) > 0 and vip == FALSE then local townid = 1 doPlayerSetTown(cid, townid) local templePos = getTownTemplePosition(getPlayerTown(cid)) doTeleportThing(cid, templePos, false) setVipTime(cid, 0) doTeleportPlayers(cid, templePos) doPlayerSendTextMessage(cid, MESSAGE_EVENT_ORANGE, "~* Sua Underworld VIP Acabou *~\n Para comprar mais acesse o site: Underworldot.servegame.com") elseif vip == TRUE then local duration = getVipDate(cid) doPlayerSendTextMessage(cid, MESSAGE_EVENT_ORANGE, "~* Você possui "..getVipDays(cid).." dia(s) de Underworld VIP *~\n"..(duration and (" Ela irá durar até "..duration..".\n Fale !promotionvip para virar vocação vip mais forte!") or "")) end return TRUE end