zMpyster Posted August 9, 2018 Posted August 9, 2018 Olá pessoal sou novo aqui no fórum e queria saber como resolver esse erro que está dando em meu painel DX, eu vi vários videos e todos falavam que se eu quisesse que o script não bugasse em outras resoluções eu teria que quem colocar "x* e y*" de prefixo. Sou novo na linguagem lua portanto não sei muito! Espero que compreendam . dxDrawRectangle(x*499, y*196, x*1, y*0, tocolor(255, 255, 255, 255), false) dxDrawRectangle(x*443, y*186, x*463, y*392, tocolor(0, 0, 0, 129), false) dxDrawRectangle(x*471, y*213, x*0, y*4, tocolor(255, 255, 255, 255), false) dxDrawRectangle(x*447, y*186, x*0, y*0, tocolor(255, 255, 255, 255), false) dxDrawLine(x*443 - 1, y*187 - 1, x*443 - 1, y*217, tocolor(0, 0, 0, 255), 1, false) dxDrawLine(x*906, y*187 - 1, x*443 - 1, y*187 - 1, tocolor(0, 0, 0, 255), 1, false) dxDrawLine(x*443 - 1, y*217, x*906, y*217, tocolor(0, 0, 0, 255), 1, false) dxDrawLine(x*906, y*217, x*906, y*187 - 1, tocolor(0, 0, 0, 255), 1, false) dxDrawRectangle(x*443, y*187, x*463, y*30, tocolor(0, 0, 0, 129), false) dxDrawText("", x*524, y*198, x*524, y*198, tocolor(255, 255, 255, 255), 1.00, "default", "left", "top", false, false, false, false, false) dxDrawText("AGÊNCIA DE EMPREGOS", x*608, y*196, x*749, y*212, tocolor(255, 255, 255, 255), 1.00, "default-bold", "left", "top", false, false, false, false, false) dxDrawRectangle(x*620, y*538, x*110, y*30, tocolor(0, 0, 0, 153), false) dxDrawText("Fechar", x*620, y*538, x*730, y*568, tocolor(255, 255, 255, 255), 1.00, "default", "center", "center", false, false, false, false, false) dxDrawText("Criado por: zMpyster", x*776, y*523, x*885, y*538, tocolor(255, 255, 255, 255), 1.00, "default", "left", "top", false, false, false, false, false) dxDrawLine(x*443 - 1, y*240 - 1, x*443 - 1, y*269, tocolor(0, 0, 0, 255), 1, false) dxDrawLine(x*832, y*240 - 1, x*443 - 1, y*240 - 1, tocolor(0, 0, 0, 255), 1, false) dxDrawLine(x*443 - 1, y*269, x*832, y*269, tocolor(0, 0, 0, 255), 1, false) dxDrawLine(x*832, y*269, x*832, y*240 - 1, tocolor(0, 0, 0, 255), 1, false) dxDrawRectangle(x*443, y*240, x*389, y*29, tocolor(12, 12, 35, 255), false) dxDrawText("CAMINHONEIRO", x*453, y*245, x*610, y*269, tocolor(255, 255, 255, 255), 1.00, "default", "center", "center", false, false, false, false, false) dxDrawText(" | R$ 500, 00", x*620, y*245, x*777, y*269, tocolor(255, 255, 255, 255), 1.00, "default", "center", "center", false, false, false, false, false) dxDrawLine(x*442 - 1, y*217 - 1, x*442 - 1, y*240, tocolor(0, 0, 0, 255), 1, false) dxDrawLine(x*906, y*217 - 1, x*442 - 1, y*217 - 1, tocolor(0, 0, 0, 255), 1, false) dxDrawLine(x*442 - 1, y*240, x*906, y*240, tocolor(0, 0, 0, 255), 1, false) dxDrawLine(x*906, y*240, x*906, y*217 - 1, tocolor(0, 0, 0, 255), 1, false) dxDrawRectangle(x*442, y*217, x*464, y*23, tocolor(8, 8, 25, 255), false) dxDrawText(" EMPREGO SALÁRIO", x*433, y*219, x*781, y*240, tocolor(255, 255, 255, 255), 0.50, "bankgothic", "left", "top", false, false, false, false, false) dxDrawLine(x*832 - 1, y*242 - 1, x*832 - 1, y*269, tocolor(0, 0, 0, 255), 1, false) dxDrawLine(x*906, y*242 - 1, x*832 - 1, y*242 - 1, tocolor(0, 0, 0, 255), 1, false) dxDrawLine(x*832 - 1, y*269, x*906, y*269, tocolor(0, 0, 0, 255), 1, false) dxDrawLine(x*906, y*269, x*906, y*242 - 1, tocolor(0, 0, 0, 255), 1, false) dxDrawRectangle(x*832, y*242, x*74, y*27, tocolor(28, 28, 28, 255), false) dxDrawText("ACEITAR", x*842, y*242, x*896, y*269, tocolor(255, 255, 255, 255), 0.50, "bankgothic", "center", "center", false, false, false, false, false) end erro: attempt to perform arithmetic on global 'x' (a nil value
Moderators Lord Henry Posted August 10, 2018 Moderators Posted August 10, 2018 Da próxima vez, poste na sessão correta de Programação em Lua. E poste seu código usando a ferramenta de código do fórum para que ele seja legível. Eu te ajudei ou achou meu comentário útil? Não esqueça de deixar um Thanks! Minhas contribuições para a comunidade: LordHenry - MTA Wiki Profile Inscreva-se no meu canal do YouTube: Lord Henry - Entertainment Discord Oficial do MTA: https://mtasa.com/discord Blacklist e Whitelist de Scripters: Planilha Por favor, não me envie mensagens privadas solicitando suporte. Crie um tópico no fórum em vez disso.
DNL291 Posted August 27, 2018 Posted August 27, 2018 Não é assim, essas são variáveis que você precisam definir antes usando a resolução nativa e a obtida com guiGetScreenSize. Please do not PM me with scripting related question nor support, use the forums instead.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now