Ir para conteúdo
  • 0

Qual o erro nesse script ?


Desnecessario

Pergunta


function onWalkIn(cid, item, frompos)



queststatus = getPlayerStorageValue(cid,5801)

if queststatus == -1 then


pos = getPlayerPosition(cid)


doTeleportThing(cid,{x=208, y=87, z=15})

doPlayerSendTextMessage(cid,180,"!!!!")

setPlayerStorageValue(cid,5801,1)

doSendMagicEffect(frompos,98)



else

setPlayerStorageValue(cid,5801,-1)


doTeleportThing(cid,pos)

doSendMagicEffect(frompos,98)

doSendAnimatedText(getPlayerPosition(cid), "!!!", 71)

setPlayerStorageValue(cid,5801,-1)

doPlayerSendTextMessage(cid,180,"Libertaçao!")


end

end



Bom galera na verdade tudo no script está funcionando menos - doTeleportThing(cid,{x=208, y=87, z=15})

Tem como alguem me ajudar ?? oque tem de errado nessa parte ? =B

Link para o comentário
Compartilhar em outros sites

8 respostass a esta questão

Posts Recomendados

  • 0

 

function onWalkIn(cid, item, frompos)
 
 
  queststatus = getPlayerStorageValue(cid,5801)
  if queststatus == -1 then
 
pos = getPlayerPosition(cid)
telar = {x=208, y=87, z=15}
doTeleportThing(cid, telar, false)
doPlayerSendTextMessage(cid,180,"!!!!")
setPlayerStorageValue(cid,5801,1)
doSendMagicEffect(frompos,98)
 
 
else
setPlayerStorageValue(cid,5801,-1)
doTeleportThing(cid,pos)
doSendMagicEffect(frompos,98)
doSendAnimatedText(getPlayerPosition(cid), "!!!", 71)
setPlayerStorageValue(cid,5801,-1)
doPlayerSendTextMessage(cid,180,"Libertaçao!")
 
end
end
Link para o comentário
Compartilhar em outros sites

  • 0

Tenta assim:

 

function onWalkIn(cid, item, frompos)

queststatus = getPlayerStorageValue(cid,5801)
if queststatus == -1 then
local pos = getPlayerPosition(cid)
local pos2 = {x=208, y=87, z=15}
doTeleportThing(cid, pos2)
doPlayerSendTextMessage(cid,180,"!!!!")
setPlayerStorageValue(cid,5801,1)
doSendMagicEffect(frompos,98)
else
setPlayerStorageValue(cid,5801,-1)
doTeleportThing(cid,pos)
doSendMagicEffect(frompos,98)
doSendAnimatedText(getPlayerPosition(cid), "!!!", 71)
setPlayerStorageValue(cid,5801,-1)
doPlayerSendTextMessage(cid,180,"Libertaçao!")
end
end
Link para o comentário
Compartilhar em outros sites

  • 0
function onWalkIn(cid, item, frompos)
 
 
  queststatus = getPlayerStorageValue(cid,5801)
  if queststatus == -1 then
 
pos = getPlayerPosition(cid)
telar = {x=208, y=87, z=15}
doTeleportThing(cid, telar, false)
doPlayerSendTextMessage(cid,180,"!!!!")
setPlayerStorageValue(cid,5801,1)
doSendMagicEffect(frompos,98)
 
 
else
setPlayerStorageValue(cid,5801,-1)
doTeleportThing(cid,pos)
doSendMagicEffect(frompos,98)
doSendAnimatedText(getPlayerPosition(cid), "!!!", 71)
setPlayerStorageValue(cid,5801,-1)
doPlayerSendTextMessage(cid,180,"Libertaçao!")
 
end
end

 

Nem foi, agora não funcionou nada no script, lembrando é pra 7.8 algumas funções não tem pra 7.8 =/

 

Tenta assim:

 

function onWalkIn(cid, item, frompos)

queststatus = getPlayerStorageValue(cid,5801)
if queststatus == -1 then
local pos = getPlayerPosition(cid)
local pos2 = {x=208, y=87, z=15}
doTeleportThing(cid, pos2)
doPlayerSendTextMessage(cid,180,"!!!!")
setPlayerStorageValue(cid,5801,1)
doSendMagicEffect(frompos,98)
else
setPlayerStorageValue(cid,5801,-1)
doTeleportThing(cid,pos)
doSendMagicEffect(frompos,98)
doSendAnimatedText(getPlayerPosition(cid), "!!!", 71)
setPlayerStorageValue(cid,5801,-1)
doPlayerSendTextMessage(cid,180,"Libertaçao!")
end
end

 

 

Vei esse até ta funcionando porem to levando debug =/ , alguma dica ?

Link para o comentário
Compartilhar em outros sites

  • 0

Dá erro no distro? Poste uma SS do erro.

Tente assim:

 

 

function onWalkIn(cid, item, frompos)

queststatus = getPlayerStorageValue(cid,5801)
if queststatus == -1 then
local pos = getPlayerPosition(cid)
local pos2 = {x=208, y=87, z=15}
doTeleportThing(cid, getThingPosition(pos2))
doPlayerSendTextMessage(cid,180,"!!!!")
setPlayerStorageValue(cid,5801,1)
doSendMagicEffect(frompos,98)
else
setPlayerStorageValue(cid,5801,-1)
doTeleportThing(cid,pos)
doSendMagicEffect(frompos,98)
doSendAnimatedText(getPlayerPosition(cid), "!!!", 71)
setPlayerStorageValue(cid,5801,-1)
doPlayerSendTextMessage(cid,180,"Libertaçao!")
end
end

 

Ou assim:

 

function onWalkIn(cid, item, frompos)

queststatus = getPlayerStorageValue(cid,5801)
if queststatus == -1 then
local pos = getPlayerPosition(cid)
local pos2 = {x=208, y=87, z=15}
doTeleportThing(cid, pos2, true)
doPlayerSendTextMessage(cid,180,"!!!!")
setPlayerStorageValue(cid,5801,1)
doSendMagicEffect(frompos,98)
else
setPlayerStorageValue(cid,5801,-1)
doTeleportThing(cid,pos)
doSendMagicEffect(frompos,98)
doSendAnimatedText(getPlayerPosition(cid), "!!!", 71)
setPlayerStorageValue(cid,5801,-1)
doPlayerSendTextMessage(cid,180,"Libertaçao!")
end
end
Editado por OriGM
Link para o comentário
Compartilhar em outros sites

  • 0


function onWalkIn(cid, item, frompos)

pos = getPlayerPosition(cid)

queststatus = getPlayerStorageValue(cid,5801)

local tpos = {x=208, y=87, z=15}

 

if queststatus == -1 then

doTeleportThing(cid, tpos)

doPlayerSendTextMessage(cid, 180, "!!!!")

setPlayerStorageValue(cid, 5801, 1)

doSendMagicEffect(frompos, 98)

else

setPlayerStorageValue(cid, 5801, -1)

doTeleportThing(cid, frompos)

doSendMagicEffect(frompos, 98)

doSendAnimatedText(getPlayerPosition(cid), "!!!", 71)

setPlayerStorageValue(cid, 5801, -1)

doPlayerSendTextMessage(cid, 180, "Libertaçao!")

end

return true

end

Link para o comentário
Compartilhar em outros sites

×
×
  • Criar Novo...