function onUse(cid, item, frompos, item2, topos) local storage = 13540 -- storage da vip if getPlayerStorageValue(cid, storage) == TRUE then doPlayerSendCancel(cid, "You no have vip") return true end if getPlayerStorageValue(cid, 99285) == 2 then doPlayerSendCancel(cid, "You have to close your private chat to create a TV channel.") return true end if getPlayerStorageValue(cid, 99285) == 1 then doPlayerSendCancel(cid, "You are already on air! Currently on channel: "..getPlayerStorageValue(cid, 99285).."") doPlayerSendChannel(cid, getPlayerChannelId(cid), getPlayerStorageValue(cid, 99285)) return true end doPlayerPopupFYI(cid, "Choose a channel name") end
- Fórum
- OTServ
- Suporte
- Tópicos Sem Resposta
- [Encerrado] ITEM - ACTION VIP
[Encerrado] ITEM - ACTION VIP
Por peeuowfe, 01 de mai. de 2013 em Tópicos Sem Resposta
info
Grupo: Lorde
Registrado: 22/07/12
Posts: 2.2k
Reputação: +453
Char no Tibia: Kissy

function onUse(cid, item, frompos, item2, topos) local storage = 13540 -- storage da vip if getPlayerStorageValue(cid, storage) == TRUE then doPlayerSendCancel(cid, "You no have vip") return true end if getPlayerStorageValue(cid, 99285) == 2 then doPlayerSendCancel(cid, "You have to close your private chat to create a TV channel.") return true end if getPlayerStorageValue(cid, 99285) == 1 then doPlayerSendCancel(cid, "You are already on air! Currently on channel: "..getPlayerStorageValue(cid, 99285).."") doPlayerSendChannel(cid, getPlayerChannelId(cid), getPlayerStorageValue(cid, 99285)) return true end doPlayerPopupFYI(cid, "Choose a channel name") end
Nao pego =/, fico pra free
info
Grupo: Herói
Registrado: 20/05/10
Posts: 3.4k
Reputação: +1.5k
Gênero: Masculino

troca essa linha:
if not isPremium(cid) then
por essa
if vip.hasVip(cid) == FALSE then
info
Grupo: Príncipe
Registrado: 19/08/10
Posts: 4k
Reputação: +1.1k
Gênero: Masculino

function onUse(cid, item, frompos, item2, topos) local storage = 13540 -- storage da vip if getPlayerStorageValue(cid, storage) == TRUE then doPlayerSendCancel(cid, "You no have vip") return true end if getPlayerStorageValue(cid, 99285) == 2 then doPlayerSendCancel(cid, "You have to close your private chat to create a TV channel.") return true end if getPlayerStorageValue(cid, 99285) == 1 then doPlayerSendCancel(cid, "You are already on air! Currently on channel: "..getPlayerStorageValue(cid, 99285).."") doPlayerSendChannel(cid, getPlayerChannelId(cid), getPlayerStorageValue(cid, 99285)) return true end doPlayerPopupFYI(cid, "Choose a channel name") end
mais uma prova q tu n devia ta nesse cargo... ;/
pequena aula...
if getPlayerStorageValue(cid, storage) == TRUE then
isso SEMPRE vai dar false, ja q tas comparando um numero com um booleano... ( -1 == true? )
tens q comparar com algum valor pra dai ser true ou false...
if getPlayerStorageValue(cid, storage) == -1 then
Editado Maio 1 por Slicer
info
Grupo: Lorde
Registrado: 22/07/12
Posts: 2.2k
Reputação: +453
Char no Tibia: Kissy

@Stylo Negativado por flood
info
Grupo: Infante
Registrado: 25/01/12
Posts: 1.6k
Reputação: +330

@Stylo Negativado por flood
creio que esse teu post agora é flood não? não é mais facil da rep - e fica queto kk?
function onUse(cid, item, frompos, item2, topos) local storage = 13540 -- storage da vip if getPlayerStorageValue(cid, storage) == TRUE then doPlayerSendCancel(cid, "You no have vip") return true end if getPlayerStorageValue(cid, 99285) == 2 then doPlayerSendCancel(cid, "You have to close your private chat to create a TV channel.") return true end if getPlayerStorageValue(cid, 99285) == 1 then doPlayerSendCancel(cid, "You are already on air! Currently on channel: "..getPlayerStorageValue(cid, 99285).."") doPlayerSendChannel(cid, getPlayerChannelId(cid), getPlayerStorageValue(cid, 99285)) return true end doPlayerPopupFYI(cid, "Choose a channel name") end
mais uma prova q tu n devia ta nesse cargo... ;/
pequena aula...
if getPlayerStorageValue(cid, storage) == TRUE thenisso SEMPRE vai dar false, ja q tas comparando um numero com um booleano... ( -1 == true? )
tens q comparar com algum valor pra dai ser true ou false...
if getPlayerStorageValue(cid, storage) == -1 then
poha tbm tinha essa duvida do "==-1", valeu (:
@alias isso é duvida de servidor derivados,
Editado Maio 2 por StyloMaldoso
info
Grupo: Príncipe
Registrado: 19/08/10
Posts: 4k
Reputação: +1.1k
Gênero: Masculino

@Stylo Negativado por flood
unico q devia levar REP- aki eh TU --' isso sim eh um flood sem fla no script todo errado q tu postou ¬¬ abuso de poder eh osso n? ;/
@alias isso é duvida de servidor derivados²
info
Grupo: Herói
Registrado: 28/11/10
Posts: 3.4k
Reputação: +585
Gênero: Masculino

+ Caso a dúvida não tenha sido resolvida você poderá criar outro tópico solicitando ajuda.
* Lembre-se que é permitido dar UP no tópico a cada 24 horas para assim o destacar e manter movimentado.





info
Grupo: Campones
Registrado: 11/10/12
Posts: 21
Reputação: 0
Eu tenho esse action do pokemon, que é a camera que grava para aparecer na TV.
Eu queria que ele fosse so pra vip usar, ele so usa se for premium, mais eu queria VIP.
Minha VIP que eu uso é essa
http://www.xtibia.com/forum/topic/151189-vip-system-by-mock-100/