Monday, September 9, 2013

Arm, Chair, Head, Mechlab

So, I've been getting a really bad pain in my right arm thanks to my awful posture. I broke the right armrest clean off the chair, and then finally broke the backrest around the time the pain creeped up my neck. So, I tossed the chair out and did some craigslist hunting. I found one for $10 that's so comfortable I think I could melt into it. I've seriously never had a chair this comfortable in my life. It needs one bolt where they lost the lock for the right armrest, but that's all of what, 30 cents?

Because of this, I've tried not to do too much hard core modeling. However, I did decide to work on an interactive mech lab for Mechwarrior Online. What exactly do I mean by "interactive"? Well, here is a quick tech demo:




Not too pretty, and lots of work to be done. Expect it to be multi-platform (Windows, Linux, MacOS) but not mobile.

Sadly, the elevator of all things is giving me problems. Poor Bill never saw it coming. You know, you show up for work thinking the maintenance guys have been doing their job, and you go through the same procedure that you've done a thousand times before. Then this happens:




The doctors said that the swelling will go down in a few weeks, but he'll have to pee sitting down for the rest of his life.

Seriously though, still putting everything together, despite the pain in my arm. I did order an ergonomic mouse and gel wrist pad, so hopefully that will help out for those marathon modeling sessions.

I'll post more when I have it. Until next time!

Tuesday, August 27, 2013

Mechwarrior Online and Third Person View (3PV)

So, PGI finally added 3PV to MWO, and it's causing part of the internet to burst into flames:


I made the comic in reaction to the, well, vocal reaction to 3PV. It's a bit rough as I didn't want to spend a lot of time on it. But if there is some interest, I could flesh out the characters and add a bit more polish for a full series. To include a full cast of characters and a Mechwarrior Online theme, to be sure (probably even a deeper battletech theme).

Honestly, I'm not overly surprised. I'd rather not have it included (my personal preference) but it is pretty vital as a learning instrument for new players. Certain games, such as War Thunder, have an entire play mode dedicated to new players who don't want to learn hardcore mechanics. Hopefully MWO will be at a point in the future where they can segregate new players for a number of matches (or even permanently if they so choose) in a boiled down environment that's much more forgiving.

That said, the game is still fun, and new players shouldn't have too difficult a time learning if they hop onto a teamspeak server and pair up with veterans. It's definitely for the thinking gamer and relies heavily on teamwork.

Thursday, August 15, 2013

New Brewing Blog

Hey all! Not strictly 3d model related, but my friend and I have started up some home brewing. I just finished making some Musk (that will become mead in a couple weeks with any luck). If that's your kind of thing, you can pop over to our blog. We'll try to keep it updated as frequently as possible, but brewing is a slow sport that requires a lot of patience. I'm sure my friend will post plenty about fermenting other things, such as vegetables.

Thursday, August 1, 2013

Using Sketchup to Design Game Models

Disclaimer: I'm not an industry veteran or 3d instructor. I'm merely sharing my set of experiences to anyone who is interested.

Purpose: I've been noticing a distinct pattern of misinformation and plain bias related to using Sketchup to produce game assets, specifically towards Unity (as that is the engine I've currently been developing on). The greatest cause for this happens to be the lack of any good information relating to how Sketchup works and what it can actually produce. Because it's designed primarily as an architectural tool, not generic 3d modeling platform, most of the Sketchup veterans have no interest in game design. Likewise, most game design veterans are loath to use a program that is not 3ds Max or Maya.

I've decided to attempt to dispel many of the rumors and clear up misinformation surrounding the use of Sketchup for game design. This paper, if you can call it that, is broken up into 3 sections - comparison, usage, and conclusion. Hopefully you, as a reader, can walk away from this with a tad more understanding of how Sketchup fits in the game development process. Bear in mind that Sketchup is not an all inclusive tool, not by any stretch of the imagination. Even if you do decide to use it, you'll need additional tools.

Comparison

Lets begin by outlining the basic characteristics of Sketchup:

Easy to learn.
Excellent for hard surface modelling.
Non-alpha texturing.
Component design and manipulation.
Generally spline based modeling.
Automatic Topology management.
Free*.
Extensive Plugins.
Poor organic modelling.
No advanced tools (UV wrapping, rigging, poly painting, etc)
Exports to Collada*.
No manual Topology editing.

If you're new to 3d modelling, you're probably wondering what all that means, so lets go over it briefly.

Hard Surface vs Organic Modelling: Imagine in one hand you have a rubik's cube and in the other you have an apple. Now, at first glance these are both "hard surface" objects. But when we discuss hard surface and organic in 3d modelling, we are referring to the complexity of the geometrical shape - or how many curves are on a surface. In the case of the rubik's cube, it's completely flat along each side. Even if we were to turn one of the sections, it would still be composed of entirely straight edges. The apple, on the other hand, is not even symmetrical. It is oblong and mostly rounded, but also curves in at the top and bottom. It has small dimples and imperfections that cause the surface to be rough.

However, do not mistake organic for explicitly meaning only biological entities. Consider a modern car and and a cyborg from the Terminator series. Both are inorganic - that is, they're just machines. But the terminator is still an organic model, with all the complexities of a human skeleton.

This is organic:

This is hard surface:

Sketchup is capable of creating organic models, and there are plugins to make this much easier. It is far simpler, however, to limit any type of organic modeling you do with Sketchup to a minimum, as you're trying to reinvent the wheel at that point. It is much more expedient to use a program like zBrush that was designed specifically for creating very detailed organic models in little time.

Texturing: Sketchup uses a very primitive surface texturing system that applies a single layer to a single, continuous surface. This means you can't brush in fading paint or specific detailing. The following image shows how Sketchup divides a surface based on lines. These lines denote what is a continuous surface. As you can see, it's impossible to bleed one texture into another for any kind of fading effect.


This entire object is a single surface with arbitrary lines placed on it. Note how the texture simply stops at the line. There are plugins to convert surfaces to quads and perform primitive unwrapping, but they are spotty at best, and highly unreliable. As a general rule, you will want to use another program, such as 3ds max, blender, or zBrush if you want to create a high quality texture for the model. Sketchup is also incapable of adding additional alpha textures, so you can't do bullet holes and blood splatters as decals.

Component Design: The strongest part of Sketchup is its component system. Starting with nuts and bolts, it is possible to design an entire component hierarchy where every part of a car is quickly and efficiently reusable. And this transfers between projects. An artist designing motors on his machine can export them as components for separate artists to bolt onto frames, who can then export those components to the body designer. Because all of these parts are reusable and rapidly re-sizeable, artists can produce buckets of interchangeable parts.

When a component is edited, it updates all instances of that component in the scene, reducing the time it takes to fix mistakes. Finally, it allows for extremely fast prototyping. A group of artists can collaborate, sharing components to snap together mockups of different objects and generate scenes with very little time or effort.

Topology Management: Sketchup automatically manages all the topology in a model. This is both good and bad. Topology in Sketchup is almost always clean by default, even when doing some pretty weird things. But in the even that you want to manually adjust the topology, you're out of luck. However, given the nature of Sketchup, this shouldn't be an issue. Your geometry should remain fairly basic, as will be outlined in the next section. A good thing to remember is that Sketchup is purposely simple. You shouldn't be doing anything too complex with it.

Plugins: The final, and possibly most important, characteristic of Sketchup is its robust plugin system. There are a considerable number of plugins that make modeling easier. The vast majority of these plugins are produced by the community, generally free and regularly updated. Keep in mind though, these plugins may become abandoned at any time, and therefore cease to function as intended.

*There is a professional version of Sketchup that costs money, but includes the ability to export to .obj and .stl natively.

Usage

Now that we're a bit more familiar with Sketchup, lets look at how it works in practice.This won't be a comprehensive tutorial, but should serve as some basic guidelines for using Sketchup and Unity.

Getting a Model Into Unity: I don't recommend using Sketchup for conventional game models. You can't control their level of detail (LoD), you would still need a 3d modeling suite to rig and animate them, and they will have only basic texturing. However, that said, they are excellent for terrain, mockups, and any game that doesn't require animations.

You can, for example, make item drops, along with their inventory icons rather quickly. Make a basic item (remember, we're looking for hard surface models that we can make very quickly). This sword took me only a couple of minutes to model:


Note that it's untextured and rather bland. From here, you can open photoshop or gimp and make yourself some basic texture sets. Because this is a sword, I made mostly metal textures to apply. Then, open the Materials section of Sketchup (it's the paint bucket in the tool bar) and click the new material button (the + in the upper right corner). From here, just add the texture you made and name the material:


Then apply the materials to your object. Here, I applied the textures and separated out the components so you can see how I could quickly make custom blades, cross guards, grips, and pommels for a huge variety of swords:


Here is the interesting part - if you were to export the model without doing any coloring or texturing, every surface appears as its own object in unity. This makes the model both unusable and highly unwieldy. Thus, if you are going to use any model made in Sketchup (no matter how you export it) you must apply some color to it, even if it's white.This defines the object groups and makes it manageable.

Also, make certain your item is as close to the center of the axis as you can possibly make it. Otherwise, Unity will not be able to rotate it properly. Keep in mind that blue is "up" when imported in Unity. This means that all 3 colors should intersect in the middle of the object, and blue should come out of the top:


Now, at this point you have two options:

1) Get an obj exporter plugin.
2) Use the native .dae or .obj exporter (depending on whether you have the free or pro version respectively).

I personally use the .obj exporter at the moment because it spits out the textures in a usable folder as well. But again, it's not necessary as you can just as easily create the Unity materials from your existing texture files.

Using GIMP or photoshop, you can also create a sprite sheet:



You're not quite done yet if you want to use this to quickly generate icons. If you're interested in doing this, I have a decent write up for it here. Otherwise, drag and drop your object into your Unity project and follow the usual steps to texture it (make a material for each texture and apply it). From here you can throw together a lot of prefabs:




Now, for the million dollar question - are these items legit? As in, can they be used just like any other swords in a game? Yes! In fact, here is a tech demo that features models made and textured in Sketchup. Keep in mind, it's just a tech demo and very, very far from a polished game.

Conclusion

This outlines exactly how it is possibly to rapidly produce models, either as mockups or finished products, for your game using Sketchup. A professional studio may find fewer uses for Sketchup, but many studios do actively use it as part of their design pipeline. Indie developers can make even better use out of this free tool, rapidly creating background and environmental assets that don't require a great deal of detailed textures or animations, or by importing it into blender for texturing (as Sketchup is far easier to create the base model with). 

It's also possible to use Sketchup to design your primary art assets if they don't contain animations. Tanks, helicopters, star fighters, even spaceships are all easy to design, texture, and plug into a game without any kind of budget. Indeed, the ease of use makes it excellent for new developers to begin with, and prevents them from launching into a game that will simply be too complex (IE, prevents them from embarking on yet another MMO) by forcing them to choose a much more simple game.

Sketchup isn't without its drawbacks, but any tool that works is a tool worth having, especially if its free. 


Monday, July 1, 2013

Computer Break Down and Ouya Review

On Wednesday I turned my workstation on, several capacitors exploded like fire crackers, and smoke came out of my computer. A quick run on my PSU tester made it clear that the PSU was, in fact, dead. So, while I was waiting for my new one to arrive, I decided to give the Ouya a go.

NO CONNECTION TROUBLESHOOTING:

Let me put this here, for those of you (and there are many) who are suffering from this problem on your Ouya. This will help you resolve the problem and get you up and running:

1) connect to a wired LAN with internet access (this MIGHT work with a wlan, but it's unlikely. The first update breaks android's ability to retain wireless network data, including the password, IP, MAC, etc).

2) Go to Manage>Advanced>System and then go down to Backup and Recovery. From here, select factory reset. Repeat this process about 20 - 30 times, or until the Ouya boots to the main menu.

If you're stuck in network configuration, you'll need to press Y on ethernet (most likely ETH0) to enter network settings. From there, press Up and O get to system settings and press down until you highlight Backup and Recovery. Do a full system restore.

Repeat this process until you make it to the main menu/account creation. 


Anyway, on to the review.

I'll start off by saying I'm not a founder, nor have I been following the Ouya development very closely. As you know (if you've read my blog) I do 3d work and Android programming, so that was the extent of my interest with the Ouya. Well, that an XBMC, but we'll get to that in a moment. 

I ordered my Ouya on June 18th, knowing it would ship on the 25th. I have Amazon prime, so I figured I'd get it on the 27th with free 2 day shipping. Well, not so fast. Apparently the Ouya was either very popular or very limited, because Amazon went from pre-order to sold out on the 25th. However, I recieved notice that I would receive the Ouya that Friday (only 5 days late). In Amazon's defense, they did bump up to free next day shipping. I can't imagine they actually made any money off my order, so I can't really complain about the service.

The Ouya came in good condition and has interesting packaging, though they underplayed the fact that it's also a developer kit and is also compatible with PS3 controllers. Those of you who already have a few of those controllers don't need to spend anything extra to start your party games.

The Good
At only $99, and sporting a quad core tegra, the Ouya makes an excellent home theater PC. It does have problems with very large files (4 gig blue ray rips, for example), but hopefully that will be resolved soon. If you have a media server like me, and you want a small, inconspicuous box to stream media on the cheap, the Ouya does a passable job. 

There are currently just over 200 games available for download, and you can try all of them for free. The quality of the demo ranges from one level, to a good portion of the game depending on what that specific developer chooses to give you. The games are also pretty cheap, topping out around $15 for larger games like Final Fantasy 3, and as low as $3 for some of the basic Android ports. The games are currently very retro and abstract heavy, with only a handful of what I would consider polished games, but there are definitely about half a dozen gems in the lot, such as Bomb Squad and Flashout (a clone of Wipeout XL).

The controller is solid and feels medium-well built. It has a touch pad in the middle, which is just as frustrating as it is essential for using the system. It is a cross between the xbox and PS3 controller, and I'm told it had some problems early on with the O button sticking. That appears to have been fixed for the final release, as mine didn't have any problems at all. The controller is mostly comfortable, but I don't like the top bumpers. It also lacks select and start buttons, which can cause problems for PS1 games. My last pet peeve is that the same button that pauses many games is also used to quit out of them if held slightly longer.

Finally, the box is very small and compact, needing only a power cable and HDMI cable to work, though you'll want to use the wired LAN port for now.

The Bad
As much as I like the value and performance, the Ouya fails in a lot of critical areas. For one, the day one patch kills the Android network service and is a brick wall for 98% of the people who buy it. The fix requires an wired connection and a bit of patience. The company essentially blocked almost all its new customers, and required factory resets for everyone with an existing configuration.

It took me about an hour to figure out the solution, which basically involves factory resetting the Ouya 20 - 30 times, which effectively finishes the update in small increments between network failures.

The next problem is that XBMC and Emulators do not work out of the box as Ouya led everyone to believe. XBMC needs to be downloaded and manually installed through the built-in web browser using the atrocious touch pad and (I hope you have one) a compatible tablet or usb/bluetooth keyboard. Once installed, it takes further configuring to optimize it for Android, and you should expect to set aside about an hour to complete the task. Oh, and yes, you heard me right. More on that in a moment. Emulators, one of the biggest draws for me, do not come with any roms (I was hoping I could buy them from the Ouya store). Instead, you have to load them on a flash drive and plug it into the only USB port on the Ouya. But the Ouya won't access attached storage unless you sideload a terminal and reconfigure the linux mount permissions (facepalm). So, the 2 things that would make you want to buy this for your parents/grandparents require complex work arounds and googlefu or linux skills.

Speaking of linux skills, the Ouya just uses a custom Android overlay that isn't complete. This means in many areas, even games (!), you need a keyboard. For example, Final Fantasy 3 takes you to an Android text screen so you can type in the characters name. Now, it's fine if you never want to change their names, but to do so requires a tablet with Blue Board or the USB/Bluetooth keyboard. In fact, there are so many areas that break you back out into the native Android OS that you'll wonder why they didn't just use Android without any custom UI. Want to uninstall a game? You'll have to go into the Android System (yes, exactly the same as your phone/tablet), go to Applications, then uninstall the game just the same as if it were on your phone.

Now, some people may be asking "So, what's the big deal with that?" Well, the idea behind this console is that it was supposed to be easy and accessible. If people wanted to play on their phone, they would do it - they wouldn't spend another $99 to do the same exact thing. This makes it great to give to your kids before the giant consoles hit with their $300 and $400 price tags - except for the biggest problem of all:

You need a valid credit card before you even get to the menu.

Yup, you have to front them your credit information to even get past the welcome screen. This may well be the idea that killed the Ouya. Why would I give this kids, knowing it has my credit card pre-loaded and ready to buy all 200+ games? The NES emulator (the only one that comes with a range of old nintendo games) works on microtransactions. Yes, it has parental controls, but it doesn't say that anywhere on the box. As a parent, I would be deeply concerned about junior maxing out my card to buy extra lives on Castlevania.

Finally, it's case was very poorly thought out and designed. First, it's mostly aluminum with plastic and it has an internal antenna. As you might expect, the wifi performance is basically unusable unless you remove the chip and lie it on the counter. The second issue is that there is no airflow, so it gets far too hot. The small 40mm fan they have cooling it does not bring any cool air in, or vent any hot exhaust. It just keeps pushing the same hot air over the burning chipset.

There is already an aftermarket brewing for 3d printed cases made of plastic with vent holes.

Bottom Line
It's not a bad system overall. It lacks any games that make it a "must have," but it's a good $99 time killer while you wait for a major console to release. It's not user friendly enough or suitable for kids or your grand parents and requires prior knowledge of Android to fully use.

Honestly, I wanted to develop games for it, but right now I'm on the fence. As with any developer, I don't want to waste time on a system that will attract little or no audience with purchasing power.


Saturday, May 18, 2013

Galaxia Game Part 1 of ??

So, been working on the game for over 18 hours straight now. I'm a little loopy, but ecstatic that I completed the first of many complex problems in the code. Basically, the game can now automatically assign weapons to hard points on the aircraft. It's not pulling weapons from user accounts yet (database work hasn't hit full swing yet). We are tentatively calling it Galaxia, and it will have a story with interlocked missions, and a lot of content.

I'm not quite ready to spill the beans on everything, but here are a couple VERY early shots (can't stress early enough, this is pre-alpha and prototype models):



Overall, I'm happy with the progress of the game. It will remain open for testing until the login and backend is completed, at which time it will enter internal alpha. You'll be able to continue playing the old version though.

You can still give it a spin at The currently hosted site

Sunday, May 12, 2013

Galaga For the 21st Century

Remember that old game Galaga? Sequel to Galaxia and grandson of Space Invaders? I'm building a game somewhat along those lines, but much improved over the old barcade game of yesteryear. How so, you ask? Well, I'll not divulge all the secrets, but stay tuned for an interesting link.

Creating models for 3d games is much more involved than 3d printing, but in some cases much easier. The difference lies in the detail of the 3d geometry. Rendering geometry in real time is very expensive for games (hardware wise). Increasing the poly count (polygons are a unit of detail used to measure models in many 3d applications) requires more video processing and memory. Moving those extra polygons requires exponentially more calculations as well.

To alleviate this problem, meshes for games are actually rather bland. Instead of using detailed geometry, a process called normal mapping is used, wherein a special texture is created that simulates light reflection. The surface of an object is detailed by how light is reflected (or not) off of the material. When the RGBA texture is placed over the normal map, you get color with simulated light reflection, which tricks your eyes into thinking there is much more geometry than actually exists.

3d printing, however, cannot benefit from this. If your mesh is not detailed, then the printed product will be equally bland. Thus, a lot of care must be taken when producing a model so that it's aesthetically pleasing without overwhelming the ability of the printer. As time goes on, I imagine 3d printers may have similar shortcuts to producing high quality textures without manually producing all of the geometry.

Here is a good example of a printable model vs a game model:

This is a detailed and printable Leopard Class Dropship from Mechwarrior (though admittedly I originally designed it for use as an icon).

This is a low poly model for a mobile game that I'm developing. It currently has no diffuse or normal mapping, just ETC1 texturing (that's right, not even RGBA!). This saves system resources to display additional objects on screen, apply physics, explosions, etc.

You can get a sneak peak at a very, very early build. This is pre-alpha stuff, and it's still missing 97% of the game. But most of the core mechanics are in: Space Game! Note that you'll need to install the small unity web player. I'm sure I'll update the game a few times as I complete the core mechanics.