xXBaddaBingXx Posted January 17, 2011 Share Posted January 17, 2011 Hey, I just wanted to ask and stuff I already know how to add like the custom models to the script but I don't know where to put the models at like the custom models? If you could also try to explain to me how to add like custom handling and stuff I'm just trying to start a server with a few friends and have some fun with modding and playing online lol. Thanks for your kind help it be so much appreciated. Link to comment
proracer Posted January 17, 2011 Share Posted January 17, 2011 Custom handling will be integrated in new version of MTA; MTA 1.1 Link to comment
xXBaddaBingXx Posted January 17, 2011 Author Share Posted January 17, 2011 Ok, thanks where do the put my custom dffs and txd for the car models to be loaded? Link to comment
DiSaMe Posted January 17, 2011 Share Posted January 17, 2011 In the place which you specified in meta.xml, relative to the resource directory. Link to comment
proracer Posted January 17, 2011 Share Posted January 17, 2011 Here is an example code: function ClientStarted() txd = engineLoadTXD ("infernus.txd") engineImportTXD (txd, 411) dff = engineLoadDFF ("infernus.dff") engineReplaceModel (dff, 411) end addEventHandler( "onClientResourceStart", getResourceRootElement(getThisResource()), ClientStarted ) Meta file for simplish: <meta> <script src="client.lua" type="client" /> <file src="infernus.txd" /> <file src="infernus.dff" /> </meta> Make sure you have script and the 1 (or 2 files if you include custom dff) in the resource folder. Link to comment
xXBaddaBingXx Posted January 17, 2011 Author Share Posted January 17, 2011 I put two custom Infernus files into the freeroam folder located under server > mods > deathmatch > resources-cache > unzipped > freeroam > infernus.dff, and infernus.txd. Did i do the following correctly? I put in the fr_client.lua and click saved I didn't go to compile. addEventHandler('onClientResourceStart', getResourceRootElement(getThisResource()), ClientStarted ) function() fadeCamera(true) setTimer(getPlayers, 1000, 1) txd = engineLoadTXD ("infernus.txd") engineImportTXD (txd, 411) dff = engineLoadDFF ("infernus.dff") engineReplaceModel (dff, 411) bindKey('f1', 'down', toggleFRWindow) createWindow(wndMain) hideAllWindows() guiCheckBoxSetSelected(getControl(wndMain, 'jetpack'), doesPedHaveJetPack(g_Me)) guiCheckBoxSetSelected(getControl(wndMain, 'falloff'), canPedBeKnockedOffBike(g_Me)) setJetpackMaxHeight ( 9001 ) triggerServerEvent('onLoadedAtClient', g_ResRoot, g_Me) end ) For the meta.xml just a snippet of it: <info name="Freeroam GUI" author="arc_" version="1.3.4" /> <script src="util_server.lua" type="server" /> <script src="fr_server.lua" type="server" /> <script src="util.lua" type="client" /> <script src="gui.lua" type="client" /> <script src="fr_client.lua" type="client" /> <export function="appendControl" type="client" /> <file src="colorselect.png" /> <file src="localplayerblip.png" /> <file src="map.png" /> <file src="playerblip.png" /> <file src="vehiclecolors.png" /> <file src="infernus.txd" /> <file src="infernus.dff" /> Link to comment
proracer Posted January 17, 2011 Share Posted January 17, 2011 No no... Put it here: server > mods > deathmatch > resources > (your resource name) - and in that folder is your script,meta file and dff and / or txd model Link to comment
xXBaddaBingXx Posted January 17, 2011 Author Share Posted January 17, 2011 I done the following, now I'm just having a issue with the car not showing up any suggestions ? I copied the freeroam the one that came with the MTA install and I put the lines in the meta.xml and then I put the lines of the TXD and DFF under the OnClientResourceStarted like this: addEventHandler('onClientResourceStart', g_ResRoot,getResourceRootElement(getThisResource()), ClientStarted ) function() fadeCamera(true) setTimer(getPlayers, 1000, 1) bindKey('f1', 'down', toggleFRWindow) createWindow(wndMain) hideAllWindows() txd = engineLoadTXD ("infernus.txd") engineImportTXD (txd, 411) dff = engineLoadDFF ("infernus.dff") engineReplaceModel (dff, 411) guiCheckBoxSetSelected(getControl(wndMain, 'jetpack'), doesPedHaveJetPack(g_Me)) guiCheckBoxSetSelected(getControl(wndMain, 'falloff'), canPedBeKnockedOffBike(g_Me)) setJetpackMaxHeight ( 9001 ) triggerServerEvent('onLoadedAtClient', g_ResRoot, g_Me) end ) I merged the code from this into the code above this one. function ClientStarted() txd = engineLoadTXD ("infernus.txd") engineImportTXD (txd, 411) dff = engineLoadDFF ("infernus.dff") engineReplaceModel (dff, 411) end Link to comment
Castillo Posted January 18, 2011 Share Posted January 18, 2011 addEventHandler("onClientResourceStart", g_ResRoot,getResourceRootElement(getThisResource()), function() fadeCamera(true) setTimer(getPlayers, 1000, 1) bindKey('f1', 'down', toggleFRWindow) createWindow(wndMain) hideAllWindows() txd = engineLoadTXD ("infernus.txd") engineImportTXD (txd, 411) dff = engineLoadDFF ("infernus.dff") engineReplaceModel (dff, 411) guiCheckBoxSetSelected(getControl(wndMain, 'jetpack'), doesPedHaveJetPack(g_Me)) guiCheckBoxSetSelected(getControl(wndMain, 'falloff'), canPedBeKnockedOffBike(g_Me)) setJetpackMaxHeight ( 9001 ) triggerServerEvent('onLoadedAtClient', g_ResRoot, g_Me) end ) Link to comment
xXBaddaBingXx Posted January 18, 2011 Author Share Posted January 18, 2011 Thanks dude, now I have everything working , Really appreciate all of your guys & ladies if any replied for your kind support! Two Thumbs up. 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