Jump to content

Vinctus

Members
  • Posts

    43
  • Joined

  • Last visited

Everything posted by Vinctus

  1. https://wiki.multitheftauto.com/wiki/Scr ... troduction
  2. make the type as "server" on first one, try after that <meta> <script src="countdownC.lua" type="client" /> <script src="countdownS.lua" type="server" /> <file src="images/1.png" /> <file src="images/2.png" /> <file src="images/3.png" /> <file src="images/go.png" /> <file src="go.mp3" /> <file src="tick.mp3" /> <export function="startCountDown" type="server" /> <export function="startCountDown" type="client" /> </meta> what is the clientside for anyway?
  3. setElementFrozen(theguy, false)
  4. replace isWindowOpen with isElement
  5. attach element data on the player once he done X thing then check if he has elem data when he opens the gui, if he has, disable the button or if you want to use accountData, make the check via server side event
  6. regarding the oxygen problem, make the text show math.ceil(current oxygen / 100) other than that, looks pretty nice - loving the GRO theme
  7. https://forum.multitheftauto.com/viewtopic.php?f=91&t=39795
  8. onPlayerWasted call playerSpawn func for the guy who died lol also think u need to getTeamFromName() to get the team element
  9. Vinctus

    Infernus skin

    local myMods = { -- file name, replaces {"filename",411}, } addEventHandler("onClientResourceStart", resourceRoot, function() for _,theMod in ipairs(myMods) do local file = theMod[1] local id = theMod[2] local txd = engineLoadTXD (file .. ".txd" ) engineImportTXD ( txd, id ) local dff = engineLoadDFF (file .. ".dff", id ) engineReplaceModel ( dff, id ) end end) if you are going to have multiple mods, use this.. easier than the engineLoad stuff 500 times.
  10. Reading the wiki doesn't make you any better scripter, you has to understand what you are doing as well
  11. Vinctus

    Save System

    also I recommend using SQL for the stats instead of account data, easier to clear it all if needed by dropping the table etc
  12. wiki.multitheftauto.com/wiki/Scripting_Introduction
  13. Vinctus

    mechanic

    make sure to check it's not empty vehicle (that there is someone driving) or players can abuse it by shooting at their vehicle and then repairing it
  14. create the vehicle to another dimension and set player's camera to it then, if he cancels the spawning or spawns the vehicle, destroy the preview one, set players camera back to the player and spawn the vehicle.
  15. Vinctus

    [Help]

    "ERROR: Couldn't find file skins/13.txd" you are missing a .txd file or you don't have it on the correct folder -- it must be in zombies/skins folder.
  16. If it's for like test-driving, send the player to another dimension and spawn the car there. That would be in my opinion the easiest way, although you can do what the guy above me said
  17. Also, always color vehicles server-sided - coloring it clientside will only show the color to you. However, sometimes coloring clientside is a good thing - like preview of modshop vehicle colors for example.
  18. cancelling the onVehicleStartEnter is more efficient as it blocks it as soon as you press the key to enter the vehicle
  19. Why would you want that?
  20. Vinctus

    Login

    so you have a login panel that isn't GUI or dxDraw? What is it then?
  21. here's an example: addEventHandler("onVehicleStartEnter", root, function(enteringPlayer, seat) if enteringPlayer and seat == 0 then -- if he tries to enter driver seat if not getElementData(enteringPlayer, "police") then cancelEvent() end end end) or whatever you use to check if he is police
  22. Vinctus

    Problem

    don't you have on extra 'end' at the end of the script?
  23. http://lua-users.org/wiki/StringLibraryTutorial try here
×
×
  • Create New...