Jump to content

Game crashes on load object!


Hoss212

Recommended Posts

Posted

Yo, when i try to load my custom object (dff) the game totally crashes. The files only 182kb. It's basically a piece of land I modeled in 3ds. Similar to the one located below...

http://www.gtaforums.com/index.php?show ... 36&hl=Land

Here is my code...

function landSpawn () 
dff = engineLoadDFF ( "cardboardbox4.dff", 0 ) 
engineReplaceModel ( dff, 1221 ) 
createObject ( 1221, -2320.8413085938, -1630.1979980469, 483.3268737793 ) 
end 
addCommandHandler ( "island", landSpawn ) 

META

<meta> 
    <script src="main.lua" type="client"/> 
    <file src="cardboardbox4.dff"/> 
</meta> 

Posted

The only thing I can think of is that the model is unusually complex, try the same thing with just a box.

Posted

Tried a small box and it definitely still fails. I'm modeling in 3ds max and using Kam's DFF export. Could it possibly be something wrong with the collision file? I made a blank collision file and exported the .dff with it so yeah... but maybe I need the collision file somewhere in the resource or code?

Posted

well anyone knows with basic GTA editing for a custom model to work it needs a .txd and a .col to function proply.

so you will need to add this

  
txd = engineLoadTXD ( "cardboardbox4.txd" ) 
engineImportTXD ( txd, 1221 ) 
col= engineLoadCOL ( "cardboardbox4.col" ) 
engineReplaceCOL ( col, 1221 ) 
  

Posted
well anyone knows with basic GTA editing for a custom model to work it needs a .txd and a .col to function proply.

[/code]

You don't need a collision file or a txd, you can import a dff on it's own creating an untextured model.

Hoss this is very strange because I've recently created a model in gmax, not got 3DS yet :P, and used Kams scripts and it worked fine....

Posted

Well, in Kams 3ds Max one you can't export the model as a dff without 'specefying' a col (collision) file. And all I did was just make a blank collision file just to export it. Possibly somthing wrong with the code? Because my friend put it all together...

Posted

Isn't there a tick box to 'Skip Col' ? I have that, if you want upload the model somewhere as .3ds and I can try saving it for you.

Posted

Well, does gmax support 3ds? Maybe it's failing because there is a collision file on it but something is'nt right? Got to be another way, but I only know how to model hight maps in 3ds. I'm at school right now so later i'll see if theres a tick.

Posted

Try to open .col file (which you created) with CollEditor (also available on gtaforums.com) and see if collision exist.

If 'Skip Col' doesn't help, try to export the object mesh to .col and then attach it to dff while exporting to .dff.

I tried with a simple box and it works, but couldn't load the textures. I've posted about it somewhere in other topic.

Posted

Wow Twig thanks! Definitely worked now! Would you please mind telling me what you did or sending me that plug in you have for 3ds max or w/e? I got 3ds Max 2008. Thanks a lot! Just make a quick tutorial starting from 1) Make your 3d model, and then after that so on! :) Thanks again!

Posted

I used gmax to do that along with kams script, all I did was assign the GTA material included with kams and export it with the 'ignore col' box ticked.

cba to do a picture tutorial....

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...