zTokyoGamer Posted October 1, 2019 Posted October 1, 2019 (edited) Estou criando um systema de construção de bases para meu servidor de DayZ estou tentando que como move o objeto manual e não estou conseguindo cria esta função por exemplo apos eu colocar ele no local eu queria usa algum tipo de tecla para muda as rotação clicando na tecla e move ele clicando nele e coloca no luga que vou clica para ele fica , alguém poderia mim ajuda já estou virando madrugadas pesquisando estudando tentando fazer isso e esta um pouco complicado para mim! Imagem: Server.Lua addEvent ("Wooden", true) addEventHandler ("Wooden", getRootElement(), function() if (getPlayerMoney (source) >= tonumber(400)) then outputChatBox("#00FF00Você colocou um Wooden Parede", source, 255, 255, 255 , true) local x,y,z = getElementPosition(source) setElementPosition ( source, posX, posY, posZ ) obj = createObject(3260,x,y + 3,z, -0, 0, 350.093) -- ID DO OBJETO + POSIÇÃO setTimer ( destroyElement, 172800000, 1, obj ) -- 2 Dias takePlayerMoney (source, tonumber (400)) else outputChatBox ("Você é muito pobre!", source, 255, 0, 0, false) end end) Client.Lua iSantistaWindow = guiCreateWindow(203, 154, 270, 370, "Painel Criar Base ~DayZ", false) guiWindowSetSizable(iSantistaWindow, false) guiSetAlpha(iSantistaWindow, 1.00) selecionar = guiCreateButton(9, 310, 270, 50, "COLOCAR", false, iSantistaWindow) guiSetFont(selecionar, "default-bold-small") guiSetProperty(selecionar, "NormalTextColour", "FFFFFFFF") Horns = guiCreateGridList(9, 24, 270, 280, false, iSantistaWindow) guiGridListSetSelectionMode(Horns, 1) column = guiGridListAddColumn(Horns, "Itens", 0.9) local painel painel = guiGridListAddRow(Horns) guiGridListSetItemText(Horns, painel, 1, "MADEIRA", false, false) guiGridListSetItemColor (Horns, painel, 1, 255, 0, 0 ) painel = guiGridListAddRow(Horns) guiGridListSetItemText(Horns, painel, 1, " Wooden Parede 400 GOLD", false, false) painel = guiGridListAddRow(Horns) guiGridListSetItemText(Horns, painel, 1, " Wood Fence 420 GOLD", false, false) painel = guiGridListAddRow(Horns) guiGridListSetItemText(Horns, painel, 1, " Wooden Door 300 GOLD", false, false) painel = guiGridListAddRow(Horns) guiGridListSetItemText(Horns, painel, 1, " Wood Structure 500 GOLD", false, false) painel = guiGridListAddRow(Horns) guiGridListSetItemText(Horns, painel, 1, "METAL", false, false) guiGridListSetItemColor (Horns, painel, 1, 255, 0, 0 ) painel = guiGridListAddRow(Horns) guiGridListSetItemText(Horns, painel, 1, " Metal Fence 600 GOLD", false, false) painel = guiGridListAddRow(Horns) guiGridListSetItemText(Horns, painel, 1, " Metal Door 570 GOLD", false, false) painel = guiGridListAddRow(Horns) guiGridListSetItemText(Horns, painel, 1, " Metal Galpao 900 GOLD", false, false) painel = guiGridListAddRow(Horns) guiGridListSetItemText(Horns, painel, 1, " Metal Escada 460 GOLD", false, false) painel = guiGridListAddRow(Horns) guiGridListSetItemText(Horns, painel, 1,"LUZES", false, false) guiGridListSetItemColor (Horns, painel, 1, 255, 0, 0 ) painel = guiGridListAddRow(Horns) guiGridListSetItemText(Horns, painel, 1," Lampada 1 100 GOLD", false, false) painel = guiGridListAddRow(Horns) guiGridListSetItemText(Horns, painel, 1," Lampada 2 150 GOLD", false, false) painel = guiGridListAddRow(Horns) guiGridListSetItemText(Horns, painel, 1," Tocha 200 GOLD", false, false) painel = guiGridListAddRow(Horns) guiGridListSetItemText(Horns, painel, 1," Explosivo 350 GOLD", false, false) painel = guiGridListAddRow(Horns) guiGridListSetItemText(Horns, painel, 1," Sofa 120 GOLD", false, false) guiSetVisible(iSantistaWindow, false) local player = getLocalPlayer() addEventHandler("onClientGUIClick", selecionar, function() local row, column = guiGridListGetSelectedItem(Horns) if row == 1 then ----- CZ triggerServerEvent("Wooden", player, 2) elseif row == 2 then ----- M4 triggerServerEvent("Fence", player,3) elseif row == 3 then ----- M4 triggerServerEvent("Door", player,4) elseif row == 4 then ----- M4 triggerServerEvent("Structure", player,6) elseif row == 6 then ----- M4 triggerServerEvent("Fence2", player,7) elseif row == 7 then ----- M4 triggerServerEvent("Door2", player,8) elseif row == 8 then ----- M4 triggerServerEvent("Galpao", player,9) elseif row == 9 then ----- M4 triggerServerEvent("Escada", player,10) elseif row == 11 then ----- M4 triggerServerEvent("Luz", player,12) elseif row == 12 then ----- M4 triggerServerEvent("Luz2", player,13) elseif row == 13 then ----- M4 triggerServerEvent("Tocha", player,14) elseif row == 14 then ----- M4 triggerServerEvent("Explosivo", player,15) elseif row == 15 then ----- M4 triggerServerEvent("Sofa", player,16) end end, false) basecreat = function() if guiGetVisible(iSantistaWindow) then guiSetVisible(iSantistaWindow, false) showCursor(false) else guiSetVisible(iSantistaWindow, true) showCursor(true) end end addEvent("ShowGUI", true) addEventHandler("ShowGUI", getRootElement(), basecreat) Edited October 2, 2019 by Lord Henry Link convertido em imagem [BR] • VIDA DE JOVEM • ~ ROLEPLAY ~ [ CORPS, VOICE, GANGS, VIPS ] VENHA CONHECER NOSSO SERVIDOR ~ R O L E P L A Y ~ SERVIDOR NOVO BEM CONFIGURADO COMPACTADO LEVE COM UM BOM PING Obs: Depende da Sua NET! Staff Sempre Online Vagas Abertas Para todos tipo de trabalhos CORPS, GANGS, SAMU, MECANICOS e Muitos Outros Trabalhos Vale a pena Visita passe seus 10Minutos Aqui e venha conhecer a verdadeira diversão de um R O L E P L A Y ID: mtasa://54.39.244.81:22853 DISCORD: discord.gg/jEyd4J3 PAGINA: https://www.facebook.com/VidaDeJovemBR/ WhatsApp: 71 987647252
zTokyoGamer Posted October 2, 2019 Author Posted October 2, 2019 Help? [BR] • VIDA DE JOVEM • ~ ROLEPLAY ~ [ CORPS, VOICE, GANGS, VIPS ] VENHA CONHECER NOSSO SERVIDOR ~ R O L E P L A Y ~ SERVIDOR NOVO BEM CONFIGURADO COMPACTADO LEVE COM UM BOM PING Obs: Depende da Sua NET! Staff Sempre Online Vagas Abertas Para todos tipo de trabalhos CORPS, GANGS, SAMU, MECANICOS e Muitos Outros Trabalhos Vale a pena Visita passe seus 10Minutos Aqui e venha conhecer a verdadeira diversão de um R O L E P L A Y ID: mtasa://54.39.244.81:22853 DISCORD: discord.gg/jEyd4J3 PAGINA: https://www.facebook.com/VidaDeJovemBR/ WhatsApp: 71 987647252
DNL291 Posted October 3, 2019 Posted October 3, 2019 Movido para Programação em Lua @zTokyoGamer Sobre o tópico: Você vai precisar de vários cálculos, te recomendo ver o código do Map editor como referência. Please do not PM me with scripting related question nor support, use the forums instead.
zTokyoGamer Posted October 3, 2019 Author Posted October 3, 2019 @DNL291 Já fiz isso meu querido e não deu muito certo mas vou continua aqui se souber os código que irei usa mim diz ai que fica mas fácil [BR] • VIDA DE JOVEM • ~ ROLEPLAY ~ [ CORPS, VOICE, GANGS, VIPS ] VENHA CONHECER NOSSO SERVIDOR ~ R O L E P L A Y ~ SERVIDOR NOVO BEM CONFIGURADO COMPACTADO LEVE COM UM BOM PING Obs: Depende da Sua NET! Staff Sempre Online Vagas Abertas Para todos tipo de trabalhos CORPS, GANGS, SAMU, MECANICOS e Muitos Outros Trabalhos Vale a pena Visita passe seus 10Minutos Aqui e venha conhecer a verdadeira diversão de um R O L E P L A Y ID: mtasa://54.39.244.81:22853 DISCORD: discord.gg/jEyd4J3 PAGINA: https://www.facebook.com/VidaDeJovemBR/ WhatsApp: 71 987647252
yanz3ra Posted October 19, 2019 Posted October 19, 2019 Já conseguiu arrumar? Te mandei mensagem no privado de uma olhada
zTokyoGamer Posted October 23, 2019 Author Posted October 23, 2019 Ainda não amigo @yanz3ra irei olha mas dez de já muito obrigado [BR] • VIDA DE JOVEM • ~ ROLEPLAY ~ [ CORPS, VOICE, GANGS, VIPS ] VENHA CONHECER NOSSO SERVIDOR ~ R O L E P L A Y ~ SERVIDOR NOVO BEM CONFIGURADO COMPACTADO LEVE COM UM BOM PING Obs: Depende da Sua NET! Staff Sempre Online Vagas Abertas Para todos tipo de trabalhos CORPS, GANGS, SAMU, MECANICOS e Muitos Outros Trabalhos Vale a pena Visita passe seus 10Minutos Aqui e venha conhecer a verdadeira diversão de um R O L E P L A Y ID: mtasa://54.39.244.81:22853 DISCORD: discord.gg/jEyd4J3 PAGINA: https://www.facebook.com/VidaDeJovemBR/ WhatsApp: 71 987647252
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