Monday, August 10, 2015

Sentinel Armor: Almost done

I thought I'd have the armor done this weekend, but I ran across a handful of issues during testing:

  • Normal maps were barely being applied
  • Everything was overly shiny
  • Only the necks of character models weight slide, heads stay the same.
  • Collision for the objects were way off.

Normal maps weren't being applied correctly due to 1) my meshes using the wrong value for "BS Num UV Sets" (1 instead of 4097) and 2) me not updating the tangents. Correcting those mistakes actually brought out the normal map's details.

Up next was every setting I used turning my armor to chrome. After looking at Bethesda's textures, I noticed that not only was the "Specular map" (actually, the environment strength map) different from the alpha channel of the normal map (which is actually the "specular map"), it was also a fraction the size of the diffuse map. As a test, I removed the black lines from the base texture to see how well the normals showed.

After a quick jaunt through NifSkope and Photoshop, I was presented with decent looking armor.


However, something looked rather off about the edges. They were the wrong direction and rather choppy. Given it'd been some time since I made normal maps, I mistakenly hit the "Invert Y" toggle in Nvidia's Normal Map plugin. Direction issue solved.

The jaggedness of the normal maps was due to not having layered normal maps (read it in a tutorial somewhere, a few years ago). A layered normal map consists of multiple layers of the diffuse texture, using a different normal filter type on each (4x4, 5x5, 7x7, etc), and overlaying them on each other. This reduces jagged details and helps accentuate varying heights on the normal map.


Adjusting the necks looked to be a tedious venture. Reason: I exported the neck AND the helmet meshes together as a single NiTriShape instead of separate. This meant any change to one element would require completely replacing the target mesh. Additionally, I would have to use 3ds Max to remove the neck mesh and re-export it for the Mundane variant. Given that my 3ds Max license is on its last legs, that wasn't going to fly.

To fix this, I split the helmets into their components and exported them together so the resulting Nif would have two NiTriShapes. That way, I could use NifSkope to delete the neck meshes for Mundane variant without much hassle.


I never made a collision model for the Sentinel Armor pieces. Instead, I swapped collisions in from vanilla armors. Bad idea. Aside from having differently sized meshes, I had no idea what values were needed or what they should be set to (translation, radius, rotation, etc). Throwing the ground objects around resulted in some wacky collisions where they'd clip through walls, the floor, each other, etc.

I took to Google for the answers and came across this thread (http://niftools.sourceforge.net/forum/viewtopic.php?f=38&t=4207#p26754) which included step by step instructions for convex shape collision creation.

Side note: Making collision models 10x smaller than the actual mesh is bizarre. You're going to make them fullsize in game later, so why not cut out the middle process? *sigh*

With those four issues taken care of (and replicated for the Unique Sentinel Armor variant), I'm testing how the armor works ingame. Specifically crafting, tempering, and enchanting.

Thursday, July 30, 2015

Female Sentinel Armor

I just implemented weight sliding. It was a bit scary due to the realization that I forgot to cap the boots and legs until after I finished conforming to the female_1 body.

I don't remember what I used for BDA to resize it to the female_1 body (probably just a blog post check away), but this time around, I found the FFD 4x4x4 modifier to be extremely helpful. The increased number of control points let me pull and push individual elements around without distorting their original shape too much and I didn't have to deal with making sure I selected the exact same poly/vertex/edge on each side with soft selection.



 So far, the animations seem to be fine. I haven't had any porcupine moments yet, but I'm not holding my breath. I don't appear to have any vertices impacted by more than 4 bones and the _0 and _1 models have the same number of vertices in the same relative places, so I think the model will be okay.

Now I have to load in the male_1 body and scale the armor to better represent that shape (Squarer hips, less up top, etc). Once that is done, I'll probably throw together a helmet to go with the "mundane" variant of the armor. There's the Duty helmet from DA:O, but I don't have a corresponding armor texture for it.

Come to think of it, I don't know what armor texture I used. I pulled from pn_arm_masb which is supposed to be for Cailan's Armor set, but the texture was grey, not gold like the armor set ingame. Given the massive amount of resuse in DA:O, they probably used recolor options in their model format.

I should note that, while the massive armors swapped textures around willy-nilly in DA:O, I'm more restricted due to fully modelling the dragon's head onto my mesh. Massive armors with other normalmap-based details (or lackthereof) will require recreating the chestpiece. Due to the expiration date of my 3ds Max license, it might behoove me to create those two chestpieces and release the texture templates for all three variants...but that's something for later.

I should probably kill the glow and see what this looks like with environment mapping.

Monday, July 27, 2015

Sentinel Armor Skin Weights: Female_0


I've sorted out the pauldrons...mostly. Oddly enough, the solution was to not use the pauldron bones. Instead, I had to use a combination of Spine02, UpperArm, and Clavicle. Using the pauldron bone caused the pauldrons to clip into the upper arm and generally act weird in relation to attack animations. I also had to add a handful of polys to the arms and stash them inside the torso so the stretching wouldn't rip arms from their sockets.

Up next is a couple tweaks to the leather straps that hold the right pauldron in place and then it's time for the Female_1 model so I can implement weight sliding (Remember folks: Don't let the NIF exporter weld vertices or else you get weird stuff happening in game).

For the male models, I'll have to undo the Lattice compression I applied to better conform to the female body, check the skin weights, and export. An easier task compared to Blood Dragon Armor where I had to create a new torso mesh and texture due to the female armor's bust.

In Skyrim, the glow and environmental mapping shaders are mutually exclusive. There is a way around it involving clever use of alpha textures (as mentioned at the end of this post http://forums.nexusmods.com/index.php?/topic/1188259-bslightingshaderproperty-basics/), but I'm not sure if I want to implement it. I like the way the armor looks with environment mapping, but I prefer the void-ish nature of the armor with the glow enabled. The armor appears out of place with the environment and that makes it feel a little more imposing.

Saturday, July 25, 2015

Sentinel Armor Skin Weights - Part 2

I finally caved and went with what the DAO devs chose for the lames/tassets. While not as "physically accurate" as I think they could be (skirt bones...), I can hardly expect it to be lifelike. That said, it looks pretty good.

Up next: The Upper Torso





Sunday, July 19, 2015

Sentinel Armor Skin Weights



According to comments on the NifTools 3dsMax plugin Nexus page, 3ds Max 2014 and later flat-out fail to run the plugin. There have been a couple projects to get 2013+ working, but all appear to be dead. Fortunately, I found I had a 2012 install that was gathering dust, so, one license transfer later and I now have a few more months to bang the Sentinel Armor out.




It took some fiddling to get the armor into the game. I forgot 1) that the first person model, if not explicitly assigned a model, will use the item's model and 2) the first person model cannot use bones that the first person skeleton does not have or else the game will CTD once the item is equipped.

I currently don't have a normal or specular map for the models, so the above screenshot is using the Blood Dragon Armor's for now (and the helmet looks pretty cool with the wrong maps). The glow map, while made, will have to wait until I either fix or give up on the skin weights for the lames/tassets.


Dragon Age's Massive Armor model looks awesome, but the hips are just too busy. I have the original model loaded in 2012 and can see how the DAO devs skinned it, but at the same time I really want to use the skirt bones present in Skyrim's skeleton. However, with the way things are going, I may go back to using the original armor's weight distribution to avoid all the ridiculous clipping.

Friday, April 24, 2015

Blender


In my search for a good 3D Modelling program that won't break the bank, I finally decided to try out Blender. Gmax, while functional with .3ds files, had terrible performance, input lag, and I could just feel the limitations of the program taunting me.

For a test run, I grabbed the 64bit version of Blender (32bit version appears to be required if I want to use NIF tools). Download, extract, run. Pretty simple. I changed the color scheme to this nice Black and Blue theme and thought "Sweet. Let's get started." That's when it all went downhill.

First, my AV software was blocking keyboard input to Blender. Apparently, it's hard to use without a keyboard. With that fixed, I moved on to importing the Sentinel Armor mesh. Aside from warping a mesh I wasn't using, the entire scene loaded without a hitch. Well, everything I had hidden was visible, but I could hide it all later (right?).

Navigation in the viewport was weird. Middle-click was orbit and Shift-Middle click, pan. Okay. Go to the User Preferences, take a gander at the input tab and, what do you know? 3ds Max, Blender, and Maya presets. Sweet. I selected the 3ds Max input preset, hit save, went back into the viewport and...nothing. Still using Blender's inputs. Keyboard shortcuts I'm used to didn't work. Fine. I'll just edit the WHY ARE THERE 10 SHORTCUT ENTRIES FOR EACH ACTION?!

Simple input snafus remedied, I turned my attention back to interacting with my meshes. Left clicking on the Sentinel Armor's translation axis helpers parented it to my cursor's movement until I left clicked again instead of moving along the axis I wanted. Weird, but okay. Right clicking on it, instead of opening a menu like in Maya, 3ds Max, XSI, XSI Mod Tool, and Gmax, placed this weird little circle wherever I clicked. I still have no idea what it is.

Okay, back to basics. Single left-click selected the mesh. Awesome! Now, how do I select a bone component to see if skin weights carried over? Ah, scene tree. I drilled down to a thigh bone and upon clicking it...nothing happened. I still had the entire skeleton selected. Clicking and dragging on it only parented the skeleton to my mouse. But, moving the bones around moved the mesh, so mission accomplished. Hitting ctrl+z placed the bones back, but then parented them to my mouse only on the Z-axis. I had to hit Escape a few times before it let go.

Things I stumbled across afterward:
  • Hovering over menu items produces a tooltip with the python function called and obscures other items. Not a big issue. Just move the mouse and it'll go away, right? Wrong. Also, moving the mouse too far from a context menu closes it. Great.
  • Every window and panel can become any other window or panel.
  • Dragging resize handles on panels creates a duplicate of the panel with no apparent way to undo or delete it. 
  • Any clicks on the name of the viewport you are in don't do anything (like, say, opening a menu to change the view or display options like wireframe mode).
  • The program doesn't remember it's "restored" window size if you close it full screen. Instead, it opens "almost" fullscreen. So, a bordered fullscreen window.
How in the world is allowing this okay?
It's a pretty program, but the interface is all wrong.

I've seen what people have done in Blender, so there's no doubt in my mind that it is a powerful program. But presenting a user with every option upfront without giving them a chance to adjust or figure out the basics seems wrong to me. Especially with such a flexible interface. I screwed up the UI by accident and had no idea how to fix it (duplicated panels left and right). Hence the image above.

I looked into making Blender behave more like 3ds Max, but most of what I found consisted of "Why would you want to do that? Just get used to it." So, I'm going to have to make every tweak needed to create a facsimile of a familiar 3d modelling environment. It isn't necessarily a bad thing. Getting into the guts of the UI will probably help me understand it.

I came in expecting a fairly simple interface that, with some minor adjustments to my flow, would behave similarly enough to what I'd used before so I could at least continue with a project (like when I moved from the XSI Mod Tool to 3ds Max). I was incorrect.

Since there doesn't appear to be any other free, fully featured, 3D Modelling programs, I'm left with a couple choices. Save up for 3ds Max (and hope my plugins work) or start from scratch in Blender. Lovely.