Monday, 30 April 2012

Dream.Build.Play: Keeping It Fresh

This week saw a version of the introduction sequence being completed. However, as I don't own any video recording equipment and a screenshot wouldn't really show anything, you'll just have to take my word for it. It also saw the completion of two components that will help to make every game different to the last one.

The first of these components is my camera director. Whenever you watch a television based game show they very rarely have the same camera angles frame by frame between shows. This is usally because a different director is probably directing each show. In order to replicate this, I have created a camera direction system which takes a collection of camera angles from an Xml document which can be used throughout the show. Throughout gameplay I can then ask the camera director for a camera angle, for which it will randomly pick one and use it when drawing other objects. However, just obtaining a random camera angle wouldn't be very good as I may want to look at the contestants and instead get an angle showing the audience. To avoid this each camera angle is associated with one or more camera categories (e.g. audience). This results in me requesting a category and being given a random angle within said category. The first place this is used is in the show introduction where it will show the audience at the beginning. Although this addition will proabably go unnoticed to the average player, I'm hoping it will help keep things fresh.

The second component is a similar component to keep things fresh, but is associated with the game's host and the things that come out of his mouth. In the game, the game show's host will introduce the show, explain the rules of each round, compliment/insult the participating contestants depending on their progress and sign off the show. In order to keep things fresh again (I already hate how much I'm using that term) by having different introductions, different insults, etc, a similar component with a similar structure (audio clips associated with a given voice category) has been created. I can then ask said component for a given category of voice overs and I will get a random audio clip every time. This component then links to a more generic component that plays the audio clip and moves the hosts mouth to give the illusion that he is talking. I'm hoping that the combination of these two components, along with future features, will help keep the experience different game after game.

This week also saw me attempting to test the online code in preparation for the week ahead's tasks, but unfortunately I'm unable to test the code due to my PC version (used for testing) <techtalk>causing InvalidOperationExceptions</techtalk> <non-techtalk>breaking</non-techtalk> whenever a new online session is created. At the moment I'm creating online code hoping it will work and will then do a playtest nearer to the deadline. If however I can't fix my PC build or the playtest shows my online code just doesn't work, I will have to leave online play out of my submission which will be very dissapointing.

So what's next? This week I will be implementing the first (of many) rounds for my game show. This means that the actual gameplay is now actually being implemented. Not bad when I have 6 weeks left...

Monday, 23 April 2012

Dream.Build.Play: An Audience To Remember

Two weeks have passed since my last entry. As you may have known (if you read said post) I had been on holiday, and therefore work on my dream build play project hadn't happened for a long time. Last week I returned, and therefore a week of progress should have occurred. Unfortunately this wasn't the case as I got back into playing games every day which resulted in me buying a PS3, playing Uncharted and finally completing Mass Effect 3; the ending to which wasn't as bad as the internet had made out, but still wasn't brilliant.

However at the end of the week I did make some progress on the game. I started looking at the environment that the player will be spending the majority of their time in. This led to me to start designing it and I ended up building the core structures.

As you may have realised with both this image and images shown in previous posts, my game will have a game show style. This is because my game is a trivia based game, with a selection of rounds designed and ready to be implemented. The image you see above is audience that will be watching the player(s) play the game show who will hopefully applaud and cheer during the game. The image does showcase however the limitation I have when design things around the Xbox avatars as all have to be designed around a limited animation pack that is provided by the AppHub. For those that don't know why, this is because custom animations can only be created in expensive bits of software (see Maya and 3DS Max).

The player you see at the top of the stairs is the host of the game and will introduce the show and provide quips throughout it. As this guy will probably be voiced by me, there will be a feature to turn him off.

The reason for the host being at the top of the stairs is because he will walk down and onto the stage (pictured above) before he introduces the show. I'm really wanting to capture every moment of a game show you would see on television and this goes down to the little details.

So that's the progress I've made so far. The next stage is to get the host to actually reach the stage and to get avatar voice work implemented. Only seven weeks to go, so I better get a move on.

Saturday, 7 April 2012

Dream.Build.Play: Trying to Connect the World

This week I have been contemplating whether to start implementing online play into the game or if I should wait until further in the development to start implementing it. After reading various posts on my phone on a very long train ride over the weekend, it was recommended that it would be easier to implement online play from the beginning instead of shoe-horning it in further in the development cycle. So over the week I have designed and developed a generic solution for wrapping XNA's network session to help with the sending and reading of online based packets. It was also recommended that the same code base should exist for both on and offline gameplay. However, this possed a problem with what I wanted to implement.

My idea was to have players drop in and out of the online "lobby". This is fine as when players join the network session they are added to an accessable collection. However my idea was to have a number of players on the same console the ability to join a given online session, so online play could consist of a mixture of remote and local players. This is fine when players want to join a session on a given console, as a method for adding local players exists. But what happens if that said player then decides they don't want to play? This wouldn't be a problem if a RemoveLocalPlayer method existed, but it doesn't. Local play is fine as there is only ever going to be local players (maximum of 4 in the session and maximum of 4 on a console), so I can look at other variables to determine which players are actually "active" in the session. But for an online game I can't leave that now gone local player attached to the session because this will stop new players from being able to join, as according to NetworkSession it has the maximum number of players. The reasoning behind this needed method not existing according to shawn was because of only two scenarios existing for a player leaving. He says usually either a single player wants to leave so they sign out (which NetworkSession then removes said player from the session), or all parties on the console want to leave and hense they destroy their session. Becuse of this limitation I have had to come up with a disjointed solution between offline and online play. In the offline scenario players can join and leave as they please with their presence still being attached to the session. This is fine as I have other means to determine active players. In online play, when a player attempts to leave they will be greeted with a message saying that they need to sign out in order to leave. NetworkSession will then deal with this and remove the local player freeing up space for other players to join. Yuck!

Having online and offline play joined by a single code base has also lead me to another design choice. In the beginning I wanted players to be able to join a game without having to sign in. Unfortuantely in order for a player to join a NetworkSession, that said player must be signed into a profile (local or live enabled). So now my game requires the player to sign into any profile for offline play and a live enabled profile (even if it's as a guest) for online play. On the plus side I have still managed to keep the ability for players to choose a random avatar if their own avatar is really that bad :)

So that's what progress has been made this week. No new screenshots unfortunately as it all looks pretty much the same as last week. Also, no further progress will be made this week as I'm away from my computer for the Easter holidays. Hope you all have a good Easter.

Monday, 2 April 2012

April Fools Without the Fool

April Fools Day. A day filled with press releases and videos bringing dreadful (and sometimes hopeful) anouncements in the gaming technology industry. In a day full of fake announcements and practical jokes I executed the primary purpose of my platformer game.

Around the beginning of last summer I had been with my girlfriend for just over four years. We had just moved in together after we had spent the majority of those four years apart maintaining a long distance relationship due to attending different universities. I knew what I wanted and I knew I wanted to ask her that very special question in a special unique way. I wanted it to have my stamp of "geek" on it. I had some big ideas; many of which were out of my league of ability. So I settled on building a platformer and started some work on it in the summer. At the time of starting I didn't really know what I was going to do with the game, just that it would be involved in some way. PAX then came around and another developer had a similar idea. To be honest I was miffed. I no longer had that, what I considered, unique idea.

Months passed, and I had abandoned development on my platformer and was desperately trying to think of another idea that was equally "me". But for everything I came up with, it just wasn't as good as my original idea. In the end I decided to carry on developing the platformer, but I still didn't really have an idea of what I was going to do with it. The only thing I really knew I wanted to do was have the level that she would play spell out the question that was on my mind.

However, one day I thought of the old saying "It's not the destination that matters, but the journey" (I'm probably paraphrasing). Eureka! What if the end of the level isn't the question, but the level itself is. So I started work on building the items I needed to pull it off. I wanted sign posts that could say the words that I would inevitably mess up. I wanted collectables that represented key elements of our relationship. I wanted her to be in the game and for me to be there at the end. It was all in there, and I still got those words at the end that I knew had to be present all along...

Yesterday, she played this level. It was painful to watch if I'm honest because I didn't know how she would react to the game. It was positive and the response I receieved was what I was hoping for. For once there were no fools present on this day.

All in the little details...

As mentioned in my Dream Build Play entry update the past week I wanted to put a few more touches on my platformer before I put my focus on my entry in order to have it be something I would be proud to submit. As I've been adding new elements to my game I've been noticing more and more of a little detail that has been missing. I've put it off for as long as possible, but wanted to get the foundations added before I started anything new. I'm talking of course about the background of the levels.

This past week I have been working on two upgrades. The first is a scalable background where I can shift the background between day and night time scenes as shown in the above screenshots. Me in my little bubble thinks that this a) makes the game more polished and b) results in levels that can hopefully be even more varied in the scenery. I'm hoping to include a sun and moon that will shift approriately with the background as well.

The second thing I added is the formation of clouds. These clouds shift from one side to another and have been set up so I can vary the density and speed on a level basis. Obviously this addition is more appealing in motion.

Obviously these additions will help make the game more polished in the long run, but why was I in a hurry to get them implemented this week when other things that would be more beneficial are still outstanding (like a menu system). Well, the answer to that deserves a post of its own...