Wednesday, February 20, 2013

3rd Sprint

AUDIO CONTROLER/LOADER/MANAGER
I am doing some research on controlling and managing audio in XNA game. XACT may be answer to this, looking into this tutorial.
More cool tutorials from RB Whitaker's Wiki.

SHADOWS
Our game doesn't have a shadow effect. The answer may be using High Level Shader Language (HLSL). I found this HLSL Riemer's XNA tutorial

ENTITY IN GAME DEVELOPMENT
I was trying to get a grasp of what entity framework is and I found this excellent tutorial What is an entity system framework for game development? from Richard Lord. It suddenly made it clear and I just remembered problems I had when using inheritance and trying to fit movable, collidable, but not drawable  object (as invisible trap or force field) into the game loop.

CREDITS SCREEN - POLISHED
I was working on credits screen again. This shows the idea of static background and flip-able pages for intro with the title and each team member with some image and about me info.


Saturday, February 9, 2013

2nd Sprint

CREDITS SCREEN
Working on the second sprint. I was given a task to create a credits screen. The credits should have both text and images and player should be able to scroll by using controller. I also think it is a good idea to start the scrolling down automatically or after certain time interval when idle. I am going through some text rendering tutorials. I am also hoping to build it as one of the game states and be one of the clickable options on the intro screen.

IMPLEMENTATION
I built Timer class that is driven by the Update method, every team member has his own page, this is taken care of by the Page class, all is tied up inside the CreditsScreen class. I was not able to reset XUI effects like  that I was planning for pages to have fade in/out transitions. I just declared another Timer object that scrolls page up/down for a half a second and then it flips up/down the page. There was a problem that if you hold thumb-stick it will just start flipping pages too fast. I timed flipping with another Timer object that even if you hold thumb-stick it will flip pages only like every half a second.

Here is the screen recording of the credits page. If you don't touch the thumbstick up/down it will scroll up automaticaly after 5 seconds. If you move thumbstick up or down it will start flipping pages with slide in/out effect. All images and texts are just place holders and need to be updated with the actual stuff.


Random thoughts about Unity and BPEUPhysics

UNITY
Unity is cool! I created some quick tests and put it online here:
I wonder if Unity can be used with lipsync avatars, this may require more testing. There are almost endless possibilities in use of Unity in serious gaming. It can be used to set up 3D scenes and take snapshots, this would be useful for creating static e-Learning scenarios. More use would be to use lip-synced avatars to replace live e-Learning presenters or to shoot educational machinima movies. No need for time consuming green-screen video recording with live people or going to and setting up shooting locations. Another ultimate use of Unity in e-Learning would be to build 3D or 2D teaching games, but this would probably require to change the corporate thinking about employees playing games at work.

Here is cool demo from Unity 4 DirectX11 contest.

BPEUPhysics
I tested this free open source physics library on both PC and Xbox and I was surprised with its ease of use. For our Ninja game I was asked to add some way to register when the collision ended. The idea is that when the player stays too long inside some room (or 3D object like building) some help message with instruction would pop up every minute or two. Once the player successfully leaves the area this popup messaging would stop. I came up with adding this CollisionEnded event

public void AddCollisionHandler(InitialCollisionDetectedEventHandler<EntityCollidable> h, CollisionEndedEventHandler<EntityCollidable> g = null )
{
            Body.CollisionInformation.Events.InitialCollisionDetected += h;
            // registering the collision end
            if (g != null)
                Body.CollisionInformation.Events.CollisionEnded += g;
}

This was not tested yet but it should fire up CollisionEndedEventHandler once the PhysicsBody entity would leave the EntityCollidable entity bounding box.