Java-Gaming.org    
Featured games (81)
games approved by the League of Dukes
Games in Showcase (495)
Games in Android Showcase (114)
games submitted by our members
Games in WIP (563)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
    Home     Help   Search   Login   Register   
Pages: [1]
  ignore  |  Print  
  side-scrolling game  (Read 1275 times)
0 Members and 1 Guest are viewing this topic.
Offline games

Senior Newbie





« Posted 2005-08-08 21:24:49 »

Hi, I am very embarrassed for asking this question and I am very new to Java and I am trying to make an online 2D side-scrolling applet game similar to Super Mario Bros. using tiles and MemoryImageSource. The tile map is a two-dimensional array. Generating the map is easy. Scrolling is slow. I don't which way is the fastest way of scrolling the map and don't know if a two-dimensional array using tiles is the best way to make a game like that. I don't know how to make it as fast as the illegal Java NES emulator called NESCafe (http://www.davieboy.net/nescafe/). I looked at the source code of NESCafe and it uses MemoryImageSource because it's the fastest way and I don't understand most of it. NESCafe can play Super Mario Bros. very fast at 30 fps. How do I start?
Offline erikd

JGO Ninja


Medals: 16
Projects: 4
Exp: 14 years


Maximumisness


« Reply #1 - Posted 2005-08-08 22:01:50 »

If you have performance problems with anything, always profile first (for example by running with -Xprof) before doing anything else.
MemoryImageSource is not the fastest way to do rendering because what you will basically do is software rendering. Most of the time people use MemoryImageSource is because it is compatible with java 1.1. (But, since you want to make an applet game, maybe that's what you want?)

Maybe you could benefit from a higher level 2D game engine like GTGE. It has most difficult stuff done for you already.
http://goldenstudios.or.id/products/GTGE/
I haven't used it myself, but from what I heard it's quite good and easy to use and it has tutorials.

Offline games

Senior Newbie





« Reply #2 - Posted 2005-08-15 17:03:09 »

I hate high-level game engines. I want something that is low-level that can make very fast Java 1.5 applet games so I can have more control of the game.
Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline Soulfly32

Senior Newbie





« Reply #3 - Posted 2005-08-15 18:16:17 »

HI I made a sidescrolling myself and maybe i can help you with scrolling perfomance issues..
If you use a tiled background only draw what is really on screen and if
you do this for the tiles of the level you will have no problem.

_____________________________________
www.soulfly-design.de
www.soulflyhome.com
Pages: [1]
  ignore  |  Print  
 
 
You cannot reply to this message, because it is very, very old.

 

Add your game by posting it in the WIP section,
or publish it in Showcase.

The first screenshot will be displayed as a thumbnail.

Dwinin (28 views)
2014-09-12 09:08:26

Norakomi (57 views)
2014-09-10 13:57:51

TehJavaDev (73 views)
2014-09-10 06:39:09

Tekkerue (37 views)
2014-09-09 02:24:56

mitcheeb (57 views)
2014-09-08 06:06:29

BurntPizza (44 views)
2014-09-07 01:13:42

Longarmx (27 views)
2014-09-07 01:12:14

Longarmx (34 views)
2014-09-07 01:11:22

Longarmx (34 views)
2014-09-07 01:10:19

mitcheeb (40 views)
2014-09-04 23:08:59
List of Learning Resources
by Longor1996
2014-08-16 10:40:00

List of Learning Resources
by SilverTiger
2014-08-05 19:33:27

Resources for WIP games
by CogWheelz
2014-08-01 16:20:17

Resources for WIP games
by CogWheelz
2014-08-01 16:19:50

List of Learning Resources
by SilverTiger
2014-07-31 16:29:50

List of Learning Resources
by SilverTiger
2014-07-31 16:26:06

List of Learning Resources
by SilverTiger
2014-07-31 11:54:12

HotSpot Options
by dleskov
2014-07-08 01:59:08
java-gaming.org is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑gaming.org
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!