Avatar Upgrade Progress

Hey Folks! The new avatar is actually coming along pretty nicely. I did quite a bit of tweaking today, as well as further code integration, and it's almost ready for prime time.

A good chunk of the work was redoing the UV maps on the mesh. The hack job I did was a decent placeholder, but there were a lot of seams and misaligned pixels as a result. And since I was trying to use a similar pixel density to the surrounding ship, those mismatches were much more apparent.

Once that was done, I did some rearranging to make room for an EVA backpack on the UV map, and created a corresponding mesh for it. It isn't pictured here, but it should just be a matter of adding it's sprite name to the data for the EVA suit item.

Finally, I've almost fully replaced the old sprite-based crew with this new mesh one, and that includes swapping parts for clothes. The suit and helmet can be triggered by the item data, and their appearance swapped based on the texture specified there.

What remains is to integrate the skin and hair color into the code for changing the base texture, and to create the corresponding textures for each. One big bonus to this approach is that I have one texture for each base mesh, instead of the 10 used for the sprite sandwich version. So that's a bit less overhead to maintain.

Today's screenshot shows an array of different situations, animations, and appearances from in-game. There's one apparent lighting glitch on the top left, where the shoulders look dark. Could be a surface normal issue, or else a light being too low to the ground for the new tall human mesh. It seemed to work yesterday, though, and I haven't changed heights on anything, so my gut feeling is it's the normals.

One thing not apparent from just this screenshot is the animation speed: it feels a bit sluggish. I actually matched the walk anim speed to movement, but I might have to tweak this to feel more natural. The nice thing, however, is that this is just changing some sliders!

Finally, I have yet to decide how I want to handle other clothing. Things like pants, shirts, and shoes. One approach is to make a mesh for each, the same way I do the EVA suit. But I expect the transparency to cause rendering issues, so I'd need one texture for each skin/hair combo. The same problem might apply to short vs. long sleeves/legs, and other things with differing skin lines. I'm unsure whether there's a performance hit for hidden meshes if I had a bunch and toggled them on/off as needed, but it's something to consider.

Overall, I think the change is an upgrade!

Tags: Ostranauts