How do you make the minimap show only discovered terrain?

This forum is currently in read-only mode.
  • I am making a platform game with a minimap. The levels in my platform game will have many secrets and traps. I tried making the minimap display the level terrain but it ends up spoiling all the secret areas that I don't want the player to see.

    I want something like the minimap in Super Metroid, where you can only see the areas on the map that you've actually been to. As you advance through the level, you begin to reveal more and more of the map.

    How exactly do I go about doing this though?

    Edit: Here is the .cap file I'm working on, if you want to look at it:

    http://machriderx.googlepages.com/minimapexample.cap

    Also, on a related note, how do I make it so that the minimap is not zoomed so far out? I want the minimap to be zoomed in a bit closer to the action rather than zoomed all the way out.

  • You could probably create a screen sized brick that always follows you around. If said brick collides with terrain pieces, it can set a value, such as 'discovered', to 1. That way, you can do something like:

    +If terrain('discovered') is equal to 1
    -Plot terrain on map[/code:3w3ngdds]
    
    Can't say will actually work, but it's probably worth a shot.
  • Nevermind, I figured it out. It was rather simple. All I had to do was "If "Tile" is on screen" then "draw terrain "Tile" on minimap" and it worked.

    The only thing is though, I used quick backdrops for a large portion of the tiles (I got tired of cutting and pasting tiles over and over again), and this ends up showing the entire batch of tiles all at once rather than one at a time, revealing huge chunks of the level that I don't want the player to see yet.

    I guess I could replace the quick backdrops all with single tiles, but that really is a pain.

    Edit: Anyway, here's an updated cap (with only quick backdrops shown on the minimap, notice how much of the level gets shown).

    http://machriderx.googlepages.com/quick ... roblem.cap

    Time to start replacing those quick backdrops with single tiles, I guess. That is, unless someone knows a way around this.

    Oh and btw, I also would still like to know how to zoom in more on the minimap if anyone knows.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • (Don't have access to Cons at the moment)

    I don't know what you've posted, but have you thought about making a Canvas object with effect "mask"? That'd be good for pixel perfect map revealing.

  • Dunno if that helps i was working on a game and have made something like that

    -day\night effect

    -attack

    -minimap

    -small interface

    M - show map

    Crtl - attack ( if you have a sword)

    Spacebar + direction keys -> browsing trought yhe menu

    http://www.speedyshare.com/595271361.html

  • Dunno if that helps i was working on a game and have made something like that

    -day\night effect

    -attack

    -minimap

    -small interface

    M - show map

    Crtl - attack ( if you have a sword)

    Spacebar + direction keys -> browsing trought yhe menu

    http://www.speedyshare.com/595271361.html

    Hmm.. interesting. You used the canvas object to obscure the regions of the map that haven't been discovered yet. I never thought of that.

    Maybe I might be able to do something with the canvas object. The only thing is that I don't want the actual level to be blacked out since it is a platform game (with jumping and platforms) and blacking out parts of the level could be fatal.

    I'm going to try messing around with it and seeing what I can do.

    Also, I still want to know, is there a way to make the minimap zoom in closer?

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