Jump to content

ViRuZGamiing

Members
  • Posts

    1,050
  • Joined

  • Last visited

Everything posted by ViRuZGamiing

  1. https://wiki.multitheftauto.com/wiki/Projectiles 58 Flare from hydra (doesn't work)
  2. executeBrowserJavascript Examples; https://github.com/Jusonex/mtasa_cef_tools/blob/master/webui/src/WebWindow.lua#L180-189 https://github.com/Jusonex/mtasa_cef_tools/blob/master/webui/src/mtaevents.js#L9-L15
  3. my bad, didn't read the question properly
  4. function setWantedLevel(player, wanted) if (getPlayerWantedLevel(player) > wanted) then setPlayerWantedLevel(player, wanted) end end This will increased the current wanted level, I think the deal is that you wouldn't want the wanted level to lower when set lower but be higher when set higher
  5. setVehicleDoorState setVehicleWheelStates setVehicleLightState Is the only thing I know. Not sure if you can change the damage model
  6. For interactive browser look at guiCreateBrowser instead of createBrowser
  7. Just thinking logically wouldn't it be better to destroy and create it client sided?
  8. createVehicle is a predefined function "Stack overflow" means that this function has been calling itself without actually finishing execution of the first call. It's like infinite loop.
  9. I think this has to do with text going outside your label container. Try wordwrapping it. guiLabelSetHorizontalAlign
  10. oh yeah source is the marker, my bad
  11. triggerServerEvent ( "takeJob", source) You trigger the event for root
  12. setTimer requires a function and setElementData has no parameters. setTimer(function(thePlayer) setElementData(thePlayer, "isPlayerMuted", false) end, 1000, 1, thePlayer)
  13. WARNING: Bad Argument @ Forum Post [Expected script got Nil] 'Cant debug without the code' but you haven't specified a SQL Connection
  14. It does work when you change the StreamMethod to 2 in the Meta.xml in <settings>
  15. <data name="position" type="coord3d" default="1900,200,18" /> I suppose
  16. if ( player and isElement ( player ) and getElementType ( player ) == "player" and not isPedInVehicle ( player ) and getTeamName(getPlayerTeam(player)) == "Criminals" ) then
  17. I suppose this would be enough: function isSerialBanned(s) serial = exports.NGSQL:db_exec("SELECT * FROM bans WHERE srl=?", s) if serial then return true end return false end
  18. Your code is shorter indeed but the difference is, Analogue example: You're in a store and want 10 things, you: For each question do Look for a worker and ask where you Can find 1 thing. While you could ask all 10 items in 1 time. It's a performance difference
  19. What I'd do then is create a col and attach it to the car. Rotate as the car rotates.
  20. So if I understand right, and you understand my drawing skill of paint The red is what you can get from the function but you also want to get the blue value to get the purple box in total
  21. oh yeah my bad didn't notice. I see what you mean. local x, y = guiGetScreenSize() --can be at the top since your screensize won't change during runtime local message = false local r, g, b function notification() dxDrawRectangle(x/2-800/2, 0, 800, 50, tocolor(0, 0, 0, 220), false, false) dxDrawText(message, 0, 15, x, y, tocolor(r, g, b, 220), 1, "default", "center", "top", false, false, true) end function sendClientMessage(message, r, g, b, colorCode) message = tostring(message) if not message then return end r,g ,b = tonumber(r), tonumber(g), tonumber(b) if not colorCode then colorCode = false else colorCode = true r,g,b = getColorFromString(message) end addEventHandler("onClientRender", root, notification) setTimer(function() removeEventHandler("onClientRender", root, notification) message = false end, 5000, 1) end addEvent("sendClientMessage", true) addEventHandler("sendClientMessage", root, sendClientMessage) Try this
  22. db_query? don't you mean dbQuery? https://wiki.multitheftauto.com/wiki/DbQuery
  23. Can you copy the error cause I don't really understand your error? I suppose expect string but got nil value?
  24. You're doing the same thing as before tho, onClientRender is every frame so dxDrawBday is called again and again so will setTimer be as well. Don't put the setTimer inside the render you're creating multiple timers this could be the lagg problem
×
×
  • Create New...