Sex* Posted February 10, 2013 Share Posted February 10, 2013 (edited) function ResetModel ( ) engineRestoreModel ( 411 ) end addEvent ( "restoreClientModel", true ) addEventHandler ( "restoreClientModel", getRootElement(), ResetModel ) addEventHandler("onClientMapStarting",getRootElement(), ResetModel) Edited February 13, 2013 by Guest Link to comment
GTX Posted February 10, 2013 Share Posted February 10, 2013 Try this: function mod() txd = engineLoadTXD("infernus.txd") engineImportTXD(txd, 411) dff = engineLoadDFF("infernus.dff", 411 ) engineReplaceModel(dff, 411) end addEventHandler("onClientMapStarting",getResourceRootElement(getThisResource()), mod) addEventHandler ( "onClientResourceStart", getResourceRootElement(getThisResource()), mod) Also check if these files exist and they're in meta. Link to comment
Sex* Posted February 10, 2013 Author Share Posted February 10, 2013 Try this: function mod() txd = engineLoadTXD("infernus.txd") engineImportTXD(txd, 411) dff = engineLoadDFF("infernus.dff", 411 ) engineReplaceModel(dff, 411) end addEventHandler("onClientMapStarting",getResourceRootElement(getThisResource()), mod) addEventHandler ( "onClientResourceStart", getResourceRootElement(getThisResource()), mod) Also check if these files exist and they're in meta. no....i want to load infernus.txd and infernus.dff from GTA directory. Link to comment
Sora Posted February 10, 2013 Share Posted February 10, 2013 i think that this function loads only the files which are added in meta and exist in the resource if you're trying to restore the original model use engineRestoreModel Link to comment
Sex* Posted February 10, 2013 Author Share Posted February 10, 2013 Well, this doesnt work: function ResetModel ( ) engineRestoreModel ( 411 ) end addEvent ( "restoreClientModel", true ) addEventHandler ( "restoreClientModel", getRootElement(), ResetModel ) addEventHandler("onClientMapStarting",getRootElement(), ResetModel) Link to comment
Sora Posted February 10, 2013 Share Posted February 10, 2013 Well, this doesnt work: function ResetModel ( ) engineRestoreModel ( 411 ) end addEvent ( "restoreClientModel", true ) addEventHandler ( "restoreClientModel", getRootElement(), ResetModel ) addEventHandler("onClientMapStarting",getRootElement(), ResetModel) umm that's weird try this addEventHandler("onClientMapStarting",root,function () engineRestoreModel( 411 ) end) setTimer(engineRestoreModel,1000,1,411) Link to comment
Sex* Posted February 12, 2013 Author Share Posted February 12, 2013 Still doesnt work. Link to comment
Blaawee Posted February 12, 2013 Share Posted February 12, 2013 'onClientMapStarting' isn't a custom race event ? try to add : addEvent( 'onClientMapStarting', true ) Link to comment
Tails Posted February 13, 2013 Share Posted February 13, 2013 addEventHandler('onClientResourceStart', resourceRoot, function() txd = engineLoadTXD ( "infernus.txd" ) engineImportTXD ( txd, 411) dff = engineLoadDFF ( "infernus.dff", 411) engineReplaceModel ( dff, 411) end ) Link to comment
Sex* Posted February 15, 2013 Author Share Posted February 15, 2013 Well this doesnt function: function ResetModel ( ) engineRestoreModel ( 411 ) end addEvent ( "restoreClientModel", true ) addEvent( "onClientMapStarting", true ) addEventHandler ( "restoreClientModel", getRootElement(), ResetModel ) addEventHandler("onClientMapStarting",getRootElement(), ResetModel) addEventHandler ( "onClientResourceStart", getResourceRootElement(), ResetModel ) Link to comment
Castillo Posted February 15, 2013 Share Posted February 15, 2013 The event: "restoreClientModel" is triggered by? function ResetModel ( ) engineRestoreModel ( 411 ) outputChatBox ( "Model should be restored." ) end addEvent ( "restoreClientModel", true ) addEvent( "onClientMapStarting", true ) addEventHandler ( "restoreClientModel", getRootElement(), ResetModel ) addEventHandler ( "onClientMapStarting",getRootElement(), ResetModel ) See if it outputs that message to chat box. Link to comment
Sex* Posted February 16, 2013 Author Share Posted February 16, 2013 I put outputchatbox many times... but as you see it puts out a message but my infernus is still with those shit wheels. Link to comment
Castillo Posted February 16, 2013 Share Posted February 16, 2013 These wheels are part of the infernus mod itself? Link to comment
Sex* Posted February 16, 2013 Author Share Posted February 16, 2013 No these wheels come with custom infernus: http://ffsgaming.net/threads/8367-Str1k ... Edition%29 Link to comment
Castillo Posted February 16, 2013 Share Posted February 16, 2013 If the wheels are part of the infernus mod, then maybe the problem is that the script is restoring the original infernus too fast. Link to comment
Sex* Posted February 16, 2013 Author Share Posted February 16, 2013 If the wheels are part of the infernus mod, then maybe the problem is that the script is restoring the original infernus too fast. Ye they are a part of that mod. But how it would restore slower then? Link to comment
Castillo Posted February 16, 2013 Share Posted February 16, 2013 I don't understand why do you replace it on the first place. Link to comment
Sex* Posted February 16, 2013 Author Share Posted February 16, 2013 I don't understand why do you replace it on the first place. Im not replacing anything! Im using custom infernus(modified GTA3.img in GTA installation directory), but the wheels load after vehiclechange only. But FFS and and TFF load my wheels on map start. 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