Java-Gaming.org Hi !
Featured games (90)
games approved by the League of Dukes
Games in Showcase (778)
Games in Android Showcase (231)
games submitted by our members
Games in WIP (856)
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  
  isometric animation loop  (Read 1849 times)
0 Members and 1 Guest are viewing this topic.
Offline MickeyB

Senior Devvie




my game will work, my game will work!


« Posted 2003-04-20 13:38:17 »

Just so I am on the right path.  When ding the animation loop for an isometric scroller, each tile, each tile overlay(layer) and each overlays overlay, have to be moved when scrolling the screen within the animation loop?

Just seems like a lot of work for the loop.   I havent dug into planetation yet, but do most of you then clip the viewable area at this point then paint?


M

MickeyB

Current Project: http://www22.brinkster.com/mbowles/
Offline Orangy Tang

JGO Kernel


Medals: 57
Projects: 11


Monkey for a head


« Reply #1 - Posted 2003-04-20 13:51:04 »

An easier way I use (and probably almost everyone else) is to have a Camera class which contains the position and size of the current viewing area - your tiles stay exactly where they are in the world, and you just choose the appropriates ones to draw (and shift their screen positions accordingly).

[ TriangularPixels.com - Play Growth Spurt, Rescue Squad and Snowman Village ] [ Rebirth - game resource library ]
Offline MickeyB

Senior Devvie




my game will work, my game will work!


« Reply #2 - Posted 2003-04-20 15:35:42 »

so the "world" map could be 1276*1024 and the view window of the 'camera' is 400*300.  

I want to draw my camera contents for x=100 y=100 plus appropriate width and height.

Sounds good, Ill take a crack at it.

thanks

M

MickeyB

Current Project: http://www22.brinkster.com/mbowles/
Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline Jeff

JGO Coder




Got any cats?


« Reply #3 - Posted 2003-04-21 17:17:39 »

An intermediate solution is to use a "background buffer" for the floor and only redraw it when the camera shofts (generally all you have to do is blt it "over" and redraw the exposed areas.

The disadvantage of this approach is that it assumes that tiles are only going to be sued for the floor.  Anything that "stands up" has to be an object or "sprite" depending on youir favorite terminology.

Got a question about Java and game programming?  Just new to the Java Game Development Community?  Try my FAQ.  Its likely you'll learn something!

http://wiki.java.net/bin/view/Games/JeffFAQ
Pages: [1]
  ignore  |  Print  
 
 

 
hadezbladez (358 views)
2018-11-16 13:46:03

hadezbladez (190 views)
2018-11-16 13:41:33

hadezbladez (361 views)
2018-11-16 13:35:35

hadezbladez (90 views)
2018-11-16 13:32:03

EgonOlsen (2190 views)
2018-06-10 19:43:48

EgonOlsen (2226 views)
2018-06-10 19:43:44

EgonOlsen (1384 views)
2018-06-10 19:43:20

DesertCoockie (2022 views)
2018-05-13 18:23:11

nelsongames (1674 views)
2018-04-24 18:15:36

nelsongames (2312 views)
2018-04-24 18:14:32
Deployment and Packaging
by mudlee
2018-08-22 18:09:50

Java Gaming Resources
by gouessej
2018-08-22 08:19:41

Deployment and Packaging
by gouessej
2018-08-22 08:04:08

Deployment and Packaging
by gouessej
2018-08-22 08:03:45

Deployment and Packaging
by philfrei
2018-08-20 02:33:38

Deployment and Packaging
by philfrei
2018-08-20 02:29:55

Deployment and Packaging
by philfrei
2018-08-19 23:56:20

Deployment and Packaging
by philfrei
2018-08-19 23:54:46
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!