Jump to content

Castillo

Retired Staff
  • Posts

    21,935
  • Joined

  • Last visited

  • Days Won

    6

Everything posted by Castillo

  1. Castillo

    Help - XML

    xmlNodeSetAttribute
  2. Castillo

    Help - XML

    Use the XML functions.
  3. Castillo

    Help me

    Is not possible.
  4. You don't want to show it on the chat box? that's what you mean?
  5. Here it works, I tested it.
  6. Because you can't simply take part of a game mode and expect it to work, that's part of race game mode, it won't work without it.
  7. -- client side: GUIEditor_Label = {} GUIEditor_Window = {} GUIEditor_Button = {} GUIEditor_Edit = {} GUIEditor_Label[1] = guiCreateLabel(218,558,387,41,"",false) guiLabelSetColor(GUIEditor_Label[1],255,255,255) guiLabelSetVerticalAlign(GUIEditor_Label[1],"top") guiLabelSetHorizontalAlign(GUIEditor_Label[1],"left",false) GUIEditor_Window[1] = guiCreateWindow(221,83,310,341,"",false) guiSetVisible ( GUIEditor_Window[1] , false ) GUIEditor_Edit[1] = guiCreateEdit(10,25,287,47,"",false,GUIEditor_Window[1]) GUIEditor_Button[1] = guiCreateButton(9,295,126,35,"Send Text",false,GUIEditor_Window[1]) close = guiCreateButton(173,294,126,35,"Close",false,GUIEditor_Window[1]) font = guiCreateFont("font.ttf", 12) addEvent ( "showWindow", true ) addEventHandler ( "showWindow", root, function ( ) guiSetVisible ( GUIEditor_Window[1], true ) showCursor ( true ) end ) addEventHandler ( "onClientGUIClick", root, function ( ) if ( source == GUIEditor_Button[1] ) then local text = guiGetText(GUIEditor_Edit[1]) triggerServerEvent ( "sendText", localPlayer, text ) elseif ( source == close ) then guiSetVisible ( GUIEditor_Window[1], false ) showCursor ( false ) end end ) addEvent ( "returnText", true ) addEventHandler ( "returnText", root, function ( text ) guiSetText ( GUIEditor_Label[1], " admin : "..text ) guiSetFont(GUIEditor_Label[1], font) guiLabelSetColor ( GUIEditor_Label[1], 255, 0, 0 ) end ) -- server side: addCommandHandler ( "text", function ( thePlayer ) local accName = getAccountName ( getPlayerAccount ( thePlayer ) ) -- get his account name if isObjectInACLGroup ( "user.".. accName, aclGetGroup ( "Admin" ) ) then triggerClientEvent ( thePlayer, "showWindow", thePlayer ) end end ) addEvent ( "sendText", true ) addEventHandler ( "sendText", root, function ( text ) triggerClientEvent ( "returnText", root, text ) end )
  8. Lee este tutorial para hacerte una cuenta admin: https://wiki.multitheftauto.com/wiki/ES/ ... istradores
  9. addCommandHandler setPlayerNametagShowing
  10. Que queres decir con "camuflar"? ocultarlo? o cambiarlo a algo como: "Oculto"?
  11. There's: https://wiki.multitheftauto.com/wiki/OnPlayerContact but it only triggers when you stand on it.
  12. Castillo

    Saving data

    element data will be removed when the element is destroyed, so maybe you should use: setAccountData instead.
  13. Create a new resource and a server side script: addEventHandler ( "onResourceStart", resourceRoot, function ( ) exports [ "scoreboard" ]:scoreboardAddColumn ( "med_kit", 100, "Medic kit" ) for _, thePlayer in ipairs ( getElementsByType ( "player" ) ) do setElementData ( thePlayer, 'med_kit', 'No' ) end end )
  14. You don't need to do that, you can use it with the exported function, also, your data name is "med_kit".
  15. How could I know? I'm not a guesser, I don't know how your script looks/works like.
  16. Castillo

    [HELP]Save

    Are you sure that you closed it with Ctrl + C?
  17. setElementData ( localPlayer, "YourDataNameHere", "Hello World!" )
  18. Castillo

    Happy New Year!

    Santa claus told me.
  19. Castillo

    [HELP]Save

    Try closing it like I said.
  20. Castillo

    [HELP]Save

    Did you close the server with "Cntrl + C"?
×
×
  • Create New...