Ir para conteúdo

[Encerrado] [Pokemon] Dúvidas? - Pda


lucashgas

Posts Recomendados

@Dudefully: Esse bug ae, eu acho que vc tem q botar PZ nas paredes... tenta e diz se fucionou!!

É botar ou retirar no meu antigo dash se eu colocase pz em qualquer wall não prescisava nem estar de fly so da um order ou ir "empurrando" o pokemon até lá

Irei verificar se isso ocorre aqui aguarde.

Se todos purem testar tbm.

 

Bom aqui está tudo normal cara não tem pz nas paredes mas não tentei colocar para testar.

 

Alguem ae pode me dizer como por o fly para premium

SÓ o FLY não o fly e ride.

Editado por SoulOroshie
Link para o comentário
Compartilhar em outros sites

não sei se perceberam mais page up e page down tem comandos !up e !down consequentimente a diagonal no teclado numerico usa os comandos pra arrumar isso eu fiz o seguinte

existia nas talkactions

 

<talkaction words="up" case-sensitive="no" event="script" value="flyup.lua"/>

<talkaction words="down" case-sensitive="no" event="script" value="flydown.lua"/>

 

alterei para

 

<talkaction words="!up" case-sensitive="no" event="script" value="flyup.lua"/>

<talkaction words="!down" case-sensitive="no" event="script" value="flydown.lua"/>

 

e o script ficou assim

 

flyup.lua

 

function onSay(cid, words, param)

 

if param ~= "" then

return false

end

 

if getPlayerStorageValue(cid, 17000) <= 0 then

return true

end

 

if getThingPos(cid).z == 0 then

doPlayerSendCancel(cid, "You can\'t go higher!")

return true

end

 

local pos = getThingPos(cid)

pos.z = pos.z-1

pos.stackpos = 0

 

 

if getTileThingByPos(pos).itemid >= 1 or getTileItemById(getThingPos(cid), 1386).itemid >= 1 then

doPlayerSendCancel(cid, "You can\'t fly through constructions.")

return true

end

 

doCombatAreaHealth(cid, 0, pos, 0, 0, 0, CONST_ME_NONE)

doCreateItem(11676, 1, pos)

doTeleportThing(cid, pos)

 

 

 

 

return true

end

 

 

flydown.lua

 

local lower = {'460', '11675', '11676'}

 

local houses = {'919', '1015', '1590', '1591', '1592', '1593', '1582', '1584', '1586', '1588', '5248', '5189'}

 

function onSay(cid, words, param)

 

if param ~= "" then

return false

end

 

if getPlayerStorageValue(cid, 17000) <= 0 then

return true

end

 

if getThingPos(cid).z == 7 then

doPlayerSendCancel(cid, "You can\'t go lower!")

return true

end

 

if getTileInfo(getThingPos(cid)).itemid == 11677 then

doPlayerSendCancel(cid, "Sorry, it's not possible to go lower.")

return true

end

 

if not isInArray(lower, getTileInfo(getThingPos(cid)).itemid) and getTileInfo(getThingPos(cid)).itemid >= 2 then

doPlayerSendCancel(cid, "You can\'t go lower.")

return true

end

 

local pos = getThingPos(cid)

pos.z = pos.z+1

pos.stackpos = 0

 

if getTileThingByPos(pos).itemid >= 1 then

 

if getTilePzInfo(pos) == true then

doPlayerSendCancel(cid, "You can\'t go down here.")

return true

end

 

if not canWalkOnPos(pos, true, true, false, false, true) then

doPlayerSendCancel(cid, "You can't go down here.")

return true

end

 

doTeleportThing(cid, pos)

 

else

doCombatAreaHealth(cid, 0, pos, 0, 0, 0, CONST_ME_NONE)

doCreateItem(11675, 1, pos)

doTeleportThing(cid, pos)

 

return true

end

return true

end

 

 

aqui resolveu sem nenhum problema

Editado por lastdemon
Link para o comentário
Compartilhar em outros sites

@SoulOroshie

tenta ir na pasta lib/order.lua e ache essa parte..

elseif skill == "fly" then

e coloque logo em baixo isso..

if not isPremium(cid) then
  doPlayerSendCancel(cid, "Only premium members are allowed to fly.")
return true
end

ficando assim..

elseif skill == "fly" then

if not isPremium(cid) then
doPlayerSendCancel(cid, "Only premium members are allowed to fly.")
return true
end

Editado por Slicer
Link para o comentário
Compartilhar em outros sites

Funcionou sim obrigado REP+ Agora alguem ta tendo esse erro no console:

 

[01/02/2012 15:44:50] [Error - CreatureScript Interface]

[01/02/2012 15:44:50] data/creaturescripts/scripts/login.lua:onLogin

[01/02/2012 15:44:50] Description:

[01/02/2012 15:44:50] data/creaturescripts/scripts/login.lua:191: attempt to index field '?' (a nil value)

[01/02/2012 15:44:50] stack traceback:

[01/02/2012 15:44:50] data/creaturescripts/scripts/login.lua:191: in function <data/creaturescripts/scripts/login.lua:103>

[01/02/2012 15:44:50] Fraga has logged out.

Eu simplismente não sei oque é eu não mechi em nada no login

mas para quem puder ajudar ta ai:

 

 

local config = {

loginMessage = getConfigValue('loginMessage'),

useFragHandler = getBooleanFromString(getConfigValue('useFragHandler'))

}

 

local flys = {

["Moltres"] = {229, 2300}, -- moltres

["Articuno"] = {230, 2100}, -- artic

["Zapdos"] = {224, 2600}, -- zapdos

["Mew"] = {232, 2200}, -- 1000

["Mewtwo"] = {233, 2200},-- two

["Dragonite"] = {221, 1300},-- nite

["Pidgeot"] = {222, 900}, -- geot

["Fearow"] = {226, 800}, -- fearow

["Aerodactyl"] = {227, 1100}, -- aero

["Charizard"] = {216, 1000}, -- chari

["Porygon"] = {316, 600}, -- porygon

["Porygon2"] = {648, 890}, -- 2

["Skarmory"] = {649, 1000}, -- skarmory

["Crobat"] = {652, 1190}, -- crobat

}

 

 

local rides = {

["Tauros"] = {128, 580}, -- tauros

["Ninetales"] = {129, 800}, -- kyuubi

["Rapidash"] = {130, 800}, -- rapid

["Ponyta"] = {131, 410}, -- ponyta

["Rhyhorn"] = {132, 400}, -- rhyhorn

["Arcanine"] = {12, 900}, -- arcan

["Shiny Arcanine"] = {492, 1000}, -- shiny arca

["Shiny Venusaur"] = {494, 420}, -- shiny vneu

["Crystal Onix"] = {293, 480}, -- cristal onix

["Onix"] = {126, 450}, -- onix

["Venusaur"] = {134, 390}, -- venu

["Dodrio"] = {133, 750}, -- dodrio

["Doduo"] = {135, 420}, -- doduo

["Steelix"] = {646, 750}, -- steelix

["Meganium"] = {685, 720}, -- meganium

["Bayleef"] = {686, 555}, -- bayleef

["Stantler"] = {687, 595}, -- stantler

["Houndoom"] = {647, 820}, -- houndoom

["Piloswine"] = {689, 450}, -- piloswine

["Mareep"] = {688, 400}, -- marip

}

 

local surf = {

["Poliwag"] = {lookType=278, speed = 320},

["Poliwhirl"] = {lookType=137, speed = 480},

["Seaking"] = {lookType=269, speed = 520},

["Dewgong"] = {lookType=183, speed = 700},

["Blastoise"] = {lookType=184, speed = 850},

["Tentacruel"] = {lookType=185, speed = 750},

["Lapras"] = {lookType=186, speed = 960},

["Gyarados"] = {lookType=187, speed = 1050},

["Omastar"] = {lookType=188, speed = 680},

["Kabutops"] = {lookType=189, speed = 840},

["Poliwrath"] = {lookType=190, speed = 680},

["Vaporeon"] = {lookType=191, speed = 800},

["Staryu"] = {lookType=266, speed = 385},

["Starmie"] = {lookType=267, speed = 685},

["Goldeen"] = {lookType=268, speed = 355},

["Seadra"] = {lookType=270, speed = 655},

["Golduck"] = {lookType=271, speed = 760},

["Squirtle"] = {lookType=273, speed = 365},

["Wartortle"] = {lookType=275, speed = 605},

["Tentacool"] = {lookType=277, speed = 340},

["Snorlax"] = {lookType=300, speed = 500},

["Mantine"] = {lookType=636, speed = 820},

["Totodile"] = {lookType=637, speed = 360},

["Croconow"] = {lookType=638, speed = 590},

["Feraligatr"] = {lookType=645, speed = 900},

["Marill"] = {lookType=639, speed = 340},

["Azumarill"] = {lookType=642, speed = 680},

["Quagsire"] = {lookType=643, speed = 740},

["Kingdra"] = {lookType=644, speed = 1020},

["Octillery"] = {lookType=641, speed = 600},

["Wooper"] = {lookType=640, speed = 315},

["Wooper"] = {lookType=1010, speed = 750},

["Shiny Poliwag"] = {lookType=1010, speed = 320},

["Shiny Poliwhirl"] = {lookType=1011, speed = 480},

["Shiny Seaking"] = {lookType=1027, speed = 520},

["Shiny Dewgong"] = {lookType=1015, speed = 700},

["Shiny Blastoise"] = {lookType=1002, speed = 850},

["Shiny Tentacruel"] = {lookType=1014, speed = 750},

["Shiny Lapras"] = {lookType=1031, speed = 960},

["Shiny Gyarados"] = {lookType=1030, speed = 1050},

["Shiny Omastar"] = {lookType=1033, speed = 680},

["Shiny Kabutops"] = {lookType=1034, speed = 840},

["Shiny Poliwrath"] = {lookType=1012, speed = 680},

["Shiny Vaporeon"] = {lookType=1032, speed = 800},

["Shiny Staryu"] = {lookType=1028, speed = 385},

["Shiny Starmie"] = {lookType=1029, speed = 685},

["Shiny Goldeen"] = {lookType=1026, speed = 355},

["Shiny Seadra"] = {lookType=1025, speed = 655},

["Shiny Golduck"] = {lookType=1009, speed = 760},

["Shiny Squirtle"] = {lookType=1000, speed = 365},

["Shiny Wartortle"] = {lookType=1001, speed = 605},

["Shiny Tentacool"] = {lookType=1013, speed = 340},

["Shiny Snorlax"] = {lookType=1035, speed = 500},

}

 

function onLogin(cid)

registerCreatureEvent(cid, "PlayerAttack")

 

doPlayerSetLossPercent(cid, PLAYERLOSS_EXPERIENCE, 100)

doCreatureSetDropLoot(cid, false)

 

local accountManager = getPlayerAccountManager(cid)

 

if(accountManager == MANAGER_NONE) then

local lastLogin, str = getPlayerLastLoginSaved(cid), config.loginMessage

if(lastLogin > 0) then

doPlayerSendTextMessage(cid, MESSAGE_STATUS_DEFAULT, str)

str = "Your last visit was on " .. os.date("%a %b %d %X %Y", lastLogin) .. "."

else

str = str

end

 

doPlayerSendTextMessage(cid, MESSAGE_STATUS_DEFAULT, str)

 

elseif(accountManager == MANAGER_NAMELOCK) then

doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Hello, it appears that your character has been namelocked, what would you like as your new name?")

elseif(accountManager == MANAGER_ACCOUNT) then

doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Hello, type 'account' to manage your account and if you want to start over then type 'cancel'.")

else

doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Hello, type 'account' to create an account or type 'recover' to recover an account.")

end

 

if getCreatureName(cid) == "Account Manager" then

local outfit = {}

if accountManagerRandomPokemonOutfit then

outfit = {lookType = getPokemonXMLOutfit(oldpokedex[math.random(151)][1])}

else

outfit = accountManagerOutfit

end

 

doSetCreatureOutfit(cid, outfit, -1)

return true

end

 

if(not isPlayerGhost(cid)) then

doSendMagicEffect(getCreaturePosition(cid), CONST_ME_TELEPORT)

end

 

local outfit = {}

 

if getPlayerVocation(cid) == 0 then

doPlayerSetMaxCapacity(cid, 0)

doPlayerSetVocation(cid, 1)

setCreatureMaxMana(cid, 6)

doPlayerAddSoul(cid, -getPlayerSoul(cid))

setPlayerStorageValue(cid, 19898, 0)

if getCreatureOutfit(cid).lookType == 128 then

outfit = {lookType = 510, lookHead = math.random(0, 132), lookBody = math.random(0, 132), lookLegs = math.random(0, 132), lookFeet = math.random(0, 132)}

elseif getCreatureOutfit(cid).lookType == 136 then

outfit = {lookType = 511, lookHead = math.random(0, 132), lookBody = math.random(0, 132), lookLegs = math.random(0, 132), lookFeet = math.random(0, 132)}

end

doCreatureChangeOutfit(cid, outfit)

end

 

registerCreatureEvent(cid, "WatchTv")

registerCreatureEvent(cid, "StopWatchingTv")

registerCreatureEvent(cid, "WalkTv")

registerCreatureEvent(cid, "RecordTv")

--registerCreatureEvent(cid, "Death")

registerCreatureEvent(cid, "PlayerLogout")

registerCreatureEvent(cid, "WildAttack")

registerCreatureEvent(cid, "Idle")

registerCreatureEvent(cid, "PokemonIdle")

registerCreatureEvent(cid, "EffectOnAdvance")

registerCreatureEvent(cid, "GeneralConfiguration")

registerCreatureEvent(cid, "ReportBug")

registerCreatureEvent(cid, "LookSystem")

registerCreatureEvent(cid, "T1")

registerCreatureEvent(cid, "T2")

registerCreatureEvent(cid, "AuraBoost")

 

if getPlayerStorageValue(cid, 99284) == 1 then

setPlayerStorageValue(cid, 99284, -1)

end

 

doChangeSpeed(cid, -(getCreatureSpeed(cid)))

 

if getPlayerStorageValue(cid, 17000) >= 1 then -- fly

 

local item = getPlayerSlotItem(cid, 8)

local poke = getItemAttribute(item.uid, "poke")

doChangeSpeed(cid, getPlayerStorageValue(cid, 54844))

doRemoveCondition(cid, CONDITION_OUTFIT)

doSetCreatureOutfit(cid, {lookType = flys[poke][1] + 351}, -1)

 

local apos = getFlyingMarkedPos(cid)

apos.stackpos = 0

if getTileThingByPos(apos).itemid <= 2 then

doCombatAreaHealth(cid, FIREDAMAGE, getFlyingMarkedPos(cid), 0, 0, 0, CONST_ME_NONE)

doCreateItem(460, 1, getFlyingMarkedPos(cid))

end

 

doTeleportThing(cid, apos, false)

 

elseif getPlayerStorageValue(cid, 63215) >= 1 then -- surf

 

if not isInArray({4820, 4821, 4822, 4823, 4824, 4825}, getTileInfo(getThingPos(cid)).itemid) then

setPlayerStorageValue(cid, 63215, -1)

doChangeSpeed(cid, PlayerSpeed)

doRemoveCondition(cid, CONDITION_OUTFIT)

return true

end

 

local item = getPlayerSlotItem(cid, 8)

local poke = getItemAttribute(item.uid, "poke")

doSetCreatureOutfit(cid, {lookType = surf[poke].lookType + 351}, -1)

doChangeSpeed(cid, getPlayerStorageValue(cid, 54844))

 

elseif getPlayerStorageValue(cid, 17001) >= 1 then -- ride

 

local item = getPlayerSlotItem(cid, 8)

local poke = getItemAttribute(item.uid, "poke")

if rides[poke] then

doChangeSpeed(cid, getPlayerStorageValue(cid, 54844))

doRemoveCondition(cid, CONDITION_OUTFIT)

doSetCreatureOutfit(cid, {lookType = rides[poke][1] + 351}, -1)

else

setPlayerStorageValue(cid, 17001, -1)

doChangeSpeed(cid, PlayerSpeed)

end

 

elseif getPlayerGroupId(cid) >= 4 and getPlayerGroupId(cid) <= 7 then

doChangeSpeed(cid, 140*getPlayerGroupId(cid))

else

doChangeSpeed(cid, PlayerSpeed)

end

 

return true

end

 

Editado por SoulOroshie
Link para o comentário
Compartilhar em outros sites

@SoulOroshie

tenta ir na pasta lib/order.lua e ache essa parte..

elseif skill == "fly" then

e coloque logo em baixo isso..

if not isPremium(cid) then
  doPlayerSendCancel(cid, "Only premium members are allowed to fly.")
return true
end

ficando assim..

elseif skill == "fly" then

if not isPremium(cid) then
doPlayerSendCancel(cid, "Only premium members are allowed to fly.")
return true
end

Brow e o Surf caso eu queiro por esse mesmo esquema como faz?

Link para o comentário
Compartilhar em outros sites

AAAAAAAA tem alguem aewwwwwwwwwwww ajudaaaaaaaaaaaaaaaaaaaa

 

Aff niguem vai me ajuda mesmo né :(

blz dexa queto

!!

 

Amigo se ninguem te ajudo é por que não tem ainda \o até agora ninguem que eu vi desse 120 posts falou algo sobre fazer ou ter só esperar ou aprender scripting ou procurar pelo xtibia ou outros foruns

 

AAAAAAAA tem alguem aewwwwwwwwwwww ajudaaaaaaaaaaaaaaaaaaaa

 

Aff niguem vai me ajuda mesmo né :(

blz dexa queto

!!

 

Amigo se ninguem te ajudo é por que não tem ainda \o até agora ninguem que eu vi desse 120 posts falou algo sobre fazer ou ter só esperar ou aprender scripting ou procurar pelo xtibia ou outros foruns

 

@SoulOroshie

tenta ir na pasta lib/order.lua e ache essa parte..

elseif skill == "fly" then

e coloque logo em baixo isso..

if not isPremium(cid) then
  doPlayerSendCancel(cid, "Only premium members are allowed to fly.")
return true
end

ficando assim..

elseif skill == "fly" then

if not isPremium(cid) then
doPlayerSendCancel(cid, "Only premium members are allowed to fly.")
return true
end

Brow e o Surf caso eu queiro por esse mesmo esquema como faz?

Faz o seguinte vai em data/movements/ scripts e abre o surf.lua

procura : local premium

ve se esta

local premium = true

E se estiver olhe abaixo se esta desse jeito:

local premium = true
function onStepIn(cid, item, position, fromPosition)
if not isPlayer(cid) or getPlayerAccess(cid) >= 6 then
return true
end
if isPlayer(cid) and getCreatureOutfit(cid).lookType == 814 then return false end -- TV
if isPlayer(cid) and not isPremium(cid) and premium == true then
doTeleportThing(cid, fromPosition, false)
doPlayerSendCancel(cid, "Only premium members are allowed to surf.")
return true
end

Link para o comentário
Compartilhar em outros sites

Ae gente, sou novo aki no XTibia_smile.gif , Mais ja venho acompanhando o Forum a anos..Exclusivamente esse Topico ultimamente, Algumas Paginas e talz..

Queria saber se alguem pode me ajudar a colocar Barra de Cooldown no meu server, Pf. Estou desesperado...Soh falta isso pra eu terminar o meu server.

Me adc Msn: Leo_ospn1@hotmail.com

Link para o comentário
Compartilhar em outros sites

Sobre o Bug de Atravesssar parede

 

Tetei aqui colocar PZ dentro da casa e não deu certo :S

 

Vou tentar colocar o Botao ESC que provaca o bug como comando !up..assim se alguem tentar fazer isso ele ira descer :)

Link para o comentário
Compartilhar em outros sites

aew gente sobre o sistema bike criei uma sprite nova pro item de use para poder usa bike se alguem quizer

disponibilizo pra quem quizer de uma olhada ai

 

 

 

imagemkwv.png

 

 

 

lembrando aos moderadores isso nao e divulgação apenas ajudando no projeto

 

Jeffe000 rep pelo sistema

Editado por Nibelins
Link para o comentário
Compartilhar em outros sites

Tank's

SoulOroshie

 

quando eu tive REP mando pra tu ... :}.

 

Ultima coisinha como adciono outas cidades no sistema de tele so tem pallet aqui.

 

local poke = {'Abra', 'Kadabra', 'Alakazam', 'Drowzee', 'Hypno', 'Mr. Mime', 'Porygon', 'Porygon2'}

local etele = 9499

local cdtele = 1800

local config = {

premium = false, -- se precisa ser premium account (true or false)

battle = true -- se precisa estar sem battle (true). Se colocar false, poderá usar teleport no meio de batalhas

}

local places = {

[1] = {name = "Pallet", id = 1},

}

function onSay(cid, words, param)

if #getCreatureSummons(cid) == 0 then

doPlayerSendCancel(cid, "You need a pokemon to use teleport.")

return true

end

if not isInArray(poke, getCreatureName(getCreatureSummons(cid)[1])) then

return 0

end

if exhaustion.get(cid, etele) and exhaustion.get(cid, etele) > 0 then

local tempo = tonumber(exhaustion.get(cid, etele)) or 0

local min = math.floor(tempo)

doPlayerSendCancel(cid, "Your pokemon is tired, wait "..getStringmytempo(tempo).." to teleport again.")

return true

end

if config.premium and not isPremium(cid) then

doPlayerSendCancel(cid, "Only premium members are allowed to use teleport.")

return true

end

if config.battle and getCreatureCondition(cid, CONDITION_INFIGHT) then

doPlayerSendCancel(cid, "Your pokemon can't concentrate during battles.")

return true

end

if (param == '') then

local str = ""

str = str .. "Places to go :\n\nHouse\n"

for a = 1, #places do

str = str..""..places[a].name.."\n"

end

doShowTextDialog(cid, 7416, str)

return true

end

local item = getPlayerSlotItem(cid, 8)

local nome = getPokeballName(item.uid)

local summon = getCreatureSummons(cid)[1]

local lastppos = getThingPos(cid)

local lastspos = getThingPos(summon)

local telepos = {}

local myplace = ""

local townid = 0

if string.lower(param) == "house" then

if not getHouseByPlayerGUID(getPlayerGUID(cid)) then

doPlayerSendTextMessage(cid, MESSAGE_EVENT_DEFAULT, "You don't own a house.")

return true

end

telepos = getHouseEntry(getHouseByPlayerGUID(getPlayerGUID(cid)))

myplace = "our home"

else

for x = 1, #places do

if string.find(string.lower(places[x].name), string.lower(param)) then

townid = places[x].id

myplace = places[x].name

end

end

if myplace == "" then

doPlayerSendCancel(cid, "That place doesn't exist.")

return true

end

end

if myplace ~= "" and townid > 0 then

telepos = getTownTemplePosition(townid)

end

if getDistanceBetween(getThingPos(cid), telepos) <= 15 then

doPlayerSendCancel(cid, "You are too near to the place you want to go!")

return true

end

doSendMagicEffect(getThingPos(summon), 29)

doSendMagicEffect(getThingPos(cid), 29)

doTeleportThing(cid, telepos, false)

local pos2 = getClosestFreeTile(cid, getPosByDir(getThingPos(cid), SOUTH))

doTeleportThing(summon, pos2, false)

doSendMagicEffect(getThingPos(cid), 29)

doCreatureSay(cid, ""..nome..", teleport to "..myplace.."!", 1)

doCreatureSay(cid, ""..nome..", teleport to "..myplace.."!", 1, false, 0, lastppos)

doCreatureSay(summon, "TELEPORT!", TALKTYPE_MONSTER)

doCreatureSay(summon, "TELEPORT!", TALKTYPE_MONSTER, false, 0, lastspos)

doCreatureSetLookDir(cid, SOUTH)

doCreatureSetLookDir(summon, SOUTH)

doSendMagicEffect(getThingPos(summon), CONST_ME_TELEPORT)

exhaustion.set(cid, etele, cdtele)

doRemoveCondition(cid, CONDITION_OUTFIT)

return true

end

 

Link para o comentário
Compartilhar em outros sites

Visitante
Este tópico está impedido de receber novos posts.
×
×
  • Criar Novo...