Jump to content

Ramon987

Members
  • Posts

    16
  • Joined

  • Last visited

Everything posted by Ramon987

  1. Eu fiz dessa forma só que acrescentei o onVehicleExit e funcionou perfeitamente. Obrigado <3 addEventHandler ("onVehicleExit", getRootElement(), finishExmanigAutoS )
  2. Troquei thePlayer por source e msm assim ainda quando termino o teste o carro e destruído mas eu não sou teleportado setElementPosition (source, -2029.6142578125, -116.66015625, 1035.171875)
  3. SIM function chek (elem) --if getElementType ( elem ) == "vehicle" then --local driver = getVehicleOccupant ( elem ) local driver = elem if elem == localPlayer then local markelem = getElementData ( driver, "drivingMarker" ) local markid = getElementData ( driver, "drivingMarkerID" ) if isElement ( markelem ) and markelem == source and markid then if markid == #markersPos then triggerServerEvent ( 'finishExmanigAuto', localPlayer ) destroyElement (source) setElementData ( driver, "drivingMarker", false ) setElementData ( driver, "drivingMarkerID", false ) elseif markid < #markersPos then setElementData ( driver, "drivingMarkerID", markid + 1 ) setElementPosition ( markelem, markersPos[markid+1][1],markersPos[markid+1][2],markersPos[markid+1][3]) end else setElementData ( driver, "drivingMarker", false ) setElementData ( driver, "drivingMarkerID", false ) end end end Ta aqui, em outro .lua
  4. function finishExmanigAutoS () local veh = getPedOccupiedVehicle ( source ) if isElement ( veh ) then destroyElement ( veh ) ac = getPlayerAccount ( source ) setAccountData ( ac, "carLicense", "1" ) setElementData ( source, "carLicense", true) outputChatBox ( "#FF0000-Auto Escola-#FFFF00Parabéns! Você passou No Teste!", source, 0, 255, 0, true ) outputChatBox ( "#FF0000-Auto Escola-#FFFF00Aqui Esta A Sua Habilitação E não quebre as regras.", source, 0, 255, 0, true ) setElementPosition (thePlayer, -2029.6142578125, -116.66015625, 1035.171875) end end addEvent( "finishExmanigAuto", true ) addEventHandler( "finishExmanigAuto", getRootElement(), finishExmanigAutoS ) Pra fazer a mesma coisa só que aqui tenho que fazer oque?
  5. Eu fiz isso e o veiculo n foi destruído e eu não fui teleportado
  6. ja sim e não funcionou, dessa vez o carro nem foi destruído
  7. function killt(thePlayer) theVehicle = getPedOccupiedVehicle ( thePlayer ) id = getElementModel ( theVehicle ) if id == 479 then account = getPlayerAccount ( thePlayer ) setAccountData ( acc, "carLicense", "0" ) setElementData ( thePlayer, "carLicense", false) outputChatBox ( "#FF0000-Auto Escola-#FFFF00Você não passou no Teste.", thePlayer, 255, 0,0,true) destroyElement (source) setElementPosition(source, 2442.2177734375, -1969.490234375, 13.546875) end end addEventHandler ( "onVehicleExit", getRootElement(), killt ) triggerClientEvent ( source, "startExaming", source ) end end dessa maneira? Ou devo deixar no setElementPosition, trocado source por thePlayer.
  8. function killt(thePlayer) theVehicle = getPedOccupiedVehicle ( thePlayer ) id = getElementModel ( theVehicle ) if id == 479 then account = getPlayerAccount ( thePlayer ) setAccountData ( acc, "carLicense", "0" ) setElementData ( thePlayer, "carLicense", false) outputChatBox ( "#FF0000-Auto Escola-#FFFF00Você não passou no Teste.", thePlayer, 255, 0,0,true) veh = getPedOccupiedVehicle ( thePlayer ) destroyElement (veh) setElementPosition(thePlayer, 2442.2177734375, -1969.490234375, 13.546875) end end addEventHandler ( "onVehicleStartExit", getRootElement(), killt ) triggerClientEvent ( source, "startExaming", source ) end end Isso não funcionou. continua saindo do veiculo e ficando no mesmo local, me ajuda a resolver isso por favor No setElementPosition, troquei source por thePlayer.
  9. function auto ( ) if getElementData ( source, "carLicense" ) then outputChatBox ( "#FF0000-Auto Escola-#FFFF00Você já passou No Teste!", source, 200, 0, 0, true ) else vedro = createVehicle ( 479, 1615.8929443359,-1135.5010986328,23.90625,0,0,0 ) setElementInterior (source,0) setElementDimension (source,0) acc = getPlayerAccount ( source ) setAccountData ( acc, "carLicense", "1" ) setElementData ( source, "carLicense", true) warpPedIntoVehicle ( source, vedro ) outputChatBox ( "#FF0000-Auto Escola-#FFFF00Você começou O Teste.", source, 255, 0, 0, true ) outputChatBox ( "#FF0000-Auto Escola-#FFFF00Siga os Marcadores Vermelhos Para completar O Teste.", source, 255, 0, 0, true ) outputChatBox ( "#FF0000-Auto Escola-#FFFF00Boa Sorte No Teste ", source, 255, 0, 0, true ) function killt(thePlayer) theVehicle = getPedOccupiedVehicle ( thePlayer ) id = getElementModel ( theVehicle ) if id == 479 then account = getPlayerAccount ( thePlayer ) setAccountData ( acc, "carLicense", "0" ) setElementData ( thePlayer, "carLicense", false) outputChatBox ( "#FF0000-Auto Escola-#FFFF00Voce nao passou no teste.", thePlayer, 255, 0, 0, true ) veh = getPedOccupiedVehicle ( thePlayer ) destroyElement (veh) setElementPosition(source,2442.2177734375, -1969.490234375, 13.546875) end end addEventHandler ( "onVehicleStartExit", getRootElement(), killt ) triggerClientEvent ( source, "startExaming", source ) end end addEventHandler( "markers", getRootElement(), auto ) Me ajudem quero fazer com que quando o jogador sair do veiculo ele seja levado para o local de onde saiu, irá teleporta para onde começou o teste. E os marcadores seja deletado Help me, I want to make sure that when the player leaves the vehicle he is taken to where he left, he will teleport where he started the test. And the markers are deleted function killt(thePlayer) theVehicle = getPedOccupiedVehicle ( thePlayer ) id = getElementModel ( theVehicle ) if id == 479 then account = getPlayerAccount ( thePlayer ) setAccountData ( acc, "carLicense", "0" ) setElementData ( thePlayer, "carLicense", false) outputChatBox ( "#FF0000-Auto Escola-#FFFF00Voce nao passou no teste.", thePlayer, 255, 0, 0, true ) veh = getPedOccupiedVehicle ( thePlayer ) destroyElement (veh) setElementPosition(source,2442.2177734375, -1969.490234375, 13.546875) Oque eu fiz de errado aqui? What did I do wrong here?
  10. function playerKilled (ammo, killer, weapon, bodypart) if killer then -- Se morreu por causa de alguém, então: if getElementType (killer) == "player" then -- Se quem matou for um jogador, então: setWl (killer, 6, 180, "TESTE") -- O jogador que matou fica com nível 6 de procurado. elseif getElementType (killer) == "vehicle" then -- Se quem matou for um veículo, então: killer = getVehicleController (killer) -- Killer passa a ser quem está dirigindo o veículo que matou o jogador. if killer then -- Se existe alguém dirigindo o veículo, então: setWl(killer, 4, 180, "TESTE") -- O motorista fica com nível 6 de procurado. end end end -- Se o jogador morreu por suicidio, nada acontece. end addEventHandler ("onPlayerWasted", getRootElement(), playerKilled) Muito obrigado agora esta funcionando perfeitamente
  11. Cara Obrigado <3 Tenho uma outro dificuldade só que bem mais simples. pode me ajudar?
  12. function client_kill_ped(ped, killer, body_part) if not ped or not isElement(ped) or isPedDead(ped) or getPedOccupiedVehicle(ped) then return end if not killer or not isElement(killer) or not getPedOccupiedVehicle(killer) or getPedOccupiedVehicleSeat(killer) > 0 then return end local px,py,pz = getElementPosition(ped) local kx,ky,kz = getElementPosition(killer) if getDistanceBetweenPoints3D(px,py,pz, kx,ky,kz) > 10 then return end killPed(ped, killer, 255, body_part, false) setWl(killer, 0.4, 60, "You committed the crime of murder") end Queria trocar isso para um de quando um player mata o outro recebera nivel de procurado. Tendeu? obs: Não sei como posta as coisa aqui ainda e sei muito pouco de script
  13. Não sei quase nada de scripts Eu quero fazer que quando um jogar matar o outro recebera 6 nives de procurado function client_kill_ped(ped, killer, body_part) if not ped or not isElement(ped) or isPedDead(ped) or getPedOccupiedVehicle(ped) then return end if not killer or not getElementType( attacker ) == "player" ) then end local px,py,pz = getElementPosition(ped) local kx,ky,kz = getElementPosition(killer) if getDistanceBetweenPoints3D(px,py,pz, kx,ky,kz) > 10 then return end killPed(ped, killer, 255, body_part, false) setWl(killer, 6.0, 60, "Você cometeu o crime de assassinato") US: I know almost nothing about scripts I want to do that when one player kills the other he receives 6 levels of wanted
  14. alguém sabe me indicar um script de trabalho de policia que seja simples mais completo Tenha o painel, escolha pele, pegar arma etc ... mais o principal é que de acordo com o registro de procurado do jogador ele ficara preso. exemplo: ele esta com pedido de procuração, é uma policia prende ele ficara 1 minuto na cadeia, com 2 level ficara mais tempo, 3 ainda mais... ES Alguém pode me dizer um simples script de trabalho da polícia que é mais completo Tenha o painel, escolha a pele, pegue a arma etc. Mas o principal é que, de acordo com o registro desejado do jogador, ele foi preso. exemplo: ele está com um pedido de procuração por isso é uma prisão policial ele ficou 1 minuto na prisão, com uma série de mais tempo, mais 3 ...
×
×
  • Create New...