-
Posts
3,990 -
Joined
-
Last visited
-
Days Won
182
Everything posted by Lord Henry
-
Já pediu ajuda pra quem desenvolveu o script? AirNew Scripter.
-
setPedWalkingStyle
-
function sairVeh (theVehicle) if (getElementModel (theVehicle) == 411) then outputChatBox ("- Você saiu do veículo e foi reprovado.", source) setElementPosition (source, 1481.06, -1601.6, 13.55) destroyElement (theVehicle) end end addEventHandler ("onPlayerVehicleExit", root, sairVeh)
-
createMarker onClientMarkerHit ou bindKey ou addCommandHandler onClientClick dxDrawRectangle dxDrawText dxDrawCircle isMouseInPosition (useful function)
-
Não exagere no uso de Caps Lock. Veja as regras do fórum aqui. Sistema de inventário + loja é muito complexo. Você está querendo dar "um passo maior que a perna". MTA Brasil é apenas um site que junta conteúdo de outros blogs. Você não posta diretamente lá. Se quer publicar seus resources, poste no site oficial da comunidade do MTA: https://community.multitheftauto.com/index.php?p=resources Para fazer feedback nos botões DX ao passar o mouse em cima, recomendo a função útil isMouseInPosition.
-
Deixe um Thanks nas respostas que lhe ajudaram.
-
Na sua linha 4, thePlayer não foi definido em lugar nenhum.
-
dxDrawText (Nome, 1257, 69, 1388, 97, tocolor(255, 255, 255, 255), 1, "default-bold", "center", "top", false, false, false, true)
-
[HELP] error: Attempt to compare number with boolean - line 225
Lord Henry replied to sanleygfx's topic in Programação em Lua
Utilize o botão <> do fórum para postar códigos. Não cole direto no texto. -
Como eu edito a zona safe ? as coordenadas no caso..
Lord Henry replied to +JOKER's topic in Programação em Lua
Fecharei este tópico por excesso de spam. Quando aprender a formatar adequadamente, solicite o desbloqueio. O mesmo vale para o uso indevido do "quote". Você pode ver as regras e formatações aqui: -
isObjectInACLGroup
-
setElementModel
-
Não se usa triggerClientEvent em um script client-side.
-
local isDxShowing = false function drawDX() dxDrawImage(650, 82, 520, 522, "painelpmerj.png", 0, 0, 0, tocolor(255, 255, 255, 255), false) dxDrawRectangle(852, 255, 117, 24, tocolor(0, 0, 0, isCursorOnElement (852, 255, 117, 24) and 200 or 110), false) -- Retângulos que ficam com alpha em 200 quando o mouse está em cima. dxDrawRectangle(852, 289, 117, 24, tocolor(0, 0, 0, isCursorOnElement (852, 289, 117, 24) and 200 or 110), false) dxDrawRectangle(852, 323, 117, 24, tocolor(0, 0, 0, isCursorOnElement (852, 323, 117, 24) and 200 or 110), false) dxDrawRectangle(852, 357, 117, 24, tocolor(0, 0, 0, isCursorOnElement (852, 357, 117, 24) and 200 or 110), false) dxDrawRectangle(860, 401, 101, 22, tocolor(0, 0, 0, isCursorOnElement (860, 401, 101, 22) and 200 or 110), false) dxDrawText("Farda 04", 852, 357, 969, 381, tocolor(255, 255, 255, 200), 1.00, "default-bold", "center", "center", false, false, false, false, false) dxDrawText("Farda 03", 852, 323, 969, 347, tocolor(255, 255, 255, 200), 1.00, "default-bold", "center", "center", false, false, false, false, false) dxDrawText("Farda 02", 852, 289, 969, 313, tocolor(255, 255, 255, 200), 1.00, "default-bold", "center", "center", false, false, false, false, false) dxDrawText("Farda 01", 852, 255, 969, 279, tocolor(255, 255, 255, 200), 1.00, "default-bold", "center", "center", false, false, false, false, false) dxDrawText("Fechar", 860, 399, 961, 423, tocolor(255, 255, 255, 200), 0.90, "default-bold", "center", "center", false, false, false, false, false) end function gerenciaPainel () if isDxShowing then removeEventHandler ("onClientRender", getRootElement(), drawDX) showCursor (false) isDxShowing = false else addEventHandler ("onClientRender", getRootElement(), drawDX) showCursor (true) isDxShowing = true end end addEvent ("ativaPainel", true) addEventHandler ("ativaPainel", getRootElement(), gerenciaPainel) addEventHandler ("onClientClick", getRootElement(), function (button, state, absoluteX, absoluteY) if (button == "left") and (state == "up") and isDxShowing then if isCursorOnElement (860, 401, 101, 22) then -- Fechar gerenciaPainel () elseif isCursorOnElement (852, 255, 117, 24) then -- Farda 01 outputChatBox ("pegou farda 01") elseif isCursorOnElement (852, 289, 117, 24) then -- Farda 02 outputChatBox ("pegou farda 02") elseif isCursorOnElement (852, 323, 117, 24) then -- Farda 03 outputChatBox ("pegou farda 03") elseif isCursorOnElement (852, 357, 117, 24) then -- Farda 04 outputChatBox ("pegou farda 04") end end end) -- Esta é uma Função Útil function isCursorOnElement( posX, posY, width, height ) if isCursorShowing( ) then local mouseX, mouseY = getCursorPosition( ) local clientW, clientH = guiGetScreenSize( ) local mouseX, mouseY = mouseX * clientW, mouseY * clientH if ( mouseX > posX and mouseX < ( posX + width ) and mouseY > posY and mouseY < ( posY + height ) ) then return true end end return false end
-
Mostre o que você já tentou fazer.
-
E cadê o portfólio? Mostrando seu trabalho.
-
Ele está dizendo que o terceiro item da table firstClipArr é nulo. Não existe.
-
[AJUDA]Como-Ver-Quanto-o-Player-Tem-No-Banco
Lord Henry replied to K13's topic in Programação em Lua
getPlayerFromName getPlayerAccount isObjectInACLGroup getAccountData outputChatBox addCommandHandler- 1 reply
-
- 1
-
-
Sem o código n tem como adivinhar.
-
Vc pode fazer com a função útil DxDrawProgressBar ou então a função útil DxDrawLoading. Elas funcionam de maneiras diferentes.
-
Comigo nunca acontece isso. Mas tente usar isso: setOcclusionsEnabled (false)
-
Seria interessante você corrigir a indentação.
-
Os dois primeiros timers estão executando ao mesmo tempo (30 segundos depois). Coloque um dentro do outro, assim o timer vai iniciar só depois que o outro for executado.
-
Cara, não é recomendável usar resources compilados. Pois você nunca sabe o que realmente tem dentro deles. Pode existir até ameaças ao seu servidor e você não tem como arrumar.
-
Queda de FPS no servidor
Lord Henry replied to +JOKER's topic in Ajudas relacionadas ao MTA:SA (Cliente/Servidor)
Você está com resources pesados ou mal otimizados.