Niels Vaes: Getting Gerrit Into Gear

 

So I’ve been working on the main character for the new game. I’ve been busy with it the last week and a half and it has been an absolute blast. It also has been an absolute pain in the ass from time to time, but I guess that comes with the territory.

The main problem I –and I’m pretty sure Tom too- had with animating Gerrit was the fact that the character was not set up with an IK rig. The reason it didn’t have an IK rig was because, unfortunately, IK doesn’t work in Unity (although the animation support in Unity 4 looks promising). That left the guys with 2 options:

  1. Just work with forward kinematics for everything, legs and feet included.

OR

  1. Build an IK rig, bake the animation in Maya and get it into Unity.

Both options work, both options have drawbacks.

The biggest drawback for just using FK is: animating a character that has to walk, crouch, jump anything like that, is very tedious. Trying to keep the floor contact poses correct is almost impossible. Moving the root means moving the entire hierarchy, which means those pesky little feet are never going to stay where they should be. Flailing legs in the air is no problem, but apart from some very specific animations that’s not going to happen a whole lot.

Baking an animation works just fine, as long as you optimize the baking process and don’t export anything more than is necessary. Now, I’m not the leading expert on animation baking or exporting animations from Maya to Unity, but I got the feeling that things weren’t as optimized in this department as in the rest of the production. So I took it upon myself to see if I could smooth out all the kinks in this part of the pipeline.

And what’s the best way to get stuff done easily in Maya? Yup, back to MEL it was. I did a little bit of MEL scripting a LOOOOOOOOOOOONG time ago and never anything terribly complicated. Luckily for me, creating a script to get this working wasn’t complicated at all. Because basically, I didn’t have to create anything that wasn’t already built into Maya. It was just a matter of combining MEL commands and doing some basic checks. More on that later.

The first thing I had to do was to inspect Tom’s file closely and fix any errors that happened when the joints were mirrored. Maya sometimes throws little monkey wrenches in your operations, so you might end up with colorful names, such as “joint25”, “joint28” and “Left_WristJoint02” on the right side of your character.

Kevin has been making the levels and requires that everything has a strict naming convention. It makes his life easier if he doesn’t have to hunt for every file. Hell, Twan even made a Python script for Maya to make sure every file has the correct name (among other things). And being the “Nazi” I am (not a real one, don’t kill me), I’m pretty strict on naming everything correctly in Maya (usually).

I started on the IK controls when the skeleton was named correctly. These didn’t have to be super-duper-Pixar-eat-your-heart-out controls because the Gerrit model is only around 1800 polygons. Just normal IK controls in both legs were all we needed. I set up a foot roll and a toe flop to help with walking/running animations. Gerrit has long ears which flop around while he’s doing stuff, I’m pretty sure his two little toes do the same thing.

This Gerrit rig is way more animator-friendly in my humble opinion. I didn’t change much on the rest of the body, other than adding a control to both hands to make a fist. Having to rotate the digits every time is a pain in the ass. Especially if you want to make a fist. AND, on top of that, you have to keep an eye on 3 animation curves instead of just a single one from the Fist attribute.

Which brings me to the next little irk I had (and unfortunately, still have) with the current Gerrit setup. I suspect that at one point in time, the local rotation axes for all joints were reset. Other than trying to manually rotate them all, I don’t think there’s a way to get them back to their “normal” orientation. Normal as in pointing down the hierarchy. And I don’t even know if doing it manually is still possible after the character has been skinned.

There probably is a way, but we can work around this little problem. The only thing we have to keep in mind is that, in order to bend the elbow joint for example, we have to rotate that joint using all 3 axes. It looks a little messy in the graph editor, but it’s not going to kill anyone soon.

I also played around with a spline IK setup for the ears, but because there are only 3 joints and not a whole lot of deformation possibilities, I omitted it and just stayed with standard FK joints.

Personally, if I don’t make a whole lot of controls available for myself (or anyone else who’s animating) in the Maya scene itself, I tend to have some quick controls available through some sort of interface. It really depends on the animator (and the mood he’s in) whether these controls are useful or not. I tend to ping pong between using them and just rotating joints. If I’m working on the firefly character, I find them very useful.

Seeing as Gerrit now has IK controls that have to play nice in Unity, I decided to write a controller/exporter script. The script makes sure than no unnecessary information is being exported out of Maya. We’re developing for iPad, stuff needs to be small and compact or Robin will get a heart attack :)

The way old Gerrit was set up added overhead to exporting him out. All extras on the character (eyelids, hair, leaves and clothes) were parented to the skeleton. This works fine, but it also means it’s exported with every animation. I don’t know for sure how Unity handles this, but all geometry is already on the main character in it’s T-pose. There’s really no need to have each and every FBX animation file to have geometry in it. It’s the skeleton we’re interested in, nothing else. So, with file size in mind, I just parent constrained all geometry to the joints. Nothing changes on the outside in Maya, but the skeleton is not bringing any excess geometry along for the ride when exported.

Hoooooooooowever. We DO need all geometry in Unity to be there and move properly, so 2 different FBX are needed. One file with no animation and one with the extra geometry parented to the joints. This is the standard Gerrit file to bring into Unity. It has all geometry + the skeleton. All other files exported from Maya don’t have any geometry in them. They just animate the existing geometry in Unity.

Makes sense?

It might be a bit of a hassle to set up, but it only needs to be done one time for the entire project. I have to talk to the guys on Monday (blogging on a Saturday, w00t) in order to see if anything needs to be changed for the Gerrit project in Unity.

All existing FBX files also need inspection because they might be exported with the incorrect naming convention. If the standard Gerrit file in Unity has joint names like Right_WirstJoint01 and the old FBX file has Left_WristJoint02 instead, the animation is going to look wonky in Unity.

On a side note, this happened to me last night. I made the animation of Gerrit falling over in Maya. I then exported that animation out using my script to see if it worked in Unity. It did work, expect the right hand wasn’t moving and neither were his fingers. It was late and I already spent the better part of the evening staring at my computer monitor, so I decided to take a look at it in the morning. Then the most freaking amazing thing ever happened. I actually dreamt about this problem and in my dream I realized the naming conventions didn’t match. When I woke up this morning I immediately checked the naming convention in Unity and voila! I found the reason why the hands weren’t moving.

Anyhoo, back to the main story. This is the script I made for our blue little fella:

As you can see, not all that complicated, but it does some clever selecting and combining of Maya stuff to get everything exported out the way it should be. Like I said earlier, most of what this interface does can be done manually in Maya, but clicking once or clicking 18 times makes all the difference in the world. Doesn’t it?

The top controls are used for selecting various parts and the entire hierarchy + all the controllers. I’ll probably change this a couple more times depending on how which buttons I use/need the most.

The Specific Attributes are used to control the foot rolls, toe flops and fisting making fists.

The Animation Baking buttons are used for… yup, baking the animation. When the animation is baked, the script cleans up all unnecessary curves and keyframes automagically.

The Export buttons are used for exporting, or baking and exporting. Usually “Bake and export”is the button I use. Unless I have some very specific reason to do it separately, this button is the one click solution to get everything exported correctly. “Export only”exports whatever is selected. When that button is used, I have to make sure that my selection is 100% correct. I usually only use this when I want to export a specific part. That “Undo bake”button is actually just an undo command.

Side note:

You’d think this can be added in the “proc BakeAndExport()”, but you’d be sadly mistaken. For reasons unknown to me at the moment, undoing from within that procedure undoes the hierarchy selection, not the baking process. I’ve tried just about everything to get the undo to work automatically, but it doesn’t want to play nice. I’m sure there’s a good reason why it’s not working, anyone who has the answer is more than welcome to let me know :)  I usually test drive my animations several times in Unity when I’m working in Maya, so I always undo the baking process. The baked animation is saved to a different (FBX) file anyway, so no need to keep it in the Maya binary.

The last 4 buttons are general animation tools I use. These are things from the Graph editor, but I added them in here because they’re just one click away now.

I added the functionality to make the window dockable anywhere in Maya. This means that when I can’t steal Robin’s extra screen, everything fits nicely on one single screen.

City hall 3D visualisation

Our latest project is finished, we only had 8 workdays to get it done and we did it!

The ground floor of the city hall of Genk is being renovated and they wanted a virtual version of this to show to the public. LuGus studios accepted the task. It was quite a challenge to create this 2700m² 3D visualization in a this short time. Luckily with our 7 men team, the help of the great people of Genk and the power of Unity we managed to get it done in time and delivered more than we expected. It was an interesting project, fun to work on and we learned a lot.

We got a lot of documentation and decorated our studio walls with the architect’s plans which we got from the city. We started by studying these plans, as there were quite a few of them.  Ofcourse we also visited the construction site to get a feel of the space we where creating and to collect some texture material by photographing every interesting detail we could find.

 

We also divided the work and looked into all kinds of little problems that might occur like the different scales, etc.  It’s important to work consistent this way when 5 people are creating assets for the same project. While Kevin managed the project, the whole team had his responsibilities and sacrificed a lot of free time to meet the deadline. Everyone worked on the different 3D assets, using the same texture pack to stay consistent in material use and feel. Furthermore, large parts of the level, like the ceiling, where generated in one piece using the plans as a base. A lot of experimenting and planning went ahead but we ended up with a nice workflow and a great combination of techniques to get us the best result in the shortest amount of time.

While the use of Unity limited us in a couple of ways, mainly visual limitations compared to 3D render engines, we are still more than happy with our choice to use this engine for the visualization. It’s very user-friendly and quick to work in and of course our visualization is full interactive. People can walk around in it for the first time, months before they can do so in real life. This is especially great for people who worked on the project for months but have only seen the plans and the individual parts of it.
After the delivery the visualization was shown in the city hall to the public, the reactions where great! It helped people imagine what the real thing will look like, mission accomplished!

 

Twan: Pitching my own project

I really like the atmosphere at LuGus, communicating with my new colleagues is just like talking to my peers at school. We all understand the inside jokes and the culture references. It’s a software developers mind set which seems to be international. It is nice to learn this way and also neat to teach things. Which is also a part of doing an internship. Because LuGus is a young studio, I think the knowledge I gained at school can be useful, rather than made obsolete by studio traditions.

I am a bit of a technical artist, It is great to know things of all sides of software development: design, asset creation and programming, helping artists where they run into problems and helping with simple pieces of code so the programmers can focus on the more difficult ones. Some simple scripts to enhance the atmosphere are more time efficient to be carried out by a technical artists.

Currently LuGus is mainly working on project Alver and some smaller projects, which are not all related to serious games. LuGus also creates websites, augmented reality prototypes and other small applications. The team gave me the chance to pitch one of my own project as well.

Over the last week I worked on a prototype of my project, which I consider in its current state to be close to a demo. Doing some C# tutorials helped me to understand better what I was doing. In the time building up to the pitch the team gave me useful advice about doing presentations, while they did not see the prototype I was building yet. I tried to make showing the prototype during my pitch more impressive that way.

It was a prototype of an interactive story. A story which uses the input of the reader to develop. I have written the story a long time ago, but still wanted to create a digital version of the story, to make it easier to read. The project itself remains classified for now.

The presentation itself went ok, but after the presentation I realized it was not exactly what the team hoped to see. They liked what they saw, but thought that I could have better focused on the look and should have explained the story better, rather than spending most of my time on creating a technically sound prototype. I do agree with their points, but I am happy with the progress I made and the things I learned while creating the prototype. The team saw potential in the idea, but not really in its current form. The target group had to be better defined and I had to think about the other things on the market that would be similar. Nonetheless the team considered to use my work in a later stage of my internship.

 

 

Community feedback

We hope you like our latest tweets and the facebook and blogposts we’ve put up lately. We’ve enjoyed the feedback and reactions we get from our community! LuGus Studios is more than just about what we do at the studio, it’s also about the community around it.

That’s why we want to know from you, what you want to hear from us in the future.
Should we expand our community on Google+, by sending newsletters or by adding a  forum to our website?

How should we include you in all of this? By starting or supporting community projects, by doing events, contests or let people write on our blog?

Let us know!

Twan: Design and production

In the previous blog I covered my personal experience with gameplay design, asset creation and worldbuilding on a high level. This blog is more in-depth on the subject.

We are now working on project Alver, it’s an educational adventure game for iPad. Its main goal is to teach things to children, but in an engaging manner. The world of Alver is designed to be an immersive world, rather than a couple of bland tests for children to make.

I’ve put a lot of work into the puzzle design: first the lesson that needs to be taught needs to be decided, then the mechanics used to teach this lesson. With that foundation a back story or reasoning can be designed; a way to connect the lesson with the outside world. I will use one of my puzzles as an example here. In one of those puzzles the player has to bake cookies. The idea behind this is that players can learn how to sort, combine and put things in order. When learning this while baking cookies, that knowledge is directly applied to a real world scenario.

The gameplay design itself first starts as a text document, thinking out what the player has to do and iterate on that. It contains restrictions and a list of all the assets that are needed during production. A rough sketch is made, containing all the needed information for the  layout of the assets and the world building in unity3d. This sketch has to convey clear information, more than being a showcase of the artist’s abilities. This way others can work with it and review the design.

After the designing phase, the assets are created. The team decided that it would be best if I would go through all the stages of development myself. For the puzzle at the bakery I created a couple of assets. When making these assets, not only was it important to maintain quality and make sure they fit in with the rest of the game, but I also had to take in account reusability. Time can be saved later on, by creating efficient reusable models and/or textures, to be used in other environments of the game or even other applications. The amount of time it costs to create assets is often misjudged: there is no 50-50 split between modeling and texturing; In my experience it is more like 25-75. Creating the assets for one of those scenes took me about three days. The assets were relatively simple and none of them required animations.

After creating the assets, I assembled the environment for the puzzle. When creating environments for puzzles, the atmosphere must be interesting, but the puzzle must remain clear. The elements that are only decoration should not obscure the puzzle and the usable area of the screen should be as large as possible. The scene can then be made more interesting by adding lights and effects. This particular scene is designed to emulate nighttime: a warm-cold contrast was used to make the puzzle both more interesting and more clear to the player. Extra effects such as lighting, particles and sounds(for example cars passing by) also make the experience more rich. During the creation of the puzzle I had to take in account the technical requirements of the iPad, such as the resolution and performance characteristics.

 

Twan: First week as an intern

Hello, I am Twan, doing an internship at LuGus-Studios for 20 weeks. I am a student game development at the NHTV in Breda in the Netherlands. Over the course of my internship I will be doing regular blog posts. What follows is a couple of blogpost that give an overview of my first few weeks at the studio.

The first couple of days I got to play some kids games to get a feel for the target audience. It surely brought me some new perspectives to game development, playing Freddy Fish and Putt Putt games.

After that, the team let me design some puzzles for project Alver, the project the team is currently working on. Project Alver is an educational game on the iPad made with the Unity3D engine .  I designed three puzzles to use in the game. Design here meaning  the thought process, looking up references and creating the documentation to implement the actual puzzle later on.

It really helps to have an idea of what you are going to create during production, as it not only makes the production a lot easier, but it also saves a lot of time in the end. The sooner you can address issues in the design, the less work is wasted. That little extra work can save a lot of time and thus money in the end. For example the arrangement of objects can be decided upfront so only the objects that are actually needed are created. Additonally the detailing in each object can be extracted from this information when compared with the camera distance and size on screen.

After the designing phase, I got to actually create the needed assets for the puzzles. Modeling, UV-mapping and texturing. It was kind of nice to go through the whole process of conceiving ideas to the production  and finalizing them, as I built the environments  with the assets afterwards.

Even with a designing phase upfront, this does not mean you have to stick to it to the letter, while in the production phase the designing process continues and features can be slightly changed or extra features can be added: for example, in the initial design of the puzzles there was no lighting information yet. I still had to discover what effect the assets’ textures were on the lighting. Sometimes it is difficult to foresee the effects of a design decision. When a wrong choice in such occasion would result in a lot of wasted time, it is better to prototype the design. In this case I did not use a prototype as the risk factor was not really high.

In the next blog I will go into more depth of the stages of world creation.

 

Alvergast are back!

Image

Today we reveal the first in-game screenshots of our new educational game based on our Alvergast IP. While it based on our old project “Project Growth”, it’s a complete new educational game, made for iPad.

 

So far the project is called Project Alver, but we are looking for a nice name for the final product. Suggestions?

LuGus Web ?

Image

Dear LuGus fans

 

The “LuGus Web” image on our Facebook page was not an april fools joke, as some of you might think, it’s the real deal! Luckily it’s probably not what you thought it meant, we are not changing our business from game development to web development. ;)

 

 

Game development will always be the main focus of LuGus Studios, it’s our passion and it’s what we are good at! Still, we are very proud to announce that LuGus is expanding into the world of web development too! It’s what our customers have asked for and we’ve delivered some successful web products already!

 
 

What will LuGus Web deliver?

- Fully functional professional websites, for PC and Mobile platforms.
- 2D and 3D web-games using the powerful Unity game engine.
- Social network games and apps (facebook, google+).

 

So what about you?

As always, we are interested in partnerships with other game and web developers, so please contact us: info@lugus-studios.be

 

Furthermore we now accept multimedia and web development students for internships at LuGus Studios. You’ll get the chance to work with a fun and creative team on exciting web AND game projects (2D, UI design,…). Send your C.V. and portfolio to info@lugus-studios.be

 

 

European Sifteo Unboxing

For this very first LuGus Studios blogpost, we have something extra special for you! The Sifteo Cubes are extremely interesting new gadgets with tremendous possibilities for game design. In this first post, we show the box they come in and explain some of their features, as well as how to get them working in Europe. Coming posts will describe our experiences developing games with these nifty machines, so stay tuned!

About using the charger in Belgium (Europe)

As explained in the video above, the Sifteo cubes come with a charger that requires 120V input (as used in the North American power system). To use them in Belgium (Europe), we have 2 options. The first is to use a transformer (from 220V to 120V) and hook the original Sifteo adapter up to that (note: it has to be an actual transformer, not just an addon piece that offers a different outlet!). The second option is to use a completely different adapter that directly plugs into Belgian outlets and delivers the 5V DC output the Sifteo dock requires.

As it turns out, neither of the options is a clear winner. In this topic on the Sifteo forums, the company advises against using a different adapter and prefers the transformer approach. However, transformers seem notoriously difficult to find in online shops (and even hardware stores). In the same topic, other early adopters seemed to have good experiences with the adapter approach, so we decided to try it out. We got this adapter, following Jochen Derwae’s advice in the topic, and it works like a charm! (for readers close to Genk, Belgium, we got it at Bea Electronics).

As Jochen also points out, you need to take care with adapters that have multiple available output plugs.  Their polarity needs to be correct. As can be seen on the image below, the polarity of the Sifteo dock is from + to -. The image also shows the back of the adapter package, which clearly indicates the plug has to have the CEN side at the + end to get this desired polarity (attention: the adapter packaging might be confusing! the polarity is not just indicated by the position of + and – on the axis, but more so by the demi-circle in the middle and to which sign it’s open). So: check your adapter packaging to make sure you use the plug correctly.

Top left: Sifteo charger dock. Bottom: European charger box instructions. Top right: correct usage of European charger

After all that is done, plug the adapter into your dock, which should then show a white/grey light on the front. If that didn’t fry your house’s electrical systems (let’s hope!), you can try putting in a sifteo cube. If everything is still ok (and no smoke is coming from your sifteo dock :) ), you’re good to go!

Enjoy tinkering with the cubes and contact us at info@lugus-studios.be should you have any problems.