Images Donate icon An illustration of a heart shape Donate Ellipses icon An illustration of text ellipses. EMBED for wordpress. Want more? Advanced embedding details, examples, and help! Topics J2ME games , Java games , mobile games , nokia games , cell phone games , games archive , j2me pack , java games , midlet , cell phone , nokia games , mobile games , nokia , games pack , archive , J2ME games , cell phone games. This item is part of an effort to archive as many J2ME software as possible before it disappears completely.
Focus is on early era games A pack of J2me games from the era. Also contains some applications. Many ones are for Nokia phones. Browse the pack. You can use the open-source FreeJ2ME emulator to play many of those games You can find some more J2ME games stuff at my profile If you still have J2ME games from that era lying around somewhere, please, any help is appreciated:contact me at Nokia64 at protonmail dot com. There are no reviews yet. Be the first one to write a review.
That's why I warmly welcome any comments or suggestions to make it a better guide. As a Midlet , the MainMidlet must extend the abstract class Midlet that can be found in the package javax.
The Midlet requires override of three methods:. We are, however, only needed to implement the startApp methods by creating an instance of our GameCanvas and adding a CommandListener to exit the Midlet.
It is, of course, not a good programming habit but until this step, we probably only want the application to run. Current display can be set to the GameCanvas at the end or inside the GameCanvas by the method setCurrent.
This method accepts any Displayable objects as an argument. As an element of low level UI engine, when combined with Graphics , GameCanvas provides us flexible tools to set up our own game screen. With Graphics , you basically can draw things that you can normally do in Java 2D, including drawing shapes, strings or images. GameCanvas is an extension to the original Canvas with more control over the painting, and the rate at which keys are delivered into the game.
Using GameCanvas , you can notice its capabilities including the off-screen buffering. When you are drawing things, you probably are drawing into the off-screen and by calling the flushGraphics method, the buffer is quickly written into the screen.
GameCanvas also simplifies the process of getting input by allowing us to query the key status using the getKeyState method. Processing key status, however, is left to the GameManager for easier management. The origin of the game coordinate system is located in the top left corner of the screen as shown. In the render method, the off-screen is cleared and graphics are rendered by calling paint method of the GameManager.
In this example, the SSGameCanvas implements Runnable interface, which leads to the creation of the run methods in which we create a game loop running until we reach certain ending condition.
Timing of the game is controlled by an integer named tick. We will probably need only 24 fps, so we limit the mDelay accordingly to have the desired animation effect with less power consumption. At every cycle of the game, we call the method advance of the GameManager , which extends LayerManager to check the user input, collisions and paint the graphics. Sprite acts as the actors of the games.
It could be our Mario characters, ducks, and bullets in the Mario games or space ships in a star war game.
As a basic visual element, it can be rendered to display continuous action with several frames stored in an Image. The Image file must pack all the frames of the Sprite in order to be displayed. All frames must have the same and predefined width and height.
To initiate the Ship sprite, I call the constructor from the superclass Sprite : super image, w, h ; where w and h is the width and height of each frame. Next, I call the defineReferencePixel method to set the reference point to the middle of the frame.
0コメント