More Elephants

Published September 10, 2008
Advertisement
A super frustrating few days for me trying to track down the skinning corruption on the little elephants. If you look closely at the screenshot from last week, you can see the vertices on the elephant's left shoulders and the top of the right leg are corrupted. Here's a more obvious shot with the shader removed:

Disabled

Given I'd had a lot of grief in the past trying to correctly support Maya's "jointOrient" (which basically allows each bone in a skeleton to define an arbitrary "local" rotation space), I assumed there must still have been a some matrix or attribute I'd overlooked. I pulled the whole skeleton/skin export code apart and rebuilt all the matrix maths from scratch. After checking I'd correct exported the Maya joint matrices properly, I did the same thing to my runtime Skeletal animation and skinning code. After pouring through MBs of log files ... everything looked like it should have been fine.

So I started doing what I should have done right at the start. I removed parts of the model (bones, attached meshes, shaders) trying to build the simplest scene I could that still showed the problem. In my experience, this is the fastest way to fix any of these kinds of issues. In this case, the very first thing I did (removing all the bones inside the head ... which should have nothing to do with the arms or legs) made the problem go away. It turns out that despite all the different models I've exported, this is the first model that has skeleton bones that aren't actually used by some of the skin bindings. The runtime code didn't know how to deal with this - so a quick re-write of the exporter to optimise these out, and my little elephants are whole again.


Here's the fixed result with the "good enough" idle animation (click for movie):

Disabled

Custom exporters can be really nice when they work ... but a huge amount of work when they don't. I'm still glad I have my own Maya integration (as it allows me to attach, configure and wire-up the run time behaviours on the game objects - meaning the behaviour of a game object and the object itself are all saved in a single file, rather than having a second level of "game bindings"), but if you have the option of using a "standard" exporter, it certainly saves a lot of work.

Cheers!
Previous Entry Enemy Agents
Next Entry Pretty Dumb AI
0 likes 7 comments

Comments

Aardvajk
Damn you, Milkshake. Now I have to download Quicktime again on my new computer [smile].

[EDIT] Elephants look ace, and really fit with the overall style. Can't wait to see them moving around (plus I remembered to untick Quicktime's "Update automatically" option this time so it shouldn't bug me relentlessly).
September 11, 2008 11:44 AM
Milkshake
Sorry again EC ... I'll be posting a few of these now I have them up and running, so at least you'll be able to use it a few times =)

[EDIT - glad you like them! I was starting to think people mustn't be digging them given I'd not had any positive feedback on them. I was really chuffed that I'd finally found an enemy that seemed to "fit". They look even better running around ... vids to come soon ... I even have an outtake]
September 11, 2008 03:30 PM
Jotaf
Nah, we dig'em :) This reminds me of LBA - Twinsen's odyssey. Featuring low-poly elephant enemies! But yours have a ton of character to make them different ;) I've told you before that I really like this, your game is looking more and more promising by the minute!
September 11, 2008 10:49 PM
Milkshake
Quote:Original post by Jotaf
Nah, we dig'em :) This reminds me of LBA - Twinsen's odyssey. Featuring low-poly elephant enemies! But yours have a ton of character to make them different ;) I've told you before that I really like this, your game is looking more and more promising by the minute!


Phew - glad you like him!

Yeah I really didn't mean for these to end up looking as much like the LBA elephants as they did. I should try and dig up a screenshot of the original textured elephant model ... it looked much more barbaric and "real". But when I put it in next to the cow, it just looked like I'd pasted a screenshot of Big Game Hunter into the game. It was only after I finished the new one that the similarity really dawned on me. Oh well - if there's a game to resemble, LBA is a good one =) And Head Over Heels has elephants in it too - so really, it's the perfect choice of animal.

Thanks for the feedback Jotaf =)
September 12, 2008 07:34 AM
Milkshake
EDIT - double post
September 12, 2008 07:38 AM
Aardvajk
Milkshape, mate, I've had a few beers.

This project sodding rocks. If you don't get replys on your journal, please don't ever think that that means jack shit in terms of how cool this is.

I didn't just pick on you for fun. Every time I see a screenshot, let alone a movie, I think - Christ, this project rocks.

People here, like me and I'm sure you, are busy. Benryes (sic) started building the Terminator about a month ago and I only just noticed.

You need to release some playable demos, methinks.
September 12, 2008 01:46 PM
Milkshake
Quote:Original post by EasilyConfused
Milkshape, mate, I've had a few beers.

This project sodding rocks. If you don't get replys on your journal, please don't ever think that that means jack shit in terms of how cool this is.

I didn't just pick on you for fun. Every time I see a screenshot, let alone a movie, I think - Christ, this project rocks.

People here, like me and I'm sure you, are busy. Benryes (sic) started building the Terminator about a month ago and I only just noticed.

You need to release some playable demos, methinks.


EC, you have my permission to get drunk more often ... even if you do go on Singleton rampages =)

I'm hoping once I get some AI in on the Elephants might be a good time for a demo (give you something to do and give some feedback on) ... but after spending the train ride home reading STRIPS, SHOP and BOD papers ... that might be a while =(

September 12, 2008 07:41 PM
You must log in to join the conversation.
Don't have a GameDev.net account? Sign up!
Profile
Author
Advertisement

Latest Entries

Moose Sighting

1394 views

Constraints

1563 views

Moose

1296 views

Melon Golf

1856 views

Toon

1359 views

Spaceships

1110 views

Rendering Pt2

1201 views

Hardware Shaders

1241 views
Advertisement