22
Series 40 Developer Training Getting Started with 2D Game Development on Nokia Series 40 Asha Phones Michael Samarin, Ph.D Director, Developer Training and Evangelism Futurice Oy +358 40 518 18 09 [email protected] @MichaelSamarin

Introduction to 2D Game Development on Nokia Series 40 Asha Phones

Embed Size (px)

DESCRIPTION

During this webinar, you’ll learn how to get started with 2D game development for Nokia Series 40 Asha phones, even if you’ve never developed a game. Michael Samarin from Futurice will show you how to use the Game Builder tool to create simple games. All you need is familiarity with Java™ technology, with the NetBeans IDE (for which Game Builder is a plug-in), and with the Nokia SDK for Java™. Using the Game Builder visual tool and studying the code generated are great ways to build game development skills. The webinar also will give you an overview of Java ME classes typically used in game development. Finally, it will introduce you to asset-management techniques and associated platform limitations and capabilities.

Citation preview

Page 1: Introduction to 2D Game Development on Nokia Series 40 Asha Phones

Series 40 Developer Training

Getting Started with 2D Game Development on Nokia Series 40 Asha Phones

Michael Samarin, Ph.D Director, Developer Training and Evangelism Futurice Oy +358 40 518 18 09 [email protected]

@MichaelSamarin

Page 2: Introduction to 2D Game Development on Nokia Series 40 Asha Phones

Today’s Topics » Understanding Gaming Market for Series 40

» Where to get more information

» 2D Game APIs in Mobile Java

» Demo of 2D Game Building Concepts

» NetBeans 7.1 and Game Builder Plugin

» Walking Through Game Builder Sample

» Series 40 Devices and 2D Games Performance

Page 3: Introduction to 2D Game Development on Nokia Series 40 Asha Phones

Series 40 » 675 Million Devices

» 3.9 Million Daily Downloads

» Price range 35 – 140 Euro

» Gaming Studios to compete with: EA, Gameloft, Rovio, India Games

Page 4: Introduction to 2D Game Development on Nokia Series 40 Asha Phones

Nokia Developer Guides and Docs » http://www.developer.nokia.com/Resources/Library/Java/#!dev

elopers-guides/ui-and-graphics/game-api.html

6/4/2012

4

Page 5: Introduction to 2D Game Development on Nokia Series 40 Asha Phones

Nokia Developer Guides and Docs

Oracle (Sun) Guides and Docs » http://developers.sun.com/mobility/midp/articles/gameapi/

» http://developers.sun.com/mobility/midp/articles/game/

» http://www.developer.nokia.com/Resources/Library/Java/#!developers-guides/ui-and-graphics/game-api.html

Page 6: Introduction to 2D Game Development on Nokia Series 40 Asha Phones

› Game API Package (MIDP)

› javax.microedition.lcdui.game › GameCanvas

› Layer

› LayerManager

› Sprite

› TiledLayer

Page 7: Introduction to 2D Game Development on Nokia Series 40 Asha Phones

› GameCanvas › Double buffered

› Convenient for minimizing code of game loop

› Methods for querying status of keys

Page 8: Introduction to 2D Game Development on Nokia Series 40 Asha Phones

› GameCanvas

public class MyCanvas extends GameCanvas implements Runnable {

public void run() {

Graphics g = getGraphics();

while(true) {

// update the game state

int k = getKeyStates();

// respond to key events

flushGraphics();

}

}

}

Page 9: Introduction to 2D Game Development on Nokia Series 40 Asha Phones

Live Demos:

Page 10: Introduction to 2D Game Development on Nokia Series 40 Asha Phones

› Graphical Assets

Page 11: Introduction to 2D Game Development on Nokia Series 40 Asha Phones

› Graphical Assets – Sprite Star

Page 12: Introduction to 2D Game Development on Nokia Series 40 Asha Phones

› Graphical Assets – Sprite Lightning

Page 13: Introduction to 2D Game Development on Nokia Series 40 Asha Phones

› Layer › Abstract class, any visual game

element

› LayerManager

› Combines layers together, provides viewport

Page 14: Introduction to 2D Game Development on Nokia Series 40 Asha Phones

› Sprite › Animated game object

› TiledLayer

› Game areas, backgrounds

Page 15: Introduction to 2D Game Development on Nokia Series 40 Asha Phones

› Sprite

› Animated element of the game (character)

› Define Sequence, Delay

› Flip, Rotate

› Define Reference Point

› Detect Collisions

Page 16: Introduction to 2D Game Development on Nokia Series 40 Asha Phones

› TIledLayer

› Defines game backgrounds

› Can be animated

› Doesn’t have Sprite methods

Page 17: Introduction to 2D Game Development on Nokia Series 40 Asha Phones

Live Demos:

Page 18: Introduction to 2D Game Development on Nokia Series 40 Asha Phones

› NetBeans Game Builder Plug-In

Page 19: Introduction to 2D Game Development on Nokia Series 40 Asha Phones

Live Demos:

Page 20: Introduction to 2D Game Development on Nokia Series 40 Asha Phones

Asha 303 Nokia 111

Page 21: Introduction to 2D Game Development on Nokia Series 40 Asha Phones

Consider

› Java Heap size (1 – 4 MB)

› JAR file size ( 1 – 2 MB)

› CPU speed

› Screen Size 240x 320, 320x240, 128x160

› Input Type: T9, Qwerty, Touch-And-Type

› Use Nokia Device Matrix

› Remote Device Access

Page 22: Introduction to 2D Game Development on Nokia Series 40 Asha Phones

Thank you!

@MichaelSamarin