Jump to content

Blaack

Members
  • Posts

    197
  • Joined

  • Last visited

  • Days Won

    4

Everything posted by Blaack

  1. tente: function botoes ( _,state ) if DX_Inventario == true then if state == "down" then if Posicao_Mouse_Inventario(x*440, y*320, x*180, y*35) then --Armas playSound("sounds/click.mp3", false) addEventHandler("onClientRender", root, armas) removeEventHandler ( "onClientRender", getRootElement(), alimentos ) removeEventHandler ( "onClientRender", getRootElement(), utilitarios ) removeEventHandler ( "onClientRender", getRootElement(), outros ) end if Posicao_Mouse_Inventario(x*445, y*445, x*80, y*20) then -- img 1 playSound("sounds/click.mp3", false) end end end end addEventHandler("onClientClick", root, botoes)
  2. Use: getDistanceBetweenPoints3D Ou mande seu código!
  3. Esse script quem fez fui eu kk, tempos atrás quando eu estava começando!
  4. Exemplo que está na wiki: -- define our chat radius local chatRadius = 20 --units -- define a handler that will distribute the message to all nearby players function sendMessageToNearbyPlayers(message, messageType) -- we will only send normal chat messages, action and team types will be ignored if messageType == 0 then -- get the chatting player's position local posX1, posY1, posZ1 = getElementPosition(source) -- loop through all player and check distance for id, player in ipairs(getElementsByType("player")) do local posX2, posY2, posZ2 = getElementPosition(player) if getDistanceBetweenPoints3D(posX1, posY1, posZ1, posX2, posY2, posZ2) <= chatRadius then outputChatBox(message, player) end end end -- block the original message by cancelling this event cancelEvent() end -- attach our new chat handler to onPlayerChat addEventHandler( "onPlayerChat", getRootElement(), sendMessageToNearbyPlayers ) Se ler a wiki, conseguirá fazer facil... tem vários exemplos lá!
  5. use localPlayer alias de source! ou mande seu código!
  6. Já tentou ver se há algum bug no /debugscript 3?
  7. Não entendi! Assim? function DNL_Hud() for _, component in ipairs( components ) do setPlayerHudComponentVisible( component, false ) end dxDrawRectangle(x*835, y*50, x*521, y*34, tocolor(32, 32, 33), false) dxDrawRectangle(x*835, y*50, x*521, y*34, tocolor(150, 16, 148), false) dxDrawLine(x*835, y*74, x*1356, y*74, tocolor(0, 0, 0), x*2, false) dxDrawLine(x*998, y*73, x*998, y*40, tocolor(0, 0, 0), x*1, false) dxDrawLine(x*1170, y*74, x*1170, y*41, tocolor(0, 0, 0), x*1, false) 
  8. function BloquearChat(message) outputChatBox("#FF0000[ERRO] #FFFFFF Chat desativado! Use o somente o chat local! Apertando a letra 'U' ", source, 255, 255, 255, true) cancelEvent() end addEventHandler("onPlayerChat", root, BloquearChat) Tenta ai (Freeroam desativado please)
  9. Creio que ai não está definindo quem é o elemento source. Tenta ai : (Nao testado) local timer = 500 function desaparecer() if getElementType(source) == "vehicle" then setTimer(destroyElement, timer, 1, source) end end addEventHandler("onVehicleExplode",getRootElement(), desaparecer)
  10. Mande o erro que aparece no /debugscript, e mande o código do script aqui, para que posssamos ajuda-lo
  11. Exatamente oque o lord falou, você não deve ter ligado o DxMessages.
  12. Quais erros da no debug brother ?
  13. A Certo, lerdeza minha kkk desculpe
  14. Eu usei o setCameraMatrix para fazer uma "cutscene"
  15. Cara, só te olhar estou vendo uns erros; este script voce fez do 0 ? eu te recomendo recomeçar...
  16. Este código quem fez foi você ? e você quer acl pra que ?
  17. Para aparecer o blip do player que solicitou você tem que usar as functions setElementData getElementData createBlipAttachedTo
  18. Caso não consiga, mande seu código
×
×
  • Create New...