Groll_Bixmes Posted October 11, 2014 Share Posted October 11, 2014 i need some help about custom objects,i dont know how to add it,i saw servers with cool customized objects,i wanted those,i already create the TXD and the DFF,it will be really helpful if you can help me,anyway,im using mta 1.4 Link to comment
spoty Posted October 11, 2014 Share Posted October 11, 2014 this is the client.lua change object name to your file name from .txd .dff .col change item id to the item id you wanne replace with it function map() txd = engineLoadTXD ( "object name.txd" ) engineImportTXD ( txd, Item ID ) col = engineLoadCOL ( "object name.col" ) dff = engineLoadDFF ( "object name.dff", 0 ) engineReplaceCOL ( col, Item ID ) engineReplaceModel ( dff, Item ID ) engineSetModelLODDistance(Item ID, 2000) end setTimer ( map, 2000, 1) addCommandHandler("reloadmap",map) addEventHandler("onClientResourceStop", getResourceRootElement(getThisResource()), function() engineRestoreCOL(Item ID) engineRestoreModel(Item ID) destroyElement(dff) destroyElement(col) destroyElement(txd) end ) this is the .map "race,editor_main"> "object (cen_bit_19) (1)" interior="0" collisions="true" alpha="255" doublesided="true" model="Item ID" scale="1" dimension="0" posX="0.00" posY="0.00" posZ="0.00" rotX="0.00" rotY="0.00" rotZ="0.00"> Link to comment
Groll_Bixmes Posted October 12, 2014 Author Share Posted October 12, 2014 this is the client.lua change object name to your file name from .txd .dff .col change item id to the item id you wanne replace with it function map() txd = engineLoadTXD ( "object name.txd" ) engineImportTXD ( txd, Item ID ) col = engineLoadCOL ( "object name.col" ) dff = engineLoadDFF ( "object name.dff", 0 ) engineReplaceCOL ( col, Item ID ) engineReplaceModel ( dff, Item ID ) engineSetModelLODDistance(Item ID, 2000) end setTimer ( map, 2000, 1) addCommandHandler("reloadmap",map) addEventHandler("onClientResourceStop", getResourceRootElement(getThisResource()), function() engineRestoreCOL(Item ID) engineRestoreModel(Item ID) destroyElement(dff) destroyElement(col) destroyElement(txd) end ) this is the .map "race,editor_main"> "object (cen_bit_19) (1)" interior="0" collisions="true" alpha="255" doublesided="true" model="Item ID" scale="1" dimension="0" posX="0.00" posY="0.00" posZ="0.00" rotX="0.00" rotY="0.00" rotZ="0.00"> im new to mta,can you please give me some more detailed instruction,and i cant find the .col for the object,i thought i only need dff and txd,can you help me to find the .col for the object?and where to put the script please? Link to comment
spoty Posted October 12, 2014 Share Posted October 12, 2014 dff = object ----- is the model txd = textures ------ gives texture to the model col = collison ------- makes je allow to walk / drive on object if you dont have the .col file you need to make one idk how you need to make a folder and put there the objects and lua client script and .map file and make a meta.xml that loads the scripts map and files Link to comment
Groll_Bixmes Posted October 13, 2014 Author Share Posted October 13, 2014 dff = object ----- is the modeltxd = textures ------ gives texture to the model col = collison ------- makes je allow to walk / drive on object if you dont have the .col file you need to make one idk how you need to make a folder and put there the objects and lua client script and .map file and make a meta.xml that loads the scripts map and files i got the .col file,but i still didnt understood to apply the custom object,can you please tell me how to apply it step by step?like this 1.[what should i do] 2.[what sould i do] 3.what should i do] Link to comment
spoty Posted October 13, 2014 Share Posted October 13, 2014 1. make a folder in your resource how ever you want to call it 2. put there your .txd .dff .col in 3. copy the scripts 4. edit the scripts [object name = how your txd dff col are called] [ item id = the object id you wanne replace with it] if you wanne also have a maded meta.xml ask it this is the client.lua change object name to your file name from .txd .dff .col change item id to the item id you wanne replace with it function map() txd = engineLoadTXD ( "object name.txd" ) engineImportTXD ( txd, Item ID ) col = engineLoadCOL ( "object name.col" ) dff = engineLoadDFF ( "object name.dff", 0 ) engineReplaceCOL ( col, Item ID ) engineReplaceModel ( dff, Item ID ) engineSetModelLODDistance(Item ID, 2000) end setTimer ( map, 2000, 1) addCommandHandler("reloadmap",map) addEventHandler("onClientResourceStop", getResourceRootElement(getThisResource()), function() engineRestoreCOL(Item ID) engineRestoreModel(Item ID) destroyElement(dff) destroyElement(col) destroyElement(txd) end ) this is the .map "race,editor_main"> "object (cen_bit_19) (1)" interior="0" collisions="true" alpha="255" doublesided="true" model="Item ID" scale="1" dimension="0" posX="0.00" posY="0.00" posZ="0.00" rotX="0.00" rotY="0.00" rotZ="0.00"> im new to mta,can you please give me some more detailed instruction,and i cant find the .col for the object,i thought i only need dff and txd,can you help me to find the .col for the object?and where to put the script please? Link to comment
Groll_Bixmes Posted October 14, 2014 Author Share Posted October 14, 2014 where do i paste them? Link to comment
Groll_Bixmes Posted October 14, 2014 Author Share Posted October 14, 2014 where you do paste what? where do i paste the script? Link to comment
spoty Posted October 15, 2014 Share Posted October 15, 2014 make a folder called how you want put the client.lua meta.xml gta.map in the folder put your objects also in the folder edit the script and test it Link to comment
Groll_Bixmes Posted October 16, 2014 Author Share Posted October 16, 2014 where to get client.lua meta.xml gta.map ? Link to comment
spoty Posted October 16, 2014 Share Posted October 16, 2014 this is the client.lua change object name to your file name from .txd .dff .col change item id to the item id you wanne replace with it function map() -------------------client.lua txd = engineLoadTXD ( "object name.txd" ) engineImportTXD ( txd, Item ID ) col = engineLoadCOL ( "object name.col" ) dff = engineLoadDFF ( "object name.dff", 0 ) engineReplaceCOL ( col, Item ID ) engineReplaceModel ( dff, Item ID ) engineSetModelLODDistance(Item ID, 2000) end setTimer ( map, 2000, 1) addCommandHandler("reloadmap",map) addEventHandler("onClientResourceStop", getResourceRootElement(getThisResource()), function() engineRestoreCOL(Item ID) engineRestoreModel(Item ID) destroyElement(dff) destroyElement(col) destroyElement(txd) end ) this is the .map "race,editor_main"> --------------------- gta.map "object (cen_bit_19) (1)" interior="0" collisions="true" alpha="255" doublesided="true" model="Item ID" scale="1" dimension="0" posX="0.00" posY="0.00" posZ="0.00" rotX="0.00" rotY="0.00" rotZ="0.00"> Link to comment
Groll_Bixmes Posted October 16, 2014 Author Share Posted October 16, 2014 Do i have to create a new file? Link to comment
Tails Posted October 17, 2014 Share Posted October 17, 2014 Do i have to create a new file? Yes, you have to create a new text file for each of them and save them accordingly. If you're just getting started, I highly recommend you to check out the official MTA Wiki. It will explain you how to set up a new resource and how .xml files work. https://wiki.multitheftauto.com/wiki/Sc ... troduction https://wiki.multitheftauto.com/wiki/Main_Page Link to comment
Groll_Bixmes Posted October 18, 2014 Author Share Posted October 18, 2014 Do i have to create a new file? Yes, you have to create a new text file for each of them and save them accordingly. If you're just getting started, I highly recommend you to check out the official MTA Wiki. It will explain you how to set up a new resource and how .xml files work. https://wiki.multitheftauto.com/wiki/Sc ... troduction https://wiki.multitheftauto.com/wiki/Main_Page what is the name for the .map file? gta.map ?and should i replace some of the contents of the .map file? and im intrested of beeing a mapper Link to comment
Tails Posted October 18, 2014 Share Posted October 18, 2014 It can be any name you want. If you're interested in mapping then you I suggest you try the official map editor. Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now