Home > Store

Micro Java" Game Development

Register your product to gain access to bonus material or receive a coupon.

Micro Java" Game Development

eBook (Adobe DRM)

  • Sorry, this book is no longer in print.
  • About Adobe DRM eBooks
  • This eBook requires the free Adobe® Digital Editions software.

    Before downloading this DRM-encrypted PDF, be sure to:


    • Install the free Adobe Digital Editions software on your machine. Adobe Digital Editions only works on Macintosh and Windows, and requires the Adobe Flash Player. Please see the official system requirements.
    • Authorize your copy of Adobe Digital Editions using your Adobe ID (select AdobeID as the eBook vendor). If you don't already have an Adobe ID, you can create one here.
Not for Sale

Description

  • Copyright 2002
  • Dimensions: 7-3/8" x 9-1/8"
  • Edition: 1st
  • eBook (Adobe DRM)
  • ISBN-10: 0-7686-6237-0
  • ISBN-13: 978-0-7686-6237-5

Micro Java Games Development explains game development for devices that support J2ME MIDP. The six parts cover a full range of topics, from a tour of all available micro-devices (Palms, cell phones and pagers), a discussion of software standards apart from J2ME (cell phones, messaging, I-mode and wireless enhancements such as Bluetooth), and available J2ME extensions (Siemans, Ericcson, Nokia), development tools and restrictions, to the creation of a meaty J2ME game!

Sample Content

Table of Contents



1. Introduction (or Everything I Wanted to Know About Micro Java Gaming But Was Afraid to Ask).

A New Era of Gaming.

A Brief History of Games.

Multiplayer Mania.

Micro Devices, Micro Lifestyles.

Enter Micro Java.

This Book's Mission.

The Game Plan.

A Bit About Game Design.

The Game Design Process.

Preproduction.

Prototyping.

Programming.

Playtesting.

Show Me the Money: Micro Game Business Models.

The Business Outlook.

Advertising and Sponsorships.

Content Deals.

Pay-For-Play or Subscription.

Summary.

I. SMALL DEVICES.

2. The Mobile World.

A New Era of Gaming.

Micro Devices.

The Micro Revolution Begins.

High-End Java Devices: Set-Top Boxes, Phones, Consoles.

PersonalJava.

JavaTV.

JavaPhone.

PingTel xpressa Phone.

Sharp NC-10 IP Phone.

Personal Digital Assistants (PDAs).

J2ME PDA Profile.

PalmOS.

Microsoft Windows CE.

Symbian EPOC.

Sharp Zaurus SL-5000.

URL: http://developer.sharpsec.com/.

Other Linux Handhelds.

Micro Java Virtual Machines.

Mobile Phones and Pagers.

Casio CdmaOne C452CA.

Ericsson R380.

Fujitsu F503i.

Hitachi CdmaOne C451H.

LG Telecom p510 (i-Book).

Other LG Telecom Phones.

Matsushita/Panasonic P503i.

Matsushita/Panasonic P503iS.

Matsushita/Panasonic FOMA P2101V.

Mitsubishi D503i and D503iS.

Mitsubishi J-D05.

Motorola i85s.

Motorola i50sx.

Motorola Accompli 009 PIC.

Motorola, Accompli 008/6288.

Other Motorola Phones.

NEC N503i.

NEC FOMA N2001.

Nokia 9210 and 9290 Communicator.

RIM/iPaq Blackberry.

Samsung SCH-X130, SCH-X230, SCH-X350, and SCH-X350.

Sharp J-SH07.

Siemens SL45i (or 6688i).

Sony SO503i.

Toshiba J-T06.

Low-End Java Devices: Smart Cards and Embedded Chips.

JavaCard.

EmbeddedJava.

Summary.

3. Big Games, Small Screens.

Your Competition.

Things to Look For.

The Near Future.

WAP Games.

Wireless Games.

Jamdat.

PicoFun.

Handy Games.

FunCaster.com.

Unplugged Games.

nGame.

i-mode Games.

Dwango's Turibaka Kibun.

SMS Games.

Fisupeli.

Blue Factory.

BotFighters by It's Alive.

Vizzavi Footie and Trivia.

J2ME MIDP Games.

Karl Hörnell's MIDPman.

HolyCowBoy's BlockBuster and HolyMoley.

Draw Poker.

Cocoasoft.

RomeBlack's Mobile Internet Maze Game.

Sky Arts' Cube Game.

Jshape's M-Type and MIDP Street Fighter.

Spruce Team.

Red Team's Dope Wars.

J2ME Palm Games.

Torunda!

Karl Hörnell's Iceblox and PalmWarp.

Hobbit's Let Me Alone.

iAppli Games.

Squiral Game.

Dwango's Samurai Romanesque.

Dwango's Challenge! The Hard-Boiled Way.

Sega.

Namco.

Capcom.

Bandai Networks.

Cybird's Mini Game Tengoku.

Hudson Soft.

What Are You Waiting For?

II. BEFORE, BETWEEN, AND BEYOND J2ME.

4. Wireless Standards: How Data Goes To And Fro.

Wireless Networks.

First Generation (1G).

Second Generation (2G).

Second (and a Half) Generation (2.5G).

Third Generation (3G).

The Wireless Application Protocol (WAP).

The WAP Protocol Stack.

WAP Architecture.

The Wireless Markup Language (WML).

WMLScript.

Server-Side WAP.

Server Configuration.

WAP and Java.

Development Environment.

Handheld Device Markup Language (HDML).

HDML Syntax.

Displays.

Activities.

Actions.

Hyperlinks.

Images.

WAP 2.0 and xHTML Basic.

Summary.

5. Let's Talk: Instant Wireless Messaging.

Messaging And Gaming.

Short Message Service (SMS).

SMS Specifics.

Short Message Service Centers (SMSCs).

Free SMS Service.

Actually Sending SMS Messages.

SMS Tools.

SMS and J2ME.

Sample Server Code.

Multimedia Messaging Service (MMS).

Multimedia Message Service Centers (MMSC).

Crack a SMIL.

Simple SMIL Example.

Enhanced Messaging Service (EMS).

Summary.

6. Wireless in Asia: i-mode and cHTML.

Using i-mode.

Compact HTML (cHTML).

Character Sets.

Emoji.

cHTML Structure.

Standard cHTML Tags.

Input Forms.

The Anchor Tag.

Images.

<Marquee>

Development Tools.

Testing and Emulators.

Summary.

7. The Wireless Landscape.

Bluetooth.

Bluetooth Protocols.

Bluetooth and Java.

Other Short-Range Applications.

Broadband's Promise.

Mobile Positioning.

How It All Works.

Forums and Associations.

Privacy.

Positioning Technologies.

m-Commerce.

Charging for Content.

Micro Java and Money.

Voice and Telephony.

VoiceXML.

VoiceXML Software.

Wireless Telephony Application Interface (WTAI).

Unified Messaging (UM).

Summary.

III. THE JAVA 2 MICRO EDITION.

8. J2ME Overview.

The Trinity of Java Platforms.

It's a Small World After All

Using Java on Small Devices.

J2ME Rocks!

Profiles and Configurations.

Major J2ME Configurations.

J2ME Profiles.

The Kilobyte Virtual Machine.

The Java Application Manager.

Packaging into a JAR File.

Connected in a Limited Way: The CLDC.

Security.

Pre-verifying.

The Mobile Profile.

MIDP in a Nutshell.

Earlier Profiles.

Summary.

9. Creating a MIDlet.

Command-Line MIDlet Development.

Development Environments.

Wireless Toolkit.

Lifecycle of a MIDlet.

Displaying Stuff.

Working with Screens.

Forms.

Menus and Commands.

Creating Help and About Alert Screens.

The Alert Class.

Splash Screens.

Global Properties.

Getting Application Properties.

Getting System Properties.

Creating a Global Cache Class.

Summary.

10. Making the Most of Limited Resources.

The Limitations.

Processor Paucity.

Memory Madness.

Video Vex.

Processors of the Future.

Memory Limitations.

Working Memory.

Storage Memory.

Displays.

Breaking Through the Limitations.

Detecting the Minimum Speed.

Frame Rate.

Multiple Display Support.

Black and White World.

Summary.

11. Making the Most of It: Optimizations.

A Limited World.

Making Code Optimal.

Code Size Optimizations.

Making code Faster.

Decreasing Memory.

Device Availability.

Network Performance.

Code Size Reductions.

Obfuscators and Name-Shortening.

The Object-Oriented Dilemma.

Image Size Reduction.

Speeding Up the Code.

Dealing with the Garbage Collector.

The Constructorless Way.

Static Methods.

The Fast-Draw.

Using Less Memory.

String Versus StringBuffer.

Arrays Versus Vector and Hashtable.

Power Consumption.

Summary.

12. Multithreaded Game Programming.

Threads.

Extending the Thread Object.

Implementing the Runnable Interface.

Thread Priorities.

Thread States.

Synchronizations and Deadlocks.

wait() and notify().

Timers.

Making Threads Better.

Summary.

IV. LET THE GAMES BEGIN!

13. High-Level Graphical User Interfaces.

The Screen Class.

Forms and Alerts.

Lists.

List Types.

Choices, Choices.

Text Boxes.

Items.

Item State Listening.

Choices.

Dates.

Progress Meters.

String Items.

Image Items.

Text Inputs.

Tickers.

Additional Libraries.

Summary.

14. Working with Graphics: Low-Level Graphical User Interfaces.

The Canvas Class.

Canvas Events.

Custom Commands.

Creating a Game Key and Pointer Handler.

Handling Touch Screens.

Painting on the Screen.

Working with Colors.

Stroke Types

Drawing Lines.

Drawing Rectangles.

Drawing Rounded Rectangles.

Drawing Arcs.

Fonts.

Drawing Strings.

Drawing Images.

The Image Class.

Clipping.

Translating.

Double Buffering.

Summary.

15. Entering the Land of Sprites.

Sprites.

Sprite Properties.

Animating Frames.

The Sprite Class.

Image Files.

Loading Included Images.

Loading Images Over the Network.

Image Size Reduction.

Drawing the Sprites.

Collision Detection.

Basic Collision Detection.

Creating Child Sprites.

Building the Player Sprite.

Opponents.

Image Transparency.

Drawing by Pixels.

Drawing a Sprite's Chunks.

Implementation of Image Transparency.

Summary.

16. Managing Your Sprites.

Networked Game Components.

Downloading Images.

Downloading Other Media Types.

Advanced Collision Detection.

Solution 1: Multiple Levels.

Solution 2: Multiple Areas.

The Sprite Manager.

Drawing Optimizations.

Enhancing Sprite Collision.

Summary.

17. Sprite Movement.

Floating-Point in J2ME.

Cheating the System.

Game Initialization.

Movement.

The Movement Routine.

Piecing It All Together.

Handling Collision Detection.

Endgame: Losing or Winning.

The Final Game Thread.

Summary.

18. J2ME Audio Basics.

Sounds Are (Barely) Possible.

Summary.

19. Be Persistent: MIDP Data Storage.

RecordStore Overview.

RecordStore in Practice.

addRecord().

getRecord().

setRecord().

deleteRecord().

getLastModified().

getNextRecordID().

getNumRecords().

getSize().

getSizeAvailable().

deleteRecordStore().

EnumerateRecords().

The Game's New Methods.

Writing the Code.

More RecordStore Joy.

Summary.

20. Connecting Out: Wireless Networking.

J2ME Networking Overview.

MIDP Networking.

A Little Info About HTTP.

HTTP Example.

Working Around HTTP's Limitations.

Setting Up Your Game Server.

Data Format.

Doing Your Own Packing.

XML.

Encoding with DataOutputStream and DataInputStream.

Making a Multiplayer Car Racing Game.

Design the System.

Special Considerations.

The Messages.

Weaknesses.

The Client Side.

The Server Side.

Playing the Game.

Summary.

V. J2ME EXTENSIONS.

21. PersonalJava, Connected Device Configuration, and Other Micro Java Blends.

Connected Device Configuration (CDC).

J2ME Foundation Profile.

The Personal Profile.

PersonalJava.

PersonalJava APIs.

Double Buffering.

Developer Tools.

MIDP Plug-In for PersonalJava.

PersonalJava Design Considerations.

PDA Profile.

Java Game Profile.

The J2ME Multimedia Profile.

Summary.

22. iAppli: Micro Java with a Twist.

The Architecture of It All.

Provisioning.

Priorities, Priorities.

iAppli: Like MIDP, But Not Quite.

User Interface.

Networking and Input/Output.

Developing iApplis.

Summary.

23. Siemens Game API.

Getting Set Up.

Compiling.

Running with the Emulator.

Running on the Actual Phone.

Download Your Applet Over the Air.

The Game SDK Overview.

Images and Sprites.

Creating an Extended Image.

Blitting.

Graphic Objects.

Sprites.

Creating and Masking a Sprite.

Sample Code.

TiledBackground.

The Tiles.

The Tile Background.

Flashing.

Good Vibrations.

Music, Sweet Music.

Melodies.

GSM Functions.

Making a Call.

Accessing the Phone Book.

SMS Messages.

Input Output.

Sending and Receiving Data.

Saving and Loading Files.

Summary.

VI. MICRO RACER.

24. Micro Racer: Putting It All Together.

The Bad News.

The Good News.

Putting Together the Pieces.

Adding Weapons.

Better Enemies: Artificial Intelligence.

Better Control.

Adding Power-Ups.

Tying In the Game with the Data Store.

Tying In the Offline Game with the Online Garage.

Future Work.

One Game Running Everywhere.

The Magic of Interfaces.

Summary.

VII. APPENDIXES.

Appendix A. Low-Level GUI Classes.

Game Classes.

javax.microedition.lcdui.AlertType.

javax.microedition.lcdui.Command.

javax.microedition.lcdui.Display.

javax.microedition.lcdui.Displayable.

javax.microedition.lcdui.Canvas.

javax.microedition.lcdui.Screen.

javax.microedition.lcdui.Alert.

javax.microedition.lcdui.Form.

javax.microedition.lcdui.List.

javax.microedition.lcdui.TextBox.

javax.microedition.lcdui.Font.

javax.microedition.lcdui.Graphics.

javax.microedition.lcdui.Image.

javax.microedition.lcdui.Item.

javax.microedition.lcdui.ChoiceGroup.

javax.microedition.lcdui.DateField.

javax.microedition.lcdui.Gauge.

javax.microedition.lcdui.ImageItem.

javax.microedition.lcdui.StringItem.

javax.microedition.lcdui.TextField.

javax.microedition.lcdui.Ticker.

Appendix B. MIDP 1.1.

Main Packages.

java.io Class Hierarchy.

java.io Interface Hierarchy.

java.lang Class Hierarchy.

java.lang Interface Hierarchy.

java.util Class Hierarchy.

java.util Interface Hierarchy.

javax.microedition.io Class Hierarchy.

javax.microedition.io Interface Hierarchy.

javax.microedition.lcdui Class Hierarchy.

javax.microedition.lcdui Interface Hierarchy.

javax.microedition.midlet Class Hierarchy.

javax.microedition.rms Class Hierarchy.

javax.microedition.rms Interface Hierarchy.

Appendix C. Siemens Game API.

Game Classes.

com.siemens.mp.game.Light.

com.siemens.mp.game.MelodyComposer.

com.siemens.mp.game.ExtendedImage.

com.siemens.mp.game.GraphicObject.

com.siemens.mp.game.Sprite.

com.siemens.mp.game.TiledBackground.

com.siemens.mp.game.GraphicObjectManager.

com.siemens.mp.game.Melody.

com.siemens.mp.game.Sound.

com.siemens.mp.game.Vibrator.

Siemens GSM Classes.

com.siemens.mp.gsm.Call.

com.siemens.mp.gsm.PhoneBook.

com.siemens.mp.gsm.SMS.

Input/Output Classes.

com.siemens.mp.io.Connection.

com.siemens.mp.io.File.

public interface ConnectionListener.

Appendix D. The iAppli API.

Packages.

com.nttdocomo.io Interfaces.

com.nttdocomo.io Interfaces.

com.nttdocomo.lang.

com.nttdocomo.net.

com.nttdocomo.ui.

com.nttdocomo.ui Interfaces.

com.nttdocomo.util.

com.nttdocomo.util Interfaces.

IApplication.

Index. 0672323427T04222002

Updates

Submit Errata

More Information

InformIT Promotional Mailings & Special Offers

I would like to receive exclusive offers and hear about products from InformIT and its family of brands. I can unsubscribe at any time.

Overview


Pearson Education, Inc., 221 River Street, Hoboken, New Jersey 07030, (Pearson) presents this site to provide information about products and services that can be purchased through this site.

This privacy notice provides an overview of our commitment to privacy and describes how we collect, protect, use and share personal information collected through this site. Please note that other Pearson websites and online products and services have their own separate privacy policies.

Collection and Use of Information


To conduct business and deliver products and services, Pearson collects and uses personal information in several ways in connection with this site, including:

Questions and Inquiries

For inquiries and questions, we collect the inquiry or question, together with name, contact details (email address, phone number and mailing address) and any other additional information voluntarily submitted to us through a Contact Us form or an email. We use this information to address the inquiry and respond to the question.

Online Store

For orders and purchases placed through our online store on this site, we collect order details, name, institution name and address (if applicable), email address, phone number, shipping and billing addresses, credit/debit card information, shipping options and any instructions. We use this information to complete transactions, fulfill orders, communicate with individuals placing orders or visiting the online store, and for related purposes.

Surveys

Pearson may offer opportunities to provide feedback or participate in surveys, including surveys evaluating Pearson products, services or sites. Participation is voluntary. Pearson collects information requested in the survey questions and uses the information to evaluate, support, maintain and improve products, services or sites, develop new products and services, conduct educational research and for other purposes specified in the survey.

Contests and Drawings

Occasionally, we may sponsor a contest or drawing. Participation is optional. Pearson collects name, contact information and other information specified on the entry form for the contest or drawing to conduct the contest or drawing. Pearson may collect additional personal information from the winners of a contest or drawing in order to award the prize and for tax reporting purposes, as required by law.

Newsletters

If you have elected to receive email newsletters or promotional mailings and special offers but want to unsubscribe, simply email information@informit.com.

Service Announcements

On rare occasions it is necessary to send out a strictly service related announcement. For instance, if our service is temporarily suspended for maintenance we might send users an email. Generally, users may not opt-out of these communications, though they can deactivate their account information. However, these communications are not promotional in nature.

Customer Service

We communicate with users on a regular basis to provide requested services and in regard to issues relating to their account we reply via email or phone in accordance with the users' wishes when a user submits their information through our Contact Us form.

Other Collection and Use of Information


Application and System Logs

Pearson automatically collects log data to help ensure the delivery, availability and security of this site. Log data may include technical information about how a user or visitor connected to this site, such as browser type, type of computer/device, operating system, internet service provider and IP address. We use this information for support purposes and to monitor the health of the site, identify problems, improve service, detect unauthorized access and fraudulent activity, prevent and respond to security incidents and appropriately scale computing resources.

Web Analytics

Pearson may use third party web trend analytical services, including Google Analytics, to collect visitor information, such as IP addresses, browser types, referring pages, pages visited and time spent on a particular site. While these analytical services collect and report information on an anonymous basis, they may use cookies to gather web trend information. The information gathered may enable Pearson (but not the third party web trend services) to link information with application and system log data. Pearson uses this information for system administration and to identify problems, improve service, detect unauthorized access and fraudulent activity, prevent and respond to security incidents, appropriately scale computing resources and otherwise support and deliver this site and its services.

Cookies and Related Technologies

This site uses cookies and similar technologies to personalize content, measure traffic patterns, control security, track use and access of information on this site, and provide interest-based messages and advertising. Users can manage and block the use of cookies through their browser. Disabling or blocking certain cookies may limit the functionality of this site.

Do Not Track

This site currently does not respond to Do Not Track signals.

Security


Pearson uses appropriate physical, administrative and technical security measures to protect personal information from unauthorized access, use and disclosure.

Children


This site is not directed to children under the age of 13.

Marketing


Pearson may send or direct marketing communications to users, provided that

  • Pearson will not use personal information collected or processed as a K-12 school service provider for the purpose of directed or targeted advertising.
  • Such marketing is consistent with applicable law and Pearson's legal obligations.
  • Pearson will not knowingly direct or send marketing communications to an individual who has expressed a preference not to receive marketing.
  • Where required by applicable law, express or implied consent to marketing exists and has not been withdrawn.

Pearson may provide personal information to a third party service provider on a restricted basis to provide marketing solely on behalf of Pearson or an affiliate or customer for whom Pearson is a service provider. Marketing preferences may be changed at any time.

Correcting/Updating Personal Information


If a user's personally identifiable information changes (such as your postal address or email address), we provide a way to correct or update that user's personal data provided to us. This can be done on the Account page. If a user no longer desires our service and desires to delete his or her account, please contact us at customer-service@informit.com and we will process the deletion of a user's account.

Choice/Opt-out


Users can always make an informed choice as to whether they should proceed with certain services offered by InformIT. If you choose to remove yourself from our mailing list(s) simply visit the following page and uncheck any communication you no longer want to receive: www.informit.com/u.aspx.

Sale of Personal Information


Pearson does not rent or sell personal information in exchange for any payment of money.

While Pearson does not sell personal information, as defined in Nevada law, Nevada residents may email a request for no sale of their personal information to NevadaDesignatedRequest@pearson.com.

Supplemental Privacy Statement for California Residents


California residents should read our Supplemental privacy statement for California residents in conjunction with this Privacy Notice. The Supplemental privacy statement for California residents explains Pearson's commitment to comply with California law and applies to personal information of California residents collected in connection with this site and the Services.

Sharing and Disclosure


Pearson may disclose personal information, as follows:

  • As required by law.
  • With the consent of the individual (or their parent, if the individual is a minor)
  • In response to a subpoena, court order or legal process, to the extent permitted or required by law
  • To protect the security and safety of individuals, data, assets and systems, consistent with applicable law
  • In connection the sale, joint venture or other transfer of some or all of its company or assets, subject to the provisions of this Privacy Notice
  • To investigate or address actual or suspected fraud or other illegal activities
  • To exercise its legal rights, including enforcement of the Terms of Use for this site or another contract
  • To affiliated Pearson companies and other companies and organizations who perform work for Pearson and are obligated to protect the privacy of personal information consistent with this Privacy Notice
  • To a school, organization, company or government agency, where Pearson collects or processes the personal information in a school setting or on behalf of such organization, company or government agency.

Links


This web site contains links to other sites. Please be aware that we are not responsible for the privacy practices of such other sites. We encourage our users to be aware when they leave our site and to read the privacy statements of each and every web site that collects Personal Information. This privacy statement applies solely to information collected by this web site.

Requests and Contact


Please contact us about this Privacy Notice or if you have any requests or questions relating to the privacy of your personal information.

Changes to this Privacy Notice


We may revise this Privacy Notice through an updated posting. We will identify the effective date of the revision in the posting. Often, updates are made to provide greater clarity or to comply with changes in regulatory requirements. If the updates involve material changes to the collection, protection, use or disclosure of Personal Information, Pearson will provide notice of the change through a conspicuous notice on this site or other appropriate way. Continued use of the site after the effective date of a posted revision evidences acceptance. Please contact us if you have questions or concerns about the Privacy Notice or any objection to any revisions.

Last Update: November 17, 2020