So, it's not necessarily pretty, but here's the first test of the 2D sprite rig in action:
I added a second isometric view of the rig so it was a bit easier to tell what's going on. The top left view is what will appear in the game.
So far, I'm pretty optimistic about this approach. It can have some pretty fluid and detailed animations, and still allow modders to create their own clothes, shoes, heads, and other parts without needing to know how to model or rig meshes. And it still allows for the pixel art aesthetic.
I still need to test it with normal maps and lighting. And hook it up to the actual space prototype, for that matter. But not a bad start for 2ish days of work!
And I'm excited to think what an actual animator and pixel artist could do with this setup :)
Hey Folks! We've finally finished moving from Canada to Seattle! Still plenty of unpacking and furniture-arranging to do, but the last of our stuff and pets is safely here with us. Yes! We've just started transferring our accounts, driver's licenses, and this is going to be a long process. So likely lots of errands to run in town. But at least no more 500-mile road trips for the foreseeable future!
Now that I'm back, I took stock of my current situation to see what needs attention next. I've finally got my characters walking around and interacting based on their data, which is good. But I think it's going to be necessary soon to improve the visual feedback of what's going on. And that means two things: UI and animations.
UI might actually be pretty simple. After cobbling together my data editor, I think I've got the hang of that. I've got some ideas for portraits, and I have plenty of NEO Scavenger encounter icons to use for activity icons. So a lot of work is already done (if only placeholder).
Animations, on the other hand, are virgin territory. At least in Unity. Fortunately, I was a tech artist at BioWare in a previous life, so I know at least a few things about rigging and animations :)
One of NEO Scavenger's cool features was to see what a character was wearing/holding from the sprite. I'd like to do this for ship crew, as well. To save myself the trouble of hand-animating a million different sprites for each combo of equipment/clothes, I'm working on a top-down, sprite rig that I hinted at in an earlier blog post:
The idea isn't too much different than any other game's 2D sprite. Just some GameObjects in a humanoid-style hierarchy with sprites attached to each. However, most games have all their sprites facing the camera, and I've decided to make some face perpendicular to the camera direction.
The thinking here is that the player will always see the tops of the head, shoulders, and feet in an animation, and things like the legs and arms only appear when they bend forward or backward in an animation. E.g. if the knee comes forward, the camera will see the upper leg peek out from under the shoulders, along with the foot. Ditto for the hands/arms.
Another benefit of this rig style is that it's still a pretty normal 3D humanoid rig, stretched out along the Z-axis. Even though the camera doesn't care about the z-dimension much, I can create poses and animations in 3D more intuitively just by mimicking actual human poses. E.g. rotate the leg forward and bend the knee, rather than trying to guesstimate how far forward the knee should be vs. the foot if they were just sliding forward/backward.
My hope is that this will allow me to take advantage of simple sprites for faster art asset production (and easier modding), while still allowing for animations and swappable items/clothes. One question remaining is whether the normal-mapped shader will work in this configuration. The shadows may not look right since each part is flat.
But we'll have time to test the visuals once there's a sample animation. For now, I've barely got the rig and parts done. I need to start keyframing tomorrow. See you then!
Hey Folks! Today was a bit of graphics work, and the beginnings of a design/UI change for AI interactions.
The graphics change was an experiment with a new unlit material on crew. If you look at yesterday's screenshot, you'll see the original lit shader with normal maps on the crewmember. It catches highlights and shadows from the environment, giving it a sense of shape and volume.
Unfortunately, it also makes it a bit hard to see the crew in some lighting situations. A case of realism not necessarily benefiting UI.
A technique some games have used to improve this usability, and to also give a distinct visual style, is to make characters unlit while the environments are shaded. This style is typical in an animated film, where characters are cel-shaded while the backgrounds are matte painted. I decided to see how it looked in this case, and here's what resulted:
I don't mind it, actually. I'm not 100% sold on it either, though. I think it's one of those things I'll need to leave in as optional until later when I can see things in action. The one thing I can say with certainty is that unlit art assets will be easier to make since they require no normal maps. This is not only good for me, but for modders, as well. Again, though, we'll have to see.
I also started working on some new selection code for crew sim mode. Previously, the mode would just auto-select any AI that was performing an interaction set to show info to the user. So the brackets would jump around the crew at random intervals, and it was a bit confusing.
As an experiment, I think I'm going to let the user control which AI is selected, and only show status messages at the bottom if that AI is doing something that triggers a message. And for anyone not selected, I'll probably show an icon over that AI to indicate it's doing something. The user can then click on that AI or icon to see more info. This way, the user can focus on a single AI without getting bombarded by noisy info, but also be alerted to other goings-on in the ship.
So far, I've got the crew and items selectable by clicking, and the brackets will focus on that object. And relevant status messages appear if so.
Out of Office
Finally, I have to miss a couple more days of work (unfortunately). Our pet snake is still waiting for us in Canada, and our permits to export/import it finally arrived. So we're heading back to retrieve it. So I'll be away from the office for a few more days. Probably until Wednesday next week. It's a bummer, as I just reached my stride getting stuff done.
However, the good news is that this is our last major traveling obligation for a while! After that, we have minor errands like getting our new IDs and such, but shouldn't have to leave town (or miss whole days of work). Looking forward to it!
For now, have a good weekend, all, and see you next Wednesday!
Hey Folks! Today, I was able to finish up the data editor, and use it to solve design bugs!
After getting the Conditions editor working, and a few save/load issues, it was time to put the editor to work. And I'm happy to report that it's already paying dividends. First of all, I was able to figure out why my sleep cycle wasn't working correctly. By quickly loading and cross-referencing data types in the editor, I noticed a typo in my sleep "allow" interactions. It was simultaneously adding and subtracting sleep stats each tick, instead of subtracting two. A few clicks and edits, and voila!
I also added my first new data field in a long while. The sleep cycle showed the bed's portrait when sleeping concluded (due to the way interactions are chained, the bed allows/denies sleep based on the user's stats). So to make it look less weird, I decided to add a checkbox to make any interaction show the other party's portrait instead. I'm not entirely sure this is a big win on its own, but more importantly, adding new data fields to the game and editor was pretty trivial. So I should be able to change the data formats in the future without much trouble, and this is good news. I expect data formats to change a lot.
This bodes well for more rapid iterations in the near future. I'm looking forward to getting this game design rolling again!
Hey Folks! I managed to get the condition trigger portion of the editor running today. I'm able to load a trigger from the game data, change values, and have it save the data.
Currently, the editor only shows one trigger at a time. Loading a new one closes the old one. It might be ideal to show more than one, but I'll save that for when I really need it. As a result of this setup, though, I realized I needed to save data whenever I close an object to preserve it's data. Otherwise, the user would have to click "save" every time they switched what they were editing, and risk losing edited data. Users will still have to click "export" to write the data to files, as changes are only in game memory until then.
Also, the export feature revealed an annoying bug today. Many of the trigger values are +/- infinity, and the JSON writer I use doesn't like that. I found myself having to write some special case handlers for single-precision numbers to allow for infinity. I've got this partially working (input), but still need to work on saving them out again to files.
Otherwise, it's going pretty smoothly! Hopefully, I can nail that down tomorrow, and get started on the Conditions themselves, Have a good night, all!
First day back at the desk, and it feels good to be working again. I always get antsy the longer I'm away, and this time was no exception. Combine that with the stress of moving household across an international border, and you have one anxious developer :)
Most of the morning was spent catching-up on emails and forum posts, and the administrative tasks that go along with it. Nothing too exciting, though I did manage to finish negotiating a contract for a web development firm to help me relaunch the site. It'll be an ongoing project over the next few months, but when it's done, there will be a new site. And importantly, people who are not me to call on if I need emergency work or maintenance done :)
With that out of the way, I returned to working on the data editor. This time, porting the Interaction editing tools to be useful on Conditions and Condition Triggers. So far, this is more tedium than challenge. Mocking-up a new UI in Unity's editor, and starting to hook up the logic, which is largely copy-pasted from the Interaction code.
However, it might force me to make some changes to the editor's architecture to better support multiple data types. I'm hoping that won't be too extensive, though. Just some minor changes.
More on that tomorrow. For now, however, it's back to my second job of late...
Hey Folks! Just finished getting the office (mostly) unpacked last night. It's good to have my main dev machine again! Still plenty of boxes to sort through, but I think I can get back to normal Monday. Woohoo!
Also, I may have figured out that pesky "maintenance mode" bug the site's been having. Looks like a memory limit issue with cron. I was able to increase the limit on the server, and it seems to be behaving now. We'll have to give it time to see if it's the real fix or not.
Anyway, I'm back! And I'll catch up to emails and forum posts as soon as I can, starting Monday. For now, more boxes to unpack...
Hey Folks! Checking-in to let you know I'm still in the process of moving. We're in Seattle now at a hotel, we've received the keys for our new rental house, and the movers arrive tomorrow with our stuff! Plus, I think most of our utilities are lined-up, and I should have power, internet, water, etc. ready to go. The home office may still take a day or three to unpack, though :)
Also, I apologize for the extended site maintenance. I have a periodic cron run to do things like database backup, search indexing, etc., but it got stuck and never switched the site back on again afterward. It seems to happen once in a while, so I'll have to sort that out once I'm setup in the new office.
Probably a few more days yet of unpacking to do, but I hope to resume normal operations soon. I'm anxious to get back to work!
Hey Folks! I managed to get the interaction editor just about finished today. I dare not say "finished," as there will always be bugs and polish to sort out. But the necessary features are all in place now, and it looks like this:
I can load and edit interactions, create new ones, link and unlink them, and save all this back out to a json file. The editor even updates all dropdowns as node names change or nodes are added/deleted, and can even figure out which upstream/downstream nodes to load if the user tries to load the middle of a chain.
Plus, I added buttons to jump into the ship editor and back again, for rapid prototyping. I still need to add UIs for conditions, triggers, and items, but those should be faster to do now that I have the most complex data type running. Soon, I'll be editing game data again!
Out of Office
Also, we're moving!
Starting tomorrow, things are going to be quiet around here for about a week. I have to return the cable modem to the ISP tomorrow, and we'll be packing up furniture and belongings shortly after. Then, we're on the road to Seattle!
We expect to be in town on the 14th, and begin our move-in on the 15th, so I'm expecting radio silence until at least a couple days after that. We should have power and internet ready to go upon our arrival, however, so hopefully, we'll be back on our feet soon.
Enjoy the rest of your week and weekend, and I'll chat with you again from the other side!
Hey Folks! Hope everyone had a good weekend. This was our last weekend in BC with furniture, so we're enjoying things like eating at a table, and sleeping on a bed. Soon, the movers will arrive, and we're off!
Back at work, I was unfortunately mired in non-gamedev stuff today. I had a bunch of administrative stuff to take care of (e.g. taxes, moving, contracts), and then I dumped pretty much the rest of my time into solving website issues.
Some of you may have noticed the site breaking in places yesterday and today. Especially links and images. This was my fault. Sorry! I thought I was being clever by changing the settings to make URLs automatically into links for people who forget to use the BBCode tags.
Unfortunately, BBCode and this auto-linking don't play well together, resulting in double html code and broken links. I've reverted that, and things seem to be back to normal now.
Also, some of you may have noticed issues with posting or editing in the forums. It turns out there is a bug (or more accurately, overzealous setting) in the server firewall which flags legitimate posts as SQL hacking attempts. It usually happens when the post contains certain sensitive keywords.
I'm working with the site host to see if we can make this rule a bit more user-friendly. But in the meantime, we're stuck with occasional 403/Access Denied errors. Again, sorry about that!
Hopefully, we can get things resolved soon. Also hopefully, I can get back to making games someday :)
Hey Folks! Sorry about the late update today. I was in town for an appointment, so did most of my work from there. A chunk of it was getting back to some vendors on a proposal, and the rest was continued editor work.
I did manage to get the interaction link arrows setup with an "unlink" button each, however. Now, I can add new nodes to the current chain, and remove them again later. I still need a way to remove them from the current scene (e.g. hide or close them), as well as a way to remove them from the game entirely. And that'll also mean a way to save data back out to json files.
Plus, I need to generate new blank interaction nodes, and eventually, condition, condition trigger, and item nodes. The good news is, interactions are the hardest of them all, and the rest should come more easily.
For now, it's weekend and time for a break. See you all Monday!
Hey Folks! I finally had a chance to dip back into prototyping today. Woohoo!
When I last left off, I was trying to get the interaction editor to show all interactions in a chain. I had them all loading, but there was a lot of overlap, and no way to tell which node connected to which.
After some fixing-up today, here's where I'm at:
Like practically every editor I make, it's nodes connected by arrows. In this case, a sleep request branches into allow/deny nodes, and the allow branches into continuation allow/deny, etc. Each continuation is a new phase of sleep until it cycles back on itself, or the AI wakes-up.
I want to be able to move these around, add new nodes, delete old ones, and tweak the settings of each node, so I can cook-up interesting interactions for the AIs to perform during long flights. This makes things easier for me than trying to edit multiple XML files that are way too long to navigate, matching up string refs and such.
There's still much to be done, not the least of which is to make this save the data back out to XML. And I'd also like to extend this editor to work on items, ship equipment, and other node types. But it's getting there!
Added optional autosave feature to save game at the beginning of each new turn.
Added ability to choose whether encounter map labels appear on minimap by adding =0 or =1 at end of data. If missing, assumes minimap label added.
Changed crowded map labels near DMC gates to be invisible on minimap, so only gates visible.
Fixed a bug that allowed communal barrel fires to be destroyed in extinguished fire recipe.
Fixed a bug in loading screen that prevented log from being added to clipboard if error in XML file.
Fixed a bug that misreported 0.0 charges on charged encounter items.
Fixed several null pointer bugs when loading save file that included content missing from currently-installed mods.
Fixed a null pointer bug if game tried to load recipe scrap for missing recipe.
The big change here is the new autosave feature. It'll try to save the game at the beginning of each turn so your progress is not lost in the event of a power outage, crash, or other event. It is enabled by default, and can be disabled on the options screen. Note that permadeath is still active, and your save will be deleted if your character dies.
Also, some modding enhancements made their way into this build. The loading screen logs should now be fixed in the event of bad XML format. And minimap labels can now be controlled by modders. An =0 means no label, while =1 means a label is added to the map. Default assumes a label is added.
Finally, the number of charges in an encounter item are now correctly reported, among some other null pointer fixes.
The likelihood that this version of NEO Scavenger will work with previous saves is: likely.
As usual, the older the save game version, the less likely it is to work.
As always, let me know what you think of the changes, and if you notice any issues with the new build!
I decided to move forward with a new NEO Scavenger update. There are a few bug fixes worth uploading, as well as this:
S1eeper reminded me in yesterday's blog post that a lot of people have been requesting Autosave functionality. It's something I've looked into before, but had trouble getting it to work correctly. I took another crack at it this morning, and I think it's behaving better now.
Basically, the game will attempt to save your progress to the save file at the beginning of each turn on the map. For now, just the map. No combat nor encounters. And it's at the beginning of the turn because the game world does all its updating at the end, so saving before that would mean loading and then watching the turn play out.
Note that this doesn't affect permadeath in any way. (Or it shouldn't, anyway.) It doesn't create more than one save file, and if you die, you still have to start over. However, this does help avoid issues such as losing progress due to a crash, power outage, cat, or other act of god. It's a convenience feature, not for game balance.
For the time being, this will be an optional feature that defaults to "on." It can be turned off on the "Options" screen, and it might be necessary to do so for long games with lots of content, especially on slow computers. I'll have a test build up soon, and we can see how it performs in practice.
Anyway, this should be a pretty exciting feature for those of you with shaky power grids or curious pets.
Now, for the real trick. Figuring out OSX code signing and other annoying developer stuff to get new builds online :) More on that tomorrow!