Postado Janeiro 16, 2016 9 anos Cara, agora entendi. Põe assim: Spoiler function onUse(cid, item, frompos, item2, topos) config = { wall1 = {x=88, y=188, z=7, stackpos=1} wall2 = {x=88, y=189, z=7, stackpos=1} getwall1 = getThingfromPos(wall1) getwall2 = getThingfromPos(wall2) tempo = 2 -- temop em minutos aqui } function remove() local itemA = getThingFromPos(config.wall1) local itemB = getThingFromPos(config.wall2) doRemoveItem(itemA.uid, 1) doRemoveItem(itemB.uid, 1) return true end if item.uid == 60010 and (item.itemid == 9825 or item.itemid == 9826) then doCreateItem(13017,1,config.wall1) doCreateItem(13017,1,config.wall2) doPlayerSendTextMessage(cid,22,"Uma nova passagem foi aberta!") addEvent(remove, config.tempo*60*1000) if (item.itemid == 9825) then doTransformItem(item.uid,item.itemid+1) else doTransformItem(item.uid,item.itemid-1) end else else doPlayerSendTextMessage(cid,22,"Não é possivel realizar esta ação.") end end Edited: kkkkkkkkkkkkkkk, ganhar donate é f**da hahahahah Editado Janeiro 16, 2016 9 anos por Xagah (veja o histórico de edições) The Last Man Standing - 100% funcional
Postado Janeiro 16, 2016 9 anos Autor 7 minutos atrás, Xagah disse: Cara, agora entendi. Põe assim: Ocultar conteúdo function onUse(cid, item, frompos, item2, topos) config = { wall1 = {x=88, y=188, z=7, stackpos=1} wall2 = {x=88, y=189, z=7, stackpos=1} getwall1 = getThingfromPos(wall1) getwall2 = getThingfromPos(wall2) tempo = 2 -- temop em minutos aqui } function remove() local itemA = getThingFromPos(config.wall1) local itemB = getThingFromPos(config.wall2) doRemoveItem(itemA.uid, 1) doRemoveItem(itemB.uid, 1) return true end if item.uid == 60010 and (item.itemid == 9825 or item.itemid == 9826) then doCreateItem(13017,1,config.wall1) doCreateItem(13017,1,config.wall2) doPlayerSendTextMessage(cid,22,"Uma nova passagem foi aberta!") addEvent(remove, config.tempo*60*1000) if (item.itemid == 9825) then doTransformItem(item.uid,item.itemid+1) else doTransformItem(item.uid,item.itemid-1) end else else doPlayerSendTextMessage(cid,22,"Não é possivel realizar esta ação.") end end Man deeu este erro no distro: '}' expected (to close '{' at line 4) near 'wall2'
Postado Janeiro 16, 2016 9 anos Corrige aí: Spoiler function onUse(cid, item, frompos, item2, topos) local wall1 = {x=88, y=188, z=7, stackpos=1} local wall2 = {x=88, y=189, z=7, stackpos=1} local getwall1 = getThingfromPos(wall1) local getwall2 = getThingfromPos(wall2) local tempo = 2 -- temop em minutos aqui function remove() local itemA = getThingFromPos(wall1) local itemB = getThingFromPos(wall2) doRemoveItem(itemA.uid, 1) doRemoveItem(itemB.uid, 1) return true end if item.uid == 60010 and (item.itemid == 9825 or item.itemid == 9826) then doCreateItem(13017,1,wall1) doCreateItem(13017,1,wall2) doPlayerSendTextMessage(cid,22,"Uma nova passagem foi aberta!") addEvent(remove,tempo*60*1000) if (item.itemid == 9825) then doTransformItem(item.uid,item.itemid+1) else doTransformItem(item.uid,item.itemid-1) end else else doPlayerSendTextMessage(cid,22,"Não é possivel realizar esta ação.") end end The Last Man Standing - 100% funcional
Postado Janeiro 16, 2016 9 anos Autor 3 minutos atrás, Xagah disse: Corrige aí: Ocultar conteúdo function onUse(cid, item, frompos, item2, topos) local wall1 = {x=88, y=188, z=7, stackpos=1} local wall2 = {x=88, y=189, z=7, stackpos=1} local getwall1 = getThingfromPos(wall1) local getwall2 = getThingfromPos(wall2) local tempo = 2 -- temop em minutos aqui function remove() local itemA = getThingFromPos(wall1) local itemB = getThingFromPos(wall2) doRemoveItem(itemA.uid, 1) doRemoveItem(itemB.uid, 1) return true end if item.uid == 60010 and (item.itemid == 9825 or item.itemid == 9826) then doCreateItem(13017,1,wall1) doCreateItem(13017,1,wall2) doPlayerSendTextMessage(cid,22,"Uma nova passagem foi aberta!") addEvent(remove,tempo*60*1000) if (item.itemid == 9825) then doTransformItem(item.uid,item.itemid+1) else doTransformItem(item.uid,item.itemid-1) end else else doPlayerSendTextMessage(cid,22,"Não é possivel realizar esta ação.") end end novo erro 'end' expected (to close 'if' at line 18) near 'elser'
Postado Janeiro 16, 2016 9 anos AeaueiHaui aGORA VAI! HAHAH function onUse(cid, item, frompos, item2, topos) local wall1 = {x=88, y=188, z=7, stackpos=1} local wall2 = {x=88, y=189, z=7, stackpos=1} local getwall1 = getThingfromPos(wall1) local getwall2 = getThingfromPos(wall2) local tempo = 2 -- temop em minutos aqui function remove() local itemA = getThingFromPos(wall1) local itemB = getThingFromPos(wall2) doRemoveItem(itemA.uid, 1) doRemoveItem(itemB.uid, 1) return true end if item.uid == 60010 and (item.itemid == 9825 or item.itemid == 9826) then doCreateItem(13017,1,wall1) doCreateItem(13017,1,wall2) doPlayerSendTextMessage(cid,22,"Uma nova passagem foi aberta!") addEvent(remove,tempo*60*1000) if (item.itemid == 9825) then doTransformItem(item.uid,item.itemid+1) else doTransformItem(item.uid,item.itemid-1) end else doPlayerSendTextMessage(cid,22,"Não é possivel realizar esta ação.") end The Last Man Standing - 100% funcional
Participe da conversa
Você pode postar agora e se cadastrar mais tarde. Se você tem uma conta, faça o login para postar com sua conta.