Moto Police:
local strgs = {17000, 17001} -- Coloque a Storage de Controle dos Sistemas Que Deseja Bloquear. local config = { outfitMale = 5510, -- Outfit male outfitFemale = 5509, -- Outfit female storageValue = 323339, -- Storage Para a bike } local storage_police = 52000 -- STORAGE PARA O PLAYER QUE É POLICE function onUse(cid, item, itemEx, fromPosition, toPosition) if getPlayerStorageValue(cid, storage_police) < 1 then doPlayerSendCancel(cid, "Você precisa ser Police para usar essa moto.") return doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Você precisa ser Police para usar essa moto.") end if isPremium(cid) then ctrl = 0 for x = 1, #strgs do if getPlayerStorageValue(cid, strgs[x]) > 0 then ctrl = ctrl + 1 end end if ctrl < 1 then if isPlayer(cid) and getCreatureOutfit(cid).lookType == 814 then return false end if getPlayerStorageValue(cid, 92001) >= 1 then doPlayerSendCancel(cid, "Você não pode usar bike e robo ao mesmo tempo.") return false end if getPlayerStorageValue(cid, 92002) >= 1 then doPlayerSendCancel(cid, "Você não pode usar bike e robo ao mesmo tempo.") return false end if getPlayerStorageValue(cid, 92003) >= 1 then doPlayerSendCancel(cid, "Você não pode usar bike e robo ao mesmo tempo.") return false end if getPlayerStorageValue(cid, 92004) >= 1 then doPlayerSendCancel(cid, "Você não pode usar bike e robo ao mesmo tempo.") return false end if getPlayerStorageValue(cid, 92005) >= 1 then doPlayerSendCancel(cid, "Você não pode usar bike e robo ao mesmo tempo.") return false end if getPlayerStorageValue(cid, 19000) == 1 then doPlayerSendCancel(cid, "Você não pode usar bike e correr ao mesmo tempo.") return false end if getPlayerStorageValue(cid, config.storageValue) <= 0 then local a = {lookType = config.outfitMale, lookHead = getCreatureOutfit(cid).lookHead, lookBody = getCreatureOutfit(cid).lookBody, lookLegs = getCreatureOutfit(cid).lookLegs, lookFeet = getCreatureOutfit(cid).lookFeet} local b = {lookType = config.outfitFemale, lookHead = getCreatureOutfit(cid).lookHead, lookBody = getCreatureOutfit(cid).lookBody, lookLegs = getCreatureOutfit(cid).lookLegs, lookFeet = getCreatureOutfit(cid).lookFeet} setPlayerStorageValue(cid, 32001, ""..getPlayerStamina(cid).."") doChangeSpeed(cid, 1500) setPlayerStorageValue(cid, config.storageValue, 1) if getPlayerSex(cid) == 0 then doSetCreatureOutfit(cid, b, -1) else doSetCreatureOutfit(cid, a, -1) end else setPlayerStorageValue(cid, config.storageValue, 0) doRemoveCondition(cid, CONDITION_OUTFIT) doRegainSpeed(cid) end else doPlayerSendCancel(cid, "Você não pode usar bike enquanto está no Fly/Hide.") end else doPlayerSendCancel(cid, "Você precisa ser Premium para usar essa moto.") return doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Você precisa ser Premium para usar essa moto.") end return true end
Moto Rocket:
local strgs = {17000, 17001} -- Coloque a Storage de Controle dos Sistemas Que Deseja Bloquear. local config = { velocidadeDaSuaBike = 1500, -- A volocidade da bike (1-9) outfitMale = 5517, -- Outfit male outfitFemale = 5516, -- Outfit female storageValue = 32053, -- Storage Para a bike } local storage_rocket = 52001 -- STORAGE PARA O PLAYER QUE FOR ROCKET function onUse(cid, item, itemEx, fromPosition, toPosition) if getPlayerStorageValue(cid, storage_rocket) < 1 then doPlayerSendCancel(cid, "Você precisa ser Rocket para usar essa moto.") return doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Você precisa ser Rocket para usar essa moto.") end if isPremium(cid) then ctrl = 0 for x = 1, #strgs do if getPlayerStorageValue(cid, strgs[x]) > 0 then ctrl = ctrl + 1 end end if ctrl < 1 then if isPlayer(cid) and getCreatureOutfit(cid).lookType == 814 then return false end if getPlayerStorageValue(cid, config.storageValue) <= 0 then local a = {lookType = config.outfitMale, lookHead = getCreatureOutfit(cid).lookHead, lookBody = getCreatureOutfit(cid).lookBody, lookLegs = getCreatureOutfit(cid).lookLegs, lookFeet = getCreatureOutfit(cid).lookFeet} local b = {lookType = config.outfitFemale, lookHead = getCreatureOutfit(cid).lookHead, lookBody = getCreatureOutfit(cid).lookBody, lookLegs = getCreatureOutfit(cid).lookLegs, lookFeet = getCreatureOutfit(cid).lookFeet} setPlayerStorageValue(cid, 32001, ""..getPlayerStamina(cid).."") doChangeSpeed(cid, -getCreatureSpeed(cid)) doChangeSpeed(cid, config.velocidadeDaSuaBike) setPlayerStorageValue(cid, config.storageValue, 1) if getPlayerSex(cid) == 0 then doSetCreatureOutfit(cid, b, -1) else doSetCreatureOutfit(cid, a, -1) end else setPlayerStorageValue(cid, config.storageValue, 0) doRemoveCondition(cid, CONDITION_OUTFIT) doRegainSpeed(cid) end else doPlayerSendCancel(cid, "Você não pode usar a moto enquanto está no Fly/Ride.") end else doPlayerSendCancel(cid, "Você precisa ser Premium para usar essa moto.") return doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Você precisa ser Premium para usar essa moto.") end return true end
Fiz verificação se é Police ou Rocket e se é premium. Na variável storage_police e storage_rocket só colocar a storage de cada, e lembrando que deixei para ver se são com o valor de storage 1, então se for 0 o valor da storage, precisa mudar na verificação.
Mas testa e fala se der algum problema.




info
Grupo: Infante
Registrado: 27/08/11
Posts: 1.9k
Reputação: +85
Gênero: Masculino
Char no Tibia: Bruno Maciel
Bom meu server ele e de PokeTibia ele tem o sistema de rocket e police e coloquei nele 2 veiculos(motos) ta funcionando tudo certinho porem queria por uma storage nelas porque queria fazer uma moto police e uma moto rocket.
Tipo se o player for da police ele vai poder usa uma monto X
Se o player dor da equipe rocket ele vai poder Usar moto Y
Script Moto(Police)
local strgs = {17000, 17001} -- Coloque a Storage de Controle dos Sistemas Que Deseja Bloquear. local config = { outfitMale = 5510, -- Outfit male outfitFemale = 5509, -- Outfit female storageValue = 323339, -- Storage Para a bike } function onUse(cid, item, itemEx, fromPosition, toPosition) ctrl = 0 for x = 1, #strgs do if getPlayerStorageValue(cid, strgs[x]) > 0 then ctrl = ctrl + 1 end end if ctrl < 1 then if isPlayer(cid) and getCreatureOutfit(cid).lookType == 814 then return false end if getPlayerStorageValue(cid, 92001) >= 1 then doPlayerSendCancel(cid, "Você não pode usar bike e robo ao mesmo tempo.") return false end if getPlayerStorageValue(cid, 92002) >= 1 then doPlayerSendCancel(cid, "Você não pode usar bike e robo ao mesmo tempo.") return false end if getPlayerStorageValue(cid, 92003) >= 1 then doPlayerSendCancel(cid, "Você não pode usar bike e robo ao mesmo tempo.") return false end if getPlayerStorageValue(cid, 92004) >= 1 then doPlayerSendCancel(cid, "Você não pode usar bike e robo ao mesmo tempo.") return false end if getPlayerStorageValue(cid, 92005) >= 1 then doPlayerSendCancel(cid, "Você não pode usar bike e robo ao mesmo tempo.") return false end if getPlayerStorageValue(cid, 19000) == 1 then doPlayerSendCancel(cid, "Você não pode usar bike e correr ao mesmo tempo.") return false end if getPlayerStorageValue(cid, config.storageValue) <= 0 then local a = {lookType = config.outfitMale, lookHead = getCreatureOutfit(cid).lookHead, lookBody = getCreatureOutfit(cid).lookBody, lookLegs = getCreatureOutfit(cid).lookLegs, lookFeet = getCreatureOutfit(cid).lookFeet} local b = {lookType = config.outfitFemale, lookHead = getCreatureOutfit(cid).lookHead, lookBody = getCreatureOutfit(cid).lookBody, lookLegs = getCreatureOutfit(cid).lookLegs, lookFeet = getCreatureOutfit(cid).lookFeet} setPlayerStorageValue(cid, 32001, ""..getPlayerStamina(cid).."") doChangeSpeed(cid, 1500) setPlayerStorageValue(cid, config.storageValue, 1) if getPlayerSex(cid) == 0 then doSetCreatureOutfit(cid, b, -1) else doSetCreatureOutfit(cid, a, -1) end else setPlayerStorageValue(cid, config.storageValue, 0) doRemoveCondition(cid, CONDITION_OUTFIT) doRegainSpeed(cid) end else doPlayerSendCancel(cid, "Você não pode usar bike enquanto está no Fly/Hide.") end return true endScript Moto(Rocket)
local strgs = {17000, 17001} -- Coloque a Storage de Controle dos Sistemas Que Deseja Bloquear. local config = { velocidadeDaSuaBike = 1500, -- A volocidade da bike (1-9) outfitMale = 5517, -- Outfit male outfitFemale = 5516, -- Outfit female storageValue = 32053, -- Storage Para a bike } function onUse(cid, item, itemEx, fromPosition, toPosition) ctrl = 0 for x = 1, #strgs do if getPlayerStorageValue(cid, strgs[x]) > 0 then ctrl = ctrl + 1 end end if ctrl < 1 then if isPlayer(cid) and getCreatureOutfit(cid).lookType == 814 then return false end if getPlayerStorageValue(cid, config.storageValue) <= 0 then local a = {lookType = config.outfitMale, lookHead = getCreatureOutfit(cid).lookHead, lookBody = getCreatureOutfit(cid).lookBody, lookLegs = getCreatureOutfit(cid).lookLegs, lookFeet = getCreatureOutfit(cid).lookFeet} local b = {lookType = config.outfitFemale, lookHead = getCreatureOutfit(cid).lookHead, lookBody = getCreatureOutfit(cid).lookBody, lookLegs = getCreatureOutfit(cid).lookLegs, lookFeet = getCreatureOutfit(cid).lookFeet} setPlayerStorageValue(cid, 32001, ""..getPlayerStamina(cid).."") doChangeSpeed(cid, -getCreatureSpeed(cid)) doChangeSpeed(cid, config.velocidadeDaSuaBike) setPlayerStorageValue(cid, config.storageValue, 1) if getPlayerSex(cid) == 0 then doSetCreatureOutfit(cid, b, -1) else doSetCreatureOutfit(cid, a, -1) end else setPlayerStorageValue(cid, config.storageValue, 0) doRemoveCondition(cid, CONDITION_OUTFIT) doRegainSpeed(cid) end else doPlayerSendCancel(cid, "Você não pode usar a moto enquanto está no Fly/Ride.") end return true endQueria por uma storage nela de so equipe Rocket quando o player for da equipe rocket pode usar e so da police pode usar moto da police.
E outra coisinha.
Alguem sabe a tag pra por na script pra deixa premium ??
Queria por as motos pra premium e mais duas coisas pra premium ^^
Quem puder ajudar REP+++