Jump to content

Castillo

Retired Staff
  • Posts

    21,935
  • Joined

  • Last visited

  • Days Won

    6

Everything posted by Castillo

  1. You can't execute server-side commands from the client side.
  2. You must check if the hit element is a player element. if ( getElementType ( hitElement ) == "player" ) then
  3. addEvent('startdraw',true) addEvent('stopdraw',true) local screenx,screeny = guiGetScreenSize() GUIEditor = { button = {}, window = {}, label = {} } addEventHandler("onClientResourceStart", resourceRoot, function() GUIEditor.window[1] = guiCreateWindow(222, 217, 378, 192, "get bike", false) guiWindowSetSizable(GUIEditor.window[1], false) guiSetProperty(GUIEditor.window[1], "CaptionColour", "FFFA1818") GUIEditor.button[1] = guiCreateButton(57, 88, 109, 57, "GET NRG", false, GUIEditor.window[1]) GUIEditor.button[2] = guiCreateButton(224, 93, 126, 52, "GET FCR", false, GUIEditor.window[1]) GUIEditor.label[1] = guiCreateLabel(87, 4, 206, 15, "", false, GUIEditor.window[1]) end ) bindKey ( "F2", "down", function ( ) local state = ( not guiGetVisible ( GUIEditor.window[1] ) ) guiSetVisible ( GUIEditor.window[1], state ) showCursor ( state ) end )
  4. That's because you are trying to obtain the "log" column data, but you are only selecting "PlayerName" in your query.
  5. Castillo

    script

    What do you mean?
  6. You can use the function executeCommandHandler Use onClientGUIClick to link the button to a function.
  7. Account data y element data son dos cosas diferentes.
  8. Yo diria que el problema es que "zombiekills" es un boolean, muy probablemente "nil", lo que quiere decir es que no tiene ningun dato guardado.
  9. How'd you check what it's returning? post it.
  10. Y el error cual es? Agregaste el recurso al ACL.xml, grupo "Admin"?
  11. Debug it, see what "sValue" returns.
  12. Castillo

    Size

    You're welcome.
  13. Castillo

    Size

    What do you mean by "crashed"? I only changed 0.4 scale to 0.7. Check the debugscript ( /debugscript 3 in-game ) and see if there are errors.
  14. Castillo

    Size

    dxDrawText("FPS: "..getElementData(getLocalPlayer(), "FPS"), (8/1024)*sWidth, (740/768)*sHeight, (130/1024)*sWidth, (130/768)*sHeight, tocolor (255, 255, 255, 255), (0.4/1366)*sWidth,(0.7/768)*sHeight,"bankgothic","left","top",false,false,false,false)
  15. Well, you shouldn't start editing a script if you don't know how it works. You could execute "aReport" function when the resource starts, but make sure to hide the window after it's created.
  16. I don't think you can actually modify that. P.S: Why would you execute the same code every 5 seconds, infinite times?
  17. Do you have any work to show? like released resources, and that stuff. P.S: Your signature has a typo.
  18. That's because "aReportForm" doesn't exist, because "aReport" function was never executed.
  19. @ImTitanium: You could attach the vehicle to an invisible object, and then move the object using moveObject.
  20. local myTable = { } -- Define the table myTable [ thePlayer ] = { } -- Use the player userdata as index Insert: table.insert ( myTable [ thePlayer ], { "Hello", "World" } )
  21. Castillo

    Duel [help]

    There's no such function "getPlayerFromId".
  22. You are never updating the "open" variable, which means it'll always be 'false'.
  23. toggleControl is for players, not vehicles.
  24. Castillo

    error in console

    Have you, by any chance put something in the IP field at the mtaserver.conf?
×
×
  • Create New...