How do I insert small map in my big game.

0 favourites
  • 8 posts
From the Asset Store
Two types of minimap: "full map" and "player is the center" (square map and radial map)
  • I have really high resolution game 6400X6400 And the player navigates the game with ScrollTo Behavior.

    My question is it possible to make a small map of the game as there are in many games

    i add picture to explain the question.

  • This kinda depends on how many objects you want to show on your map. In general it's not really hard - have an object on the map as well and on every tick set its coordinates to, for example, map's left corner + original objects X location/map size ratio. So, say, if your map is 64x64 px that is 100 times smaller you would set the map objects coordinates to map's left corner + OriginalObject.X/100

    Same for Y coordinates, of course and you are done.

  • This kinda depends on how many objects you want to show on your map. In general it's not really hard - have an object on the map as well and on every tick set its coordinates to, for example, map's left corner + original objects X location/map size ratio. So, say, if your map is 64x64 px that is 100 times smaller you would set the map objects coordinates to map's left corner + OriginalObject.X/100

    Same for Y coordinates, of course and you are done.

    Thanks but I did not understand anything. I would be happy if you explain to me again. I have to use a special object or I need to build the map alone?

  • The map won't just appear - you basically draw it as a usual map would be done - at a smaller scale than your level. Then place that as an image and show object placement on it by using that same scale you drew your map in.

    I went ahead and built an example - study it and you should manage to make your own.

  • Cool that's exactly what I was looking for. Thank you very much.

  • Sure thing, just pay attention to the origin point of the map - as the coordinates of the main view go from top left to bottom right so they must on the minimap. Thus place the origin point on the minimap on the top left as well.

  • Somebody i try implement you map to my game, layout have 10000, 7777 px i create map 10x smaller, Player on start of layout is on middle of layout.

    Dot is not displayed anywhere, how fix this?

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Well, it's impossible to tell, using this given information, is it? What you need to do is explained above - set the dot location to map location + player location/10 (or whatever is appropriate). Also make sure the dot is ABOVE the map in Z order.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)