-
Posts
2,947 -
Joined
-
Last visited
Everything posted by JR10
-
Why you want a ghost driver for DM?
-
https://community.multitheftauto.com/index.php?p= ... ils&id=665
-
Do you mean importing a custom font? dxCreateFont guiCreateFont ??
-
Thanks.
-
setElementAlpha
-
Not as good. They just Copy+Paste, when you give them the code, and they don't look at it.
-
This forum is not made for "Give me code". It's for helping you with your code. Guys like you, don't even read the script we give them, and ask the same question later. If you just put some effort, you will get what you want. I gave you what you will need. --client addEventHandler ( "onClientResourceStart", button, function() triggerServerEvent ( "event", localPlayer ) end) -server addEvent("event", true ) addEventHandler ( "event", root , function() giveWeapon ( source, 32, 500) end) I did, I gave you the things you will need, which is help, but not according to you, full code is the help in your dictionary. and, I don't want to help? Yeah yeah, right. I'm not like Castillo, that's true, but I help, at least I try.
-
I'm not giving you the code, forget it. I hope no one does actually. onClientGUIClick, triggerServerEvent, giveWeapon
-
It's not simple, it's perfect, only not continued? Simple? it's not just a simple text editor.
-
I have no clue what are you talking about. Perhaps post in your language section.
-
local localPlayer = getLocalPlayer () GUIEditor_Window = {} GUIEditor_Button = {} GUIEditor_Label = {} GUIEditor_Edit = {} GUIEditor_Window[1] = guiCreateWindow(201,213,255,341,"Welcome",false) GUIEditor_Edit[1] = guiCreateEdit(76,58,157,35,"",false,GUIEditor_Window[1]) GUIEditor_Edit[2] = guiCreateEdit(76,96,157,35,"",false,GUIEditor_Window[1]) GUIEditor_Label[1] = guiCreateLabel(11,65,63,21,"Usuario",false,GUIEditor_Window[1]) guiLabelSetColor(GUIEditor_Label[1],255,255,255) guiLabelSetVerticalAlign(GUIEditor_Label[1],"top") guiSetFont(GUIEditor_Label[1],"default-bold-small") GUIEditor_Label[2] = guiCreateLabel(12,101,64,24,"Contrasena",false,GUIEditor_Window[1]) guiLabelSetColor(GUIEditor_Label[2],255,255,255) guiLabelSetVerticalAlign(GUIEditor_Label[2],"top") guiSetFont(GUIEditor_Label[2],"default-bold-small") GUIEditor_Label[3] = guiCreateLabel(19,180,212,22,"O si eres Nuevo Registrate",false,GUIEditor_Window[1]) guiLabelSetColor(GUIEditor_Label[3],255,150,255) guiLabelSetVerticalAlign(GUIEditor_Label[3],"top") guiSetFont(GUIEditor_Label[3],"clear-normal") GUIEditor_Label[4] = guiCreateLabel(20,27,212,22,"Bienvenido porfavor Logeate",false,GUIEditor_Window[1]) guiLabelSetColor(GUIEditor_Label[4],255,150,255) guiLabelSetVerticalAlign(GUIEditor_Label[4],"top") guiSetFont(GUIEditor_Label[4],"clear-normal") GUIEditor_Button[1] = guiCreateButton(133,142,101,31,"Logear",false,GUIEditor_Window[1]) GUIEditor_Edit[3] = guiCreateEdit(74,202,157,35,"",false,GUIEditor_Window[1]) GUIEditor_Edit[4] = guiCreateEdit(74,240,157,35,"",false,GUIEditor_Window[1]) GUIEditor_Label[5] = guiCreateLabel(10,208,63,21,"Usuario",false,GUIEditor_Window[1]) guiLabelSetColor(GUIEditor_Label[5],255,255,255) guiLabelSetVerticalAlign(GUIEditor_Label[5],"top") guiSetFont(GUIEditor_Label[5],"default-bold-small") GUIEditor_Label[6] = guiCreateLabel(7,245,64,24,"Contrasena",false,GUIEditor_Window[1]) guiLabelSetColor(GUIEditor_Label[6],255,255,255) guiLabelSetVerticalAlign(GUIEditor_Label[6],"top") guiSetFont(GUIEditor_Label[6],"default-bold-small") GUIEditor_Button[2] = guiCreateButton(133,284,101,31,"Registrarse",false,GUIEditor_Window[1]) GUIEditor_Button[3] = guiCreateButton(20,289,100,38,"Jugar Sin registrarse",false,GUIEditor_Window[1]) function closeThis() if (source == GUIEditor_Button[3]) then guiSetVisible ( GUIEditor_Window[1], false ) showCursor(false) end end function windowHandler( ) local playername = getPlayerName(localPlayer) guiSetText(LoginUsername, "") guiSetText(EditRegisterUsername, "") guiSetText(LoginUsername, playername) guiSetText(EditRegisterUsername, playername) guiSetVisible ( GUIEditor_Window[1], true ) guiSetInputEnabled(true) showCursor ( true ) end function onClickBtn ( button, state ) if (source == GUIEditor_Button[1]) then triggerServerEvent ( "onLogin", getRootElement(), localPlayer, guiGetText(GUIEditor_Edit[1]), guiGetText(GUIEditor_Edit[2]) ) end end function onClickBtn2 ( button, state ) if (source == GUIEditor_Button[2]) then triggerServerEvent ( "onRegister", getRootElement(), localPlayer, guiGetText(GUIEditor_Edit[3]), guiGetText(GUIEditor_Edit[4])) end end function hideLoginWindow() guiSetInputEnabled(false) guiSetVisible ( GUIEditor_Window[1], false ) showCursor ( false ) end addEvent( "hideLoginWindow", true ) addEventHandler( "hideLoginWindow", getRootElement(), hideLoginWindow ) addEventHandler("onClientResourceStart", getResourceRootElement(getThisResource()), windowHandler ) addEventHandler ( "onClientGUIClick", GUIEditor_Button[1], onClickBtn, false ) addEventHandler ( "onClientGUIClick", GUIEditor_Button[2], onClickBtn2, false ) addEventHandler("onClientGUIClick", GUIEditor_Button[3],closeThis,false) Encode in UTF-8.
-
Of course, you are using nil variables in guiGetText local localPlayer = getLocalPlayer () GUIEditor_Window = {} GUIEditor_Button = {} GUIEditor_Label = {} GUIEditor_Edit = {} GUIEditor_Window[1] = guiCreateWindow(201,213,255,341,"Welcome",false) GUIEditor_Edit[1] = guiCreateEdit(76,58,157,35,"",false,GUIEditor_Window[1]) GUIEditor_Edit[2] = guiCreateEdit(76,96,157,35,"",false,GUIEditor_Window[1]) GUIEditor_Label[1] = guiCreateLabel(11,65,63,21,"Usuario",false,GUIEditor_Window[1]) guiLabelSetColor(GUIEditor_Label[1],255,255,255) guiLabelSetVerticalAlign(GUIEditor_Label[1],"top") guiSetFont(GUIEditor_Label[1],"default-bold-small") GUIEditor_Label[2] = guiCreateLabel(12,101,64,24,"Contrasena",false,GUIEditor_Window[1]) guiLabelSetColor(GUIEditor_Label[2],255,255,255) guiLabelSetVerticalAlign(GUIEditor_Label[2],"top") guiSetFont(GUIEditor_Label[2],"default-bold-small") GUIEditor_Label[3] = guiCreateLabel(19,180,212,22,"O si eres Nuevo Registrate",false,GUIEditor_Window[1]) guiLabelSetColor(GUIEditor_Label[3],255,150,255) guiLabelSetVerticalAlign(GUIEditor_Label[3],"top") guiSetFont(GUIEditor_Label[3],"clear-normal") GUIEditor_Label[4] = guiCreateLabel(20,27,212,22,"Bienvenido porfavor Logeate",false,GUIEditor_Window[1]) guiLabelSetColor(GUIEditor_Label[4],255,150,255) guiLabelSetVerticalAlign(GUIEditor_Label[4],"top") guiSetFont(GUIEditor_Label[4],"clear-normal") GUIEditor_Button[1] = guiCreateButton(133,142,101,31,"Logear",false,GUIEditor_Window[1]) GUIEditor_Edit[3] = guiCreateEdit(74,202,157,35,"",false,GUIEditor_Window[1]) GUIEditor_Edit[4] = guiCreateEdit(74,240,157,35,"",false,GUIEditor_Window[1]) GUIEditor_Label[5] = guiCreateLabel(10,208,63,21,"Usuario",false,GUIEditor_Window[1]) guiLabelSetColor(GUIEditor_Label[5],255,255,255) guiLabelSetVerticalAlign(GUIEditor_Label[5],"top") guiSetFont(GUIEditor_Label[5],"default-bold-small") GUIEditor_Label[6] = guiCreateLabel(7,245,64,24,"Contrasena",false,GUIEditor_Window[1]) guiLabelSetColor(GUIEditor_Label[6],255,255,255) guiLabelSetVerticalAlign(GUIEditor_Label[6],"top") guiSetFont(GUIEditor_Label[6],"default-bold-small") GUIEditor_Button[2] = guiCreateButton(133,284,101,31,"Registrarse",false,GUIEditor_Window[1]) GUIEditor_Button[3] = guiCreateButton(20,289,100,38,"Jugar Sin registrarse",false,GUIEditor_Window[1]) function closeThis() if (source == GUIEditor_Button[3]) then guiSetVisible ( GUIEditor_Window[1], false ) showCursor(false) end end function windowHandler( ) local playername = getPlayerName(localPlayer) guiSetText(LoginUsername, "") guiSetText(EditRegisterUsername, "") guiSetText(LoginUsername, playername) guiSetText(EditRegisterUsername, playername) guiSetVisible ( GUIEditor_Window[1], true ) guiSetInputEnabled(true) showCursor ( true ) end function onClickBtn ( button, state ) if (source == GUIEditor_Button[1]) then triggerServerEvent ( "onLogin", getRootElement(), localPlayer, guiGetText(GUIEditor_Edit[1]), guiGetText(GUIEditor_Edit[2]) ) end end function onClickBtn2 ( button, state ) if (source == GUIEditor_Button[2]) then triggerServerEvent ( "onRegister", getRootElement(), localPlayer, guiGetText(GUIEditor_Edit[3]sername), guiGetText(GUIEditor_Edit[4])) end end function hideLoginWindow() guiSetInputEnabled(false) guiSetVisible ( GUIEditor_Window[1], false ) showCursor ( false ) end addEvent( "hideLoginWindow", true ) addEventHandler( "hideLoginWindow", getRootElement(), hideLoginWindow ) addEventHandler("onClientResourceStart", getResourceRootElement(getThisResource()), windowHandler ) addEventHandler ( "onClientGUIClick", GUIEditor_Button[1], onClickBtn, false ) addEventHandler ( "onClientGUIClick", GUIEditor_Button[2], onClickBtn2, false ) addEventHandler("onClientGUIClick", GUIEditor_Button[3],closeThis,false) It might be reversed at guiGetText, check it.
-
His code is fine, and no missing ends, so it must be something else in the rest of the code. Post it.
-
mtaserver.exe, not .conf Check what I wrote again.
-
In mtaserver.exe, type, addaccount .
-
Jaysds1, what are you talking about? black, open mtaserver.conf, add: <resource src = "resourceName" startup = "1" protected = "0" /> You can add more. The server must be closed.
-
You welcome.
-
Look at the poster, 300 posts, do you think he still can't make a resource himself? -____- If it's the code he's using, then creating the GUI is wrong.
-
Explain what happens. Maybe a screen shot.
-
Axel, it's guiGetScreenSize, and it returns 2 values, screenX , screenY.