Jump to content

Captain Cody

Members
  • Posts

    2,753
  • Joined

  • Last visited

  • Days Won

    18

Everything posted by Captain Cody

  1. Table = {} Table["Value"] = value
  2. Yes you can create a table client side, it's a shared function.
  3. function loadScoreboardData () data.ids = nil data.players = nil data.ids = {} data.players = {} local players = getElementsByType ("player") for k,v in ipairs(players) do if v ~= getLocalPlayer() then local ID = getElementData (v,"id") table.insert(data.players,ID) data.ids[ID] = v end end table.sort (data.players) local ID = getElementData(getLocalPlayer(),"playerid") data.ids[ID] = getLocalPlayer() table.insert(data.players,1,ID) data.length = #data.players --data.slots = maxP --data.serverName = sName data.maxHeight = 800 if sy-200 <= data.maxHeight then data.maxHeight = sy-200 end end Replace first part with this, clears the table. Originally it just added onto the already existent table thus, doubling the values.
  4. triggerServerEvent ( "closeAllDoor", root) or if its from the same resource triggerServerEvent ( "closeAllDoor", resourceRoot) And function closeAllDoor() local vehicle = getPedOccupiedVehicle (client) if vehicle then for i=0,5 do setVehicleDoorOpenRatio ( vehicle, i, 0) end end end addEvent("closeAllDoor", true) addEventHandler( "closeAllDoor", getRootElement(), closeAllDoor )
  5. dxDrawImage is indeed clientSide. If you were asking. But now realizing what you may have been asking you wanna send the response data client side, and define it client side.
  6. Any way to make a shader come out the color you want when applying over a dark colored object? Due to the darkness of the object, the shader is just staying black instead of changing to the color I'm trying to set it to.
  7. There's other ways of doing it then, I'll take a look at the possible handling fields in a bit, and report back with info I gather.
  8. I'll take a look at it in a bit.
  9. Well I what I meant was assigning it separate from the setText, then combing it in.
  10. Is client.lua the code that you posted? if so there's no apparent errors at line 29, or did you not copy it correctly?
  11. Maybe temperately freezing the rhino when it explodes as to prevent the jump.
  12. local localPlayer = getLocalPlayer() function stop_turret_rotation() local veh = getPedOccupiedVehicle(localPlayer) local id = getElementModel ( veh ) if id == 432 or id == 601 then setVehicleTurretPosition(veh, x1, y1) end end function event() addEventHandler("onClientRender", root, stop_turret_rotation) x1, y1 = getVehicleTurretPosition ( getPedOccupiedVehicle(localPlayer) ) end addCommandHandler("lockturrent", event) function event2 () removeEventHandler("onClientRender", root, stop_turret_rotation) end addCommandHandler("unlockturrent", event2)
  13. You realize all that code does is set the turrent positon to the current position? -- Try thus -- local localPlayer = getLocalPlayer() function stop_turret_rotation() local veh = getPedOccupiedVehicle(localPlayer) local id = getElementModel ( veh ) if id == 432 or id == 601 then local x, y = getVehicleTurretPosition(veh) if x and y then setVehicleTurretPosition(veh, 0, 0) -- Forward Look end end end function event() addEventHandler("onClientRender", root, stop_turret_rotation) end addCommandHandler("event", event)
  14. Try defining (v.'Whatever') as another variable first then setting it rtext = v.Whatever And have you tried out putting it server side, or client side?
  15. Well I know you can do it by modifying the dff file. But I'm asking if theres a way to just do it with shaders. Trying to keep download as low as possible.
  16. The vehicleID variable is not being sent over correctly.
  17. From what I'm getting out of this: He wants to use the regular rhino shooting sound, then 7 seconds after he wants to play the (Reload.mp3) Fire(Rhino Sound) -> 7s Reload(Reload.mp3)
  18. There is something wrong with your "Hill_Exit" function, it's not finding it.
  19. [2016-03-17 17:55:01] [Network] OutCommandQueue > 600000 msgs. This is due to server overload or script freeze [2016-03-17 17:55:01] Temporarily suspending outgoing sync packets [2016-03-17 17:56:47] Resuming outgoing sync packets OutCommandQueue is over 6 thousand, may be your issue there.
  20. Not sure you understand what I mean. I'm asking if there is a way to use shaders to add changable secondary colors to vehicles
  21. Clear your debug with /cleardebugscript, then launch the script and post the whole debug here.
  22. If you're trying to decrease the acceleration you wanna decrease the Acceleration setting and the vehicles drag, to allow it to actually reach the top speed you want.
  23. Not sure, but if you see any major errors just post them here.
×
×
  • Create New...