Hi !
Featured games (91)
games approved by the League of Dukes
Games in Showcase (757)
Games in Android Showcase (229)
games submitted by our members
Games in WIP (843)
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  
  Minimap with mobile frame  (Read 1971 times)
0 Members and 1 Guest are viewing this topic.
Offline Pagliaccio

Innocent Bystander

« Posted 2007-03-18 13:09:23 »

Hi there!

I'm currently developing a game in Java and I think this is the right subforum for the following question:

I want to make a "minimap" which erm... maps another bigger map and has this feature: a mobile frame in it that translates its moves into moves of the bigger map, that tipically may be embedded in a scrollable pane. So it must work both ways I assume, when you scroll through the map, the frame also moves in the minimap.

I'm totally clueless about it

Thanks in advance!
Offline Coinerson

Junior Devvie

Introducing the world's cutest zombie, Timmy

« Reply #1 - Posted 2007-03-18 22:14:52 »

1) what?
2) iterate through the big map's elements one at a time and draw a 2x2 or 1x1 rectangle with color depending on what is in the big map's element. Like draw a green rect if its a grass tile. But I don't really know what your asking.

I gather, maybe, that you want process clicks in the little map and translate them to the big map? You would do that the exact same way you do it on the big map. Just change tile size to 1 or 2 or however big each element on the little map is.

For scrolling, just find the starting X/Y and last X/Y that your large map is drawing, and draw the minimap based those.
Pages: [1]
  ignore  |  Print  

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

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

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

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

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

nelsongames (122 views)
2018-04-24 18:14:32

ivj94 (862 views)
2018-03-24 14:47:39

ivj94 (123 views)
2018-03-24 14:46:31

ivj94 (759 views)
2018-03-24 14:43:53

Solater (140 views)
2018-03-17 05:04:08
Java Gaming Resources
by philfrei
2017-12-05 19:38:37

Java Gaming Resources
by philfrei
2017-12-05 19:37:39

Java Gaming Resources
by philfrei
2017-12-05 19:36:10

Java Gaming Resources
by philfrei
2017-12-05 19:33:10

List of Learning Resources
by elect
2017-03-13 14:05:44

List of Learning Resources
by elect
2017-03-13 14:04:45

SF/X Libraries
by philfrei
2017-03-02 08:45:19

SF/X Libraries
by philfrei
2017-03-02 08:44:05 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‑
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!