The number of animated/rigged objects on screen.

Ive recently been playing around with duplicating my animated rigged characters in the GE, too see my limits. When I get 7-10 rigged animated characters on screen, My FPS drops dramatically and animation debug is really chewing up. (80+percent). I want to be able to have more animated objects on scene so I am wondering what my options are.

After reading a bit I think ive learned that the actual rig, Not the mesh deform is whats killing the FPS. Ive read that I should make my armatures more basic and with less bones. but they seem pretty basic basic by what i think is basic. My goal is to get more animated enemies on scene at one time.

I would like to know if there is a way to get more rigged, animated characters on through tweaking of any kind.
Is there a way to fake more animated characters without them having actual rigs?
Anything tips or things I could do would be great. The end result is to get more animated enemies on the scene

Any help is much appreciated.

Far away enemys can be a single plane mesh with an animated jpg/png texture (the enemy moving) when they come close they get replaced by actual model characters.

How many bones does your rig have? There are some performance improvements you can try, but they might have compatibility issues:

BGE deformer - Look at the bottom of the Skeleton panel under the deform options in the Armature properties. This is a different mesh deformation algorithm geared more toward the BGE. It doesn’t support b-bones, and I’ve had mixed results with various meshes. However, if it works, it can give you around a 20% performance improvement.

Restrict Animation Updates - Look under the System panel of the render properties. This will only update animations at the animation frame rate (look at the Display panel) instead of the full game frame rate. This can be a significant performance increase, but your animations won’t be as smooth.

it seem to me instead which the problem(slow) of the bones is due by the mesh deformer , not by the bone itself!

how many char you can see in the same time??

and also the demo of Monster I think demostrate this fact (if not wrong) ,which the problem is the mesh , not the bone

b-bone is bone children of other bone (of the same armature)?

umh, maybe depend by kind of test, now , seem in effectly which the slow is due by the bone .

the slow start when the char here more than 20 .

with or without mesh not change almost anything…

need some test more serius

-Whats B-Bone ?
-Theres a “Best Practice” about how many Bones an Armature for Gaming should have ?
- Custom Bone Shapes reduce the performance?

EDIT: i find this is a BBone: http://wiki.blender.org/index.php/Doc:2.4/Tutorials/Animation/Armatures/BSoD/The_B-Bone_Spine
it seems like a Flexible Self-Scalable Single Bone, i never used that.

i think 11 bone(total) is the minimum for a human char (decent)

I think I read that the mesh deform is handled by rasterizer, and my rasterizer is very low, my ‘animation’ is whats totally staying spiked this was sposed to be affectes by the rigging otself. My armatures have normal amount of bones, ill see if I can find the thread. Ill try some of the tips mentioned here and ill upload a small blend of my model/arm when I get back home.

Yup, the animation time can really kill things. Are you using a lot of IK? If so, you could play around with iTaSC. Also, if you’re using an animation frame rate of 24 or 30, then the Restrict animation updates should cut the animation time roughly in half. Also, reducing the number of bones in your rig should reduce the animation time.Also, what do you consider a “normal” amount of bones? “normal” is different for offline rendering and realtime rendering.

Ok heres a test

I figured I would have gotten more of a response out of this sentence: (ill find that thread in just a minute)

I think I read that the mesh deform is handled by rasterizer, and my rasterizer is very low, my ‘animation’ is whats totally staying spiked this was supposed to be affected by the rigging itself. Edit: according to this particular thread I read

Here is the file im using. As you can see its very simple. I can duplicate the wolf 11 times to stay above 30…drops of dramatically for each wolf added after that…


Here is the file. Just duplicate the wolfskin/armature. I tried a few of the things I read I could try on here. I did see a very slight fall in animation. Tell me what you think my options are. :smiley:

Edit: This would define a (normal) amount of bones to me. Maybe it has 1 or 2 extra in the spine that I dont need.

File 2.62 testmin1.blend (1.86 MB)

I got around 25 wolves before the FPS drops to 30. However, there’s a lot you can do to optimize it - animation’s like a high-poly mesh in that it can hurt FPS, but is fairly easy to cull and prioritize. You don’t need to play animations for objects that are far away or not within the camera’s view frustum (i.e. if the camera’s looking away, there’s no need to play the animation). 11 bones isn’t a huge number, but for an enemy, a wolf could have less (i.e. the foot bones aren’t really necessary, and the tail could just be two bones as opposed to four). Or you could just have a relatively small number of enemies (wolves) onscreen at a time.

If you look at commercial games, you probably would be surprised at how many bones enemies actually have. Also, remembering games like Megaman Legends (which was for PS1, but which did animate objects by bones, I think), it usually didn’t have a huge number of enemies onscreen at a time, even though the dungeons were filled with enemies.

Thanks Solarlune very useful.

objects not within the camera’s view frustum (i.e. if the camera’s looking away, there’s no need to play the animation).

Is there a quick and easy to this becuase I have no idea how?

Too much bones and grass texture is too big for that level of detail, i repeat, for that level of detail.

@superflip - Well, I’m not familiar with the Action logic brick, so I’m not sure. It’s easy to tell if something is in the ‘eyeshot’ of a camera, though - it’s got a function that will tell you if something’s visible or not (the center, I believe, not the whole object; for that, there’s a different set of functions that you should be able to use).

Well, I’m not familiar with the Action logic brick, so I’m not sure. It’s easy to tell if something is in the ‘eyeshot’ of a camera, though - it’s got a function that will tell you if something’s visible or not (the center, I believe, not the whole object; for that, there’s a different set of functions that you should be able to use).

any direction on this because my 1st thought of a way to do this was to but some triangle shaped object or some cube object pointing way out in the camera FOV. and only play the animation if collide with object

Ah, that would probably work, but I’m not sure about how the Action Actuator handles stopping actions.

yea , at least 50% of bone excedes :wink:

well , to me there

1 - at least 10 unnecessary bone (in sense which deliting them the animation not lost anything,really)

2 - many vertex here shared with 5/6 vertex group (this is “lazinees!” and pretty wasting),should be only one ,
except where two bone joint , this is pretty common , but is wrong.

3 - the mesh his static/ghost instead of no collision
(static/ghost have the same behaviour of no collision but cost ever more than no collision
the calculation change respect the kind of scene)

4 - other bone here unnecessary , 4 or 5 ,this make lost a bit with animation ,but is acceptable
at least which the wolf is the primary obj of the game

5- other 4 is just to make a optimization strong :smiley:

plus i have delete also some vertex(not much)

try to see if this version run a bit more faster .

note which if you chose “restrict animation update”(as say Moguri) …if is the animation the problem , the speed increase of 2x.

press 1 to add 4 wolf optimizated 8) :wink:

Attachments

testminOPTIMIZ.blend (233 KB)