Archive for the ‘game development’ Category

cocos2d-guide2

Nov 28

A Compendious Guide On Creating A Simple iPhone Game Using Cocos 2D 2.X

The current trend of iPhone gaming apps has taken the gaming world by storm. Almost every iPhone app developer has tried his/her hands on developing a game. Thanks to the availability of highly effective iOS app development frameworks, it has become feasible for the developers to create simple yet fun 2D games targeted at iOS devices. Cocos 2D is a fantastic iOS framework that has worked wonders for developers looking to develop games for smartphones. The following is a simple guide on developing your first game using the Cocos 2D 2.X framework.

Step 1- Download and install Cocos2D

Firstly, you’ll need to download the Cocos2D framework from the official Cocos2D-iPhone home page here. On this page, you’ll be able to choose from different versions of the software program including: Cocos2D 1.X vs Cocos2D 2.x and the stable vs stable choices. In this post, I’ll be referring to the creation of a simple iPhone game using the most recent Cocos2D 2.X. Many companies offering iPhone application development services have already worked on building gaming apps using Cocos2D.

Step 2- Start with adding a sprite

Just in case… A sprite is basically a 2D image that can be rotated, moved, animated, scaled and so on. Prior to proceeding ahead with addition of a sprite, opt for gathering some good game art/graphics. After having downloaded the required resources, unzip the file and drag everything over the Resources folder available within the Xcode. With images ready-for-use, try and figure out where you’d be placing the player. In Cocos2D, choosing the landscape mode means that the upper right corner is (480, 320) and that the game would run on a 3.5” screen. In addition to this, you may also opt for the (568, 320) option which would denote that the game would run on a 4” screen.

Step 3- Open the HelloWorldLayer.m file and replace the existing init method with the following code:

– (id) init

{

if ((self = [super init])) {

CGSize winSize = [CCDirector sharedDirector].winSize;

CCSprite *player = [CCSprite spriteWithFile:@“player.png”];

player.position = ccp(player.contentSize.width/2, winSize.height/2);

[self addChild:player];

}

return self;

}

Step 4- Add moving monsters

On this step, you’ll add some monsters into the game’s scene for the ninja to combat. Here, it is important to make the monsters move. You can do this by simply creating the monsters slightly off screen towards the right side, followed by setting up an action for them, prompting them to move into the left direction. For all this, simply add the below mentioned method before the init method:

– (void) addMonster {

 

CCSprite * monster = [CCSprite spriteWithFile:@“monster.png”];

 

// Determine where to spawn the monster along the Y axis

CGSize winSize = [CCDirector sharedDirector].winSize;

int minY = monster.contentSize.height / 2;

int maxY = winSize.height – monster.contentSize.height/2;

int rangeY = maxY – minY;

int actualY = (arc4random() % rangeY) + minY;

 

// Create the monster slightly off-screen along the right edge,

// and along a random position along the Y axis as calculated above

monster.position = ccp(winSize.width + monster.contentSize.width/2, actualY);

[self addChild:monster];

 

// Determine speed of the monster

int minDuration = 2.0;

int maxDuration = 4.0;

int rangeDuration = maxDuration – minDuration;

int actualDuration = (arc4random() % rangeDuration) + minDuration;

 

// Create the actions

CCMoveTo * actionMove = [CCMoveTo actionWithDuration:actualDuration

position:ccp(-monster.contentSize.width/2, actualY)];

CCCallBlockN * actionMoveDone = [CCCallBlockN actionWithBlock:^(CCNode *node) {

[node removeFromParentAndCleanup:YES];

}];

[monster runAction:[CCSequence actions:actionMove, actionMoveDone, nil]];

 

}

Step 5- Setting the background and logo

With Cocos2D came the concept of ‘scenes’. Each scene within the game can be effectively used for incorporating levels, menus, credits and a variety of other assets that collaboratively work as the backbone of the iPhone game. Within each scene, you can choose to include several Photoshop designs that can have separate properties including animations, background color, a shadow and even menus.

Step 6-Giving the finishing touches

Now that you’re pretty much close to having a workable game, it’s time to add some sound effects and music to your game. For this, you can add the following import to the top of your HelloWorldLayer.m file:

#import “SimpleAudioEngine.h

Also, in the init method, add the code for the background music as shown below:

[[SimpleAudioEngine sharedEngine] playBackgroundMusic:@“background-music-aac.caf”];

Lastly, for the sound effects, add the below code snippet in your ccTouchesEnded method:

[[SimpleAudioEngine sharedEngine] playEffect:@“pew-pew-lei.caf”];

Finally, create a new file using the iOS\cocos2d ve.x\CCNode class template followed by making it a subclass of CCLayerColor and clicking the “Next” button. Now, name this class as GameOverLayer and click on the ‘Create’ button. Replace the GameOverLayer.h file with the following code:

 

#import “cocos2d.h

@interface GameOverLayer : CCLayerColor

 

+(CCScene *) sceneWithWon:(BOOL)won;

– (id)initWithWon:(BOOL)won;

 

@end

Lastly, replace the GameOverLayer.m

#import “GameOverLayer.h

#import “HelloWorldLayer.h

 

@implementation GameOverLayer

 

+(CCScene *) sceneWithWon:(BOOL)won {

CCScene *scene = [CCScene node];

GameOverLayer *layer = [[[GameOverLayer alloc] initWithWon:won] autorelease];

[scene addChild: layer];

return scene;

}

 

– (id)initWithWon:(BOOL)won {

-­————————————– for more, please refer to Google.

Wrapping Up

There you have it, all the basic steps that need to create an iPhone game using the very cool Cocos iOS framework. I hope the above guide has encouraged you to keep learning more about Cocos2D 2.X and its varied appealing advantages.

marvel-slots

Aug 18

What Marvel Slots Can Teach Us About Game Design

Superhero movies have been big business for a long time. Every year we see an array of characters from the iconic Spiderman to the unknown (until recently) Rocket Raccoon. Sadly, when it comes to superhero movie tie-in video games then the quality quickly diminishes. Gone are the days of the Commodore 64 and Amiga when games such as Robocop, Batman and The Amazing Spiderman topped the game charts. Nowadays, video games from superhero movies are usually met with a groan.

One area of the games market that has really nailed the Superhero tie-in is the gambling market. The Marvel Video Slots have never been so popular. Over the past five years Playtech have pushed Superhero games far beyond that of its Crytologic predecessor (who’s licensing agreement ran out earlier this year). Since Playtech took up the Marvel mantle they have created a myriad of games that include Iron Man 2, Thor, as well as the 50 pay line version of Hulk, Iron Man 2 and Fantastic 4.

What Are They Doing Right?

The beauty of the slot machine game is that the core mechanic is simple and clear. Players instantly know that the aim of the game is to spin the lines to earn the rewards. In most cases it’s a 5 reel and 25 paylines slot that offers the player nice gameplay along with lots of fantastic features. What Playtech have done is taken key moments of the films and boiled them down into short bursts of activity as you progress through the game, on your journey to the big jackpot (and they are big!). By activating bonus games the player is whisked away to a short mini-game that mirrors parts of the movie before retiring the player back to the game at hand.

The idea of concentrating on the core gameplay and building ‘modifiers’ to expand the gameplay is a lesson all developers should take heed of. It is easy for developers to want to crowbar in a number of features and mechanics but this practice can actually detract from the main game. By focusing on a core gameplay mechanic you create familiarity and a sense of comfort within the player. From that comfort, you can then take the player to new places to explore the world, and then return them back to the main game to regroup.

The recent ‘Watch_Dogs’ game is a great example of a game that despite having an array of great ideas, the sheer diversity and amount of these ideas meant the game was confusing, lacked direction and was ultimately not fun fun play.

In contrast, the recent indie title ‘Gone Home’ concentrated of exploration. The developers made a active choice not to include jumping, fighting, and shooting mechanics. In isolation, the gameplay now sounds dull but when you add the eerie sounds and engaging story the game is suddenly a multi award-winning title.

There are plenty of places to try out Marvel Slots and see for yourself how the games interact with the player. From your initial spin to the plethora of mini games you can see that the developers have considered how to keep the player both entertained and engaged throughout.

May 27

Game theory: Exit strategies

Whilst playing No More Zombies on the iPhone recently, I found myself trying to set a limit to my gaming. My limit was set to 100 residents. If I get to 100 people in my town I will stop playing, delete the game and get on with my life. Free of the distraction of stocking shops, building buildings and killing zombies I can discover the other delights of the mobile gaming world.

By 99 I knew the end was near and I was making my price with the world whilst secretly hoping that number 100 was far away. To my surprise, however, the illusive centennial resident was really far away. I continued to pack my shops full of goodies, made a shed load of money and killed more than my fair share of the undead. Yet the regular resident that appeared every few ‘minutes’ (in game time, not real time) failed to materialise.

This got me wondering. Is there a part of game theory that deals with checkpoints, achievements and round numbers in terms of exit points. Is there a shelf life for the casual gamer that can be manipulated to extend the general playtime?

In the old days a game had a beginning and an end, whereas now we have downloadable content which can extend the life of a game ten fold . What interest me though is whether game designers or testers look at ‘exit strategies’.  In business an exit strategy is a point in which the investor or owner has got all the best out of a business and leaves the company with money, shares or a general good feeling. I suppose in games with DLC the main exit point is after the main quest or story has been completed but with more endless games such as city builders, when is a good time to unplug?

After some time scouring the Internet for studies or papers to support my theory I was surprised to find nothing that helped. There is a lot online about rewarding gamers in order to keep their attention which I assume is the reaction to losing gamers. However there is little written about when and why they leave the comfort of the gaming world. So for the record, I would like to claim the study of exit theory in gamers as my own.

Gamers leave a good game for many reasons. The top five reasons are:

game completion (main game) most achievable achievements achieved left for newer/better game difficulty to steep time, family and other commitments

With further study and a whole host of questionnaires it might be possible to predict the most likely exit  points of a game and inject these sections with additional goodies to retain their attention. Being aware that you might lose some of your players at 100 residents might encourage game designers to be smarter when it comes to these exit points.

Source: http://www.gamingdebugged.com/2012/09/19/game-theory-exit-strategies/

AutoDesk-Maya

Apr 28

Top 3 3D Modelling and Animation Software

3D modelling and animation software programs combine the use of numbers and colours to create an amazing visual concept. You can bring your typical 3D model to life using an array of tools to enhance lighting, textures, backgrounds or add additional angles. Your stationary 3d model can be transformed into a rotating model, which can be viewed from a variety of angles, including the ability to zoom in and out to truly assess the effectiveness of certain features. There are many different 3d modelling and animation software packages on the market, some requiring paid subscriptions while others are free. Of those several packages on the market however, there are three options that really offer a superior level of performance.

AutoDesk Maya

This is without a doubt the most comprehensive 3d modelling and software package. It offers the most extensive range of material and texture features including the ability to alter soft body dynamics, hair, skin and muscles. It really stands out for its superior animation features as it offers the ability to edit motion trails and track footage motions as well as other key features such as key frame animation, layering and pose blending. The GeoDex Voxel binding feature allows you to create top quality models very quickly. It is one of the most user friendly software packages too, and it is very easy to use. It can be run on all modern operating systems including Windows 7, 8, XP and Vista as well as MAC OS X. Because it is so comprehensive, you do have to really dedicate yourself to learning in order to really benefit from its full scale of features.

AutoDesk 3DS Max

It might seem unfair to list two AutoDesk products in our top 3, but to leave out AutoDesk 3DS Max would be a travesty. This professional 3d modelling and animation software package has been around for quite some time and offers an excellent array of features. While it doesn’t offer quite the comprehensive list of advanced animation features in comparison with Maya, it is still a very powerful piece of software, and it is ideal if you need to develop content rapidly. It too is supported by all popular operating systems. The Perspective Match features makes editing backgrounds a dream as you can simply upload your background image and fit your model to suit. The ability to upgrade easily to newer versions allows a professional to consistently avail of the most advanced features in 3d modelling. The 2014 version also now supports the use of 2D vector graphics too.

Cinema 4D

Maxon’s premium 3D modelling and animation software really can do just about anything a creative professional could desire from such a software program. It is specifically popular in the movie world where it has been used in the production of some huge movies in recent years including Spiderman 3 and War of the Worlds. That said, architects, engineers and product builders can find it just as beneficial. It has undergone consistent upgrades over the years and now can rightfully claim an equal standard of that of the two aforementioned AutoDesk products. It offers a completely customisable layout to allow for superior ease of use. It can alter bodily dynamics including hair and offer an animation toolbar for easy key frame management. It can render a pretty impressive 32 bits per pixel too. The latest version – Cinema 4D Studio R12 – even offers a visualisation library and a great picture viewer with RAM playback.

There are some great options out there in terms of 3D modelling and animation software, however these three really do serve as the cream of the crop.

unreal-conference

Apr 10

Epic Games offers an insight into the latest Unreal Engine tools and technologies

Epic Games is staging a set of Unreal developer sessions right here in the UK to inform developers about the latest Unreal Engine tools and techniques.

Epic recently announced (at GDC) that the Unreal Engine 4 will be available under a new subscription service which gives developers access to the full engine, tools and C++ source code.

Anyone with an active subscription has been invited by the game maker to the Unreal Developer Day on April 17th, in Stafford. Developers can attend one of two half-day sessions designed for ‘ground floor’ members of the new UE4 ecosystem.

Throughout this event, Epic’s engineering, design and support team members will be onsite to provide insight into the toolset and technologies.

This exciting event takes place on Thursday, April 17th at the Epic Games Centre, Ruxton Technology Centre, Staffordshire University, ST18 0AD, UK. The tickets are sold on a first come, first served basis so get signed up quick.

Registration is for one session only and visitors are required to bring their registration ticket on the day or they might be denied entry.

You can register for the event and get more information here >>

games-in-classroom

Apr 02

What role do video games play in the classroom?

The English Language Arts classroom has a tremendously broad and diverse scope. The curriculum covers writing, speaking, language, literature, and informational reading. That range of content gives you five enormous areas to cover. The source material you study can be taken from ancient Greece, modern popular culture, or anything in between. The means of teaching and assessing students’ progress can include exams, research projects, written essays, presentations, videos, and community projects.

With such diversity in the classroom, and the increasing inclusion of multi-media in schools, perhaps there is room for the use of video games, too. Here are some ideas on the role of video games in the classroom.

Entry points for teaching topics

Video games are good for getting students’ attention, and they can provide easy to understand illustrations of points that you want to teach. For instance, if you are teaching students about the use of tone in writing, you could contrast the tone of two different video games. You could show clips from popular games like Limbo and Little Big Planet 2 side by side, and students will easily see the difference in tone. From there, you could move on to more literary examples.

A ways to get students engaged

Often it is a struggle to get students interested and engaged in books in the classroom. On the other hand, a lot of students are passionate about their video games. This can give you a means to get them more interested in the classroom. Rather than making everyone present and discuss their favorite book, you could make it an option to use your favorite video game as a topic instead. They will be much more enthusiastic about the assignment, and will probably do a better job on it, too.

A source of inspiration

Good video games give players a magical world to enter and develop. Gamers can spend dozens or hundreds of hours exploring their digital world, developing their character’s skills and abilities, and taking exciting and dangerous actions along the way. This can be very inspiring for players, and you can bring some of this into the classroom. Even the most uninterested students may perk right up and get involved when the conversation shifts to relevant aspects of a game they love. Be prepared for some interesting and animated discussions. Your classroom may be livelier than ever before.

Digital learning tools

Schools are increasingly using multi-media learning tools, and video games can be just one more item in your toolbox. The field is still young, however, and you will need to do some experimentation in order to determine the most effective way to use these new tools to accomplish your teaching objectives. You could select a topic, like examining the narrative elements of a popular video game like Call of Duty. On the other hand, you could talk to your students for insights. The world of video games is constantly changing, so see what their favorites are. What do they play every day? What ideas do they have for using video games in the classroom? As you work through this the first few times, you will continue to develop your own ideas about how to make video games an important teaching tool.

We live in a world surrounded by social media. Gamers now have the possibility to share their experiences on Facebook, and that’s a great way of appealing to other people. Teachers should really foster that need to interact with others. Believe it or not, video games have that ability to take kids out of their comfort zone and compel them to do something fun and connect with their peers.

stencyl-3

Feb 22

Stencyl 3.0 is Out Now

Stencyl is a fantastic tool and game engine for those who hate code but love making games. This tool speeds up the process of building games or game prototypes. The highly anticipated update of Stencyl 3.0 is finally here and the new version now supports publishing games to

iOS (iPhone/iPad) Android Flash Windows Mac Linux

Here are few features in the new version:

Platforms

Publish to iOS, Android, Flash, Standalone Desktop (Windows, Mac, Linux). Publish all games directly from your computer. Unification – 1 engine, 1 programming language (Haxe) Open Framework for building new native and pure Haxe extensions.

Other

Improved Font Support Improved Translation (Language Pack) Support Draw UTF-8 (international) characters in-game Gap Free MP3 Playback for Flash Support for OGG playback on all platforms except Flash Multi-Mapped Controls Mobile

Improved handling of arbitrary screen sizes. Improved Ad Support (iAds, AdMob, Events) Improved Social Gaming API Support (Game Center, Events) Improved In-App Purchase Support (Consumables, Restore Purchases, Events) Improved Native UI Support (Keyboard, Swipe, better Joystick, Alerts, Vibrate) Uniform handling of mouse and touch events

Workflow

Test on iOS without going through Xcode Universal Log Viewer No more MAC address requirement to test You don’t have to use atlases if you hate ‘em Engine

Improved Performance. Reduced memory usage and churn. Simple Physics Mode – opt out of physics for better performance if you don’t need it. Reduction of “works only on Flash” features. Core features work everywhere. Full Blending Mode support for Flash Full Screen Mode for Flash, Desktop

Obviously we need to wait and see what the game developers can do with it before we sing its praises, but the features in new version are a step in the right direction

Nov 09

Randomness and Video Game Design

Randomness in games is a recipe for disaster. There are some games like snakes and ladders in which everything is random. The roll of the dice is random, the placement of both the snakes an ladders are random and the winner is random. The game requires no skill and has a level playing field. This is one of the reasons it is a great family game, as a child of four playing for the first time has just as much chance of winning as their experience father, who has played many times. However, if you are creating a game for those over the age of six then randomness should be kept to a minimum.

In most cases, games need set rules and laws to govern play. These rules allow players to learn and get better at the game. If you think of tennis for example, the rules are set and anyone can play. However, only those willing to put the effort in truly excel. If randomness is introduced players would not seek to become professionals as they could never truly control the game. In some cases, such as XCOM the randomness is introduced at the very beginning in the placement of the enemy aliens. This randomness works well as it changes the game from memorizing where the aliens are, to a more strategic game where the act of playing requires skill.

Games like the original Mario and Sonic games required the user to play the levels and memorise the layout in order to achieve the best outcome. Whilst fun, it left little playability after the levels had been completed. More recently, games have introduced additional elements to extend playability such as three different star achievements which are achieved when certain criteria is met. This feature does extend the game but only by a factor of three.

One such random occurrence in modern games is the infamous winged blue shell in Mario Kart. The blue shell is a power up given to the last place player and pretty much instantly, takes out the player in first place. The game itself is fantastic and has spawned a slew of clones but one thing that does stop it from being a fully playable game is the blue shell. I know it is part of a range of balancing measures to keep the game fun for all players but it ultimately punishes good players and those who have attempted to master the game. When you see gamers play Mario Kart at a competitive level you will notice that a tactic has emerged where played actively try NOT to be in first place and that by sitting in the middle of the pack is the best strategy when competing.

I don’t think I have explained myself fully here but the moral of the story is that if you intend your game to last, and tempt players to really invest time and effort in your game, then keep randomness to the absolute minimum. It will just turn players off and pigeon hole your game with many others in the ‘good fun for five minutes’ bracket and lose players who will follow and promote your game. Obviously, some exceptions to the rule exist but trust me; my logic is sound.

Related articles Get ready to waste your life: ‘Super Mario Bros.’ is now playable on your Web browser Designer: Elements of Replayability Indie Showcase: FTL (Faster Than Light) Algorithms to play randomized game Get on board
game-development-guide

Oct 30

Ultimate Online Guide to Video Game Design [Infographic]

The path to video game developer success is long and fraught with danger. It might be easy to have and idea but how do you take make that idea a reality. More than that, how do you make game design and development your life?

Developing video games requires knowledge of many different disciplines. Whilst you might be able to outsource certain aspects of the game build, such as game asset design and music composition, your first few games will require you to envisage, creatively direct, project manage and deliver all by yourself. Sadly, game creation is more than just having a game idea, coding the mechanics and then slapping on some lovely graphics… The modern day indie developer needs to manage the marketing and patiently test the final creation in order to secure some commercial success.

Outside of the game design and development process you may want to think about joining a game development team or established studio in order to gain valuable experience in the industry.

With SO many questions floating around, including those questions that you don’t know to ask yet, wouldn’t it be nice if some kind person or website put together a handy list of resources in an easy to read infographic that would act as an ultimate guide to lead you through the ferocious land of game development…

Thanks to the helpful people over at ‘Online Game Design Schools’ you now have such a document.

Behold, Click here to read The Ultimate Online Guide to Video Game Design

 

 

Related articles Game Design Question: Are You Really Making a Game? Indie Developer Interview: Beansprites | Games for Toddlers Job Description of game designer, technical designer, art designer,level designer and sound designer Google’s game chief has your guide to designing for Google Glass Job description for a game designer
game-or-sim

Oct 28

Game Design Question: Are You Really Making a Game?

It dawned on me recently whilst researching game design that there is a fundamental question that you should ask yourself when starting a game:

Am I making a game or a narrative driven fantasy simulation?

Before video games were around, a game was an activity with a set of rules than could be enjoyed again and again. From Tic Tac Toe to soccer they all have a fixed set of rules and can be played anywhere with almost anything. By this I mean that both the examples can be played on a beach, for example, as Tic Tac Toe can be drawn in the sand with a stick and soccer can use a beach ball and use sweaters as goal posts.

Popular video games such as Tetris and Angry Birds adhere to this pattern. Moles could easily replace the birds and the setting changed to a garden. The rules and enjoyment of the games would still be the same. Game developers need to decide right at the beginning whether or not they are making a game and if so, what are the rules, how is it enjoyed and can it be replicated no matter what the graphics, story and rewards.

A narrative based fantasy simulation sees the player assume a role in a story and the player must walk the protagonist through a series of events and/or confrontations until the narrative is complete. Whilst fun, these games are pretty linear and often are disposed of when complete similar to books.

One question that is asked when designing games is:

How is the game won or beaten?

For a narrative driven games this is easy, as it concludes when the story is complete. However, with Tetris, the game is never truly beaten. Success is achieved by beating previous scores. Games like chess can be mastered but never really beaten.

So when your next devising your next video game ask yourself if it’s a game or simulation and if the answer is a game then focus on the rules, the gameplay and how a player wins. If the later is true, focus on story, experience emotion and characters. Trying to mix the two from an early point might just lead to a game that has mediocre effort in both areas.