Jump to content

Captain Cody

Members
  • Posts

    2,753
  • Joined

  • Last visited

  • Days Won

    18

Posts posted by Captain Cody

  1. If you look on my GitHub I have some tools laid out to convert form 3ds max to MTA using MTA-Stream. Unfortunately I haven't really don't anything with MTA in a while and I no longer develop content with it so I can not really give you a precise guide to converting.

     

  2. Hi, @LuanSantos_ if you go to my GitHub I have a converter posted with the information. Personally I'm not a fan of scene to res as it uses a streaming system which produces very low performance results.

    https://github.com/Wolfee-J/MTA-Map-Convertor

     

    • Download MTA-Map-Converator
    • Extract the folder 'MTA-Convertor' into your MTA resources
    • Extract map resources (TXD,COL,DFF) into the 'MTA-Convertor/Resources' folder
    • Extract map files (IPL/IDE/ECT) into the root MTA-Convertor folder
  3.  text1 = dxDrawText ( "Click to copy", 700, 828, 150,"Click to copy" )
    
    function setClipboardF (texts) 
        setClipboard(texts)
    end
    addEventHandler("onClientGUIClick", tex1, setClipboardF, false)

     

  4. Sorry for a bit of a late response, haven't been reading forums much lately.

     

    https://wiki.multitheftauto.com/wiki/OnClientVehicleDamage

    https://wiki.multitheftauto.com/wiki/GetVehiclePanelState

    https://wiki.multitheftauto.com/wiki/SetVehiclePanelState

    When you active the function loop through the panels and save their states. On vehicle damage loop through and restore their states to what has been saved.

     

    damageTable = {}
    
    function setVehiclePanelsDamageProof(player)
       local veh = getPedOccupiedVehicle(player)
       if isElement(veh) then
          if damageTable[veh] then
             damageTable[veh] = nil
          else
             damageTable[veh] = {}
             for i = 0,6 do
                local state = getVehiclePanelState(veh,i)
                damageTable[veh][i] = state
             end
          end
       end
    end
    addCommandHandler ( "damageProof", setVehiclePanelsDamageProof ) -- # Change this to whatever you want
    
    function onVehicleDamage()
        if isElement(source) and damageTable[source] then
          for i = 0,6 do
             setVehiclePanelState(source,i,damageTable[source][i])
          end
       end
    end
    
    addEventHandler("onVehicleDamage", root, onVehicleDamage)

    Basic script, should work (Untested) . You'll have to modify it to your needs though.

     

    When you use the command "damageProof" it loops through the vehicles panels and saves their states (Or if table exists nils it) which enables or disables it. If a table exists (It's enabled) onVehicleDamage it loops through and resets the vehicles panel states. If disabled then it'll ignore it.

    • Like 1
  5. Firstly, MTA does not have it's own streamer; there is physically no difference between how SA handles elements and how MTA handles elements. However, separate LOD models are broken in MTA, luckly they are not really required as a typical SA object is lower poly then a far - lod element from modern games thus performance in't really hit much on decent computers (Even sub decent) unless you're going for custom maps.

     

    For important objects (AND ONLY IMPORTANT OBJECTS) create the object again with a lod boolen set to true. After that use https://wiki.multitheftauto.com/wiki/SetLowLODElement

    to assign it. And set the LOD distance to between 170 and 300 depending on how big the object is. https://wiki.multitheftauto.com/wiki/EngineSetModelLODDistance

     

    Typically I'd recommend people use my streamer, but apparently it's the worlds most difficult thing to figure out (Other then my girl friend) and the above does the job just as well for smaller maps. For bigger maps though  https://github.com/CodyJL/JStreamer

    The github readme explains it.

  6. Looking back at this my grammar there sucks, and no. What I was thinking at the time (Which is completely different from what I wrote) was setting players to the dimension of the current player client side, this however would cause de-syncs. So either way it's wrong.

×
×
  • Create New...