Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Author
Message
Benjames8
16
Years of Service
User Offline
Joined: 6th Jan 2010
Location: Your Nightmares
Posted: 15th Apr 2010 07:09 Edited at: 15th Apr 2010 07:31
In my game enemy's are made throughout it. Every time I make an enemy I have to load and append it's animation. Which causes the game to lag a sec. My question is "Can you load a 3d file in the beggining of the program then later assign it to one or even multiple objects?"

If not is there some other way to get rid of that lag? Could do something with loading a mesh then making an the object's from it?
Kira Vakaan
17
Years of Service
User Offline
Joined: 1st Dec 2008
Location: MI, United States
Posted: 15th Apr 2010 10:45
Check out the instance object command.
baxslash
Valued Member
Bronze Codemaster
19
Years of Service
User Offline
Joined: 26th Dec 2006
Location: Duffield
Posted: 15th Apr 2010 10:48
Or clone object...

Hawkblood
16
Years of Service
User Offline
Joined: 5th Dec 2009
Location:
Posted: 15th Apr 2010 15:36
instance object won't work well with animated objects as an instanced object will only have one animation set and therefore ALL the instaces will be in animation sync. Use clone object.

The fastest code is the code never written.
Kira Vakaan
17
Years of Service
User Offline
Joined: 1st Dec 2008
Location: MI, United States
Posted: 16th Apr 2010 01:57
I didn't think about that. Good point.
Sepnon
16
Years of Service
User Offline
Joined: 7th Feb 2010
Location: Brazil
Posted: 16th Apr 2010 02:26
btw.. load mesh will load animations too?
baxslash
Valued Member
Bronze Codemaster
19
Years of Service
User Offline
Joined: 26th Dec 2006
Location: Duffield
Posted: 16th Apr 2010 11:03
Quote: "load mesh will load animations too?"

I don't think so... there aren't any DBP commands to edit the current frame of a mesh anyway.

Just wrote this quick test program and no it doesn't load all frames:


I get "Object has 0 frames" as a result.

chafari
Valued Member
20
Years of Service
User Offline
Joined: 2nd May 2006
Location: Canary Islands
Posted: 16th Apr 2010 13:03
HI there.

@Benjames8
If you want to load an object and then appendt animation of three more objects, you will have to load them all at start, and won´t be any lag...perhaps fps will go down slightly.If not, you will have to make your object with the four animation in the same model.

It is easy to add keyframes to the object, just copy and paste at the end of keyframes bar

cheers.

I'm not a grumpy grandpa
Sepnon
16
Years of Service
User Offline
Joined: 7th Feb 2010
Location: Brazil
Posted: 16th Apr 2010 20:07
@baxslash

hmm.. it means meshs cannot hold animations
I tryed loading it as a object, converting it to mesh and then to object again, 0 frames, but i found something



execute it, the third mesh is different than the first one
the first is flat shaded, while the last is gourad/smooth
Kira Vakaan
17
Years of Service
User Offline
Joined: 1st Dec 2008
Location: MI, United States
Posted: 16th Apr 2010 23:07
A mesh is very simply a mesh. It's only geometry. You can use the make memblock from mesh command and you'll see everything that's inside one.

Login to post a reply

Server time is: 2026-07-26 07:36:09
Your offset time is: 2026-07-26 07:36:09