• Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
Question by Yanger_xy · Mar 26, 2011 at 02:26 PM · maplinegl

How to create a Mini Map at runtime

hi, guys. I wanna to create a mini-map at runtime, and i have some points that represent the road, and when the character moves, it is reflected to the mini map, how can i realize it? using the GL class or Gizmal? Is there some good idea?

Any reply will be apprecaite

Comment
BeHappy

People who like this

1 Show 0
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

2 Replies

· Add your reply
  • Sort: 
avatar image
Best Answer

Answer by Scribe · Mar 26, 2011 at 02:41 PM

hi, you might want to check out this answer:

http://answers.unity3d.com/questions/18307/mini-map-radar-screen-with-different-blips

which is related to this demo:

http://www.dastardlybanana.com/radarDemoWebPlayer.htm

and this is where to download it:

http://www.dastardlybanana.com/radarPage.htm

it is very easy to edit.

If your more looking for a camera image from above the player there is this answer:

http://answers.unity3d.com/questions/6913/how-do-i-attach-a-camera-to-a-gui-for-a-mini-map

next time please search the site for answers before asking the exact same thing. I spent about 30 seconds searching

Comment
Yanger_xy

People who like this

1 Show 5 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image Yanger_xy · Mar 26, 2011 at 04:15 PM 0
Share

Thank you very much. in fact, i have searched it on this website, i just searched the tag "mini-map" and got no satisfying result. However, i know how to realize the radar, but it's not exactly what i want,the question that i am concerned about is that how can i draw the road in a specific area dynamicly.

avatar image Scribe · Mar 26, 2011 at 06:15 PM 0
Share

sorry I didn't understand your question and I still don't fully, are you trying to create a radar type thing with a map OR are you building a road at runtime in a specified area. Sorry been ill the last couple of days probably me just being a bit slow

avatar image Yanger_xy · Mar 26, 2011 at 11:43 PM 0
Share

Maybe it's my fault! my question seems not to be clear.And here, i will state my view again with a example: There is a character in my Terrain, and the terrain is very large, also, the terrain is generated at runtime. And i have some points measured by the Measuring Department that respect the road, what is important is that, the road points are not fixed.So, i must draw it at runtime,so is in the radar.

avatar image Yanger_xy · Mar 26, 2011 at 11:44 PM 0
Share

In brief, i wanna to draw a radar which can draw the road dynamicly.For example, when the character moves into limited range, draw the road on the radar, if the character moves out, the road disapper too.

avatar image SuIXo3 · Jul 27, 2012 at 10:43 AM 0
Share

So the road is hidden by the "fog of war" on the minimap, right?

avatar image

Answer by jorjdboss · Jul 27, 2012 at 09:04 AM

I did it this way and it works out pretty well. From Daniel's answer above, follow the last link to attaching a second camera for a gui minimap. This method works fine except that both cameras render the same thing wasting performance. So to avoid rendering twice, you could do this:

  1. Create a separate layer called something like 'minimap'

  2. Set the second camera's culling mask(in inspector) to render only this layer. Similarly uncheck rendering of minimap layer in main camera's culling mask.

  3. Ask your artist to give you a picture of the top view of the environment. This need's to be approximately 1/4th the size of the target resolution.

  4. In Unity place a plane in the middle of your environment and scale it evenly till it fits the entire location.

  5. Apply the picture from the artist onto this plane and change the material if needed.

  6. Scale it and move it till it matches the actual environment. Change the plane's layer to 'minimap'

So the main camera renders everything except minimap layer, and second camera renders only minimap layer.

For showing elements on the minimap:

  1. Attach planes to each character/object you want to show on the minimap, facing upwards.

  2. Change the texture to an arrow/circle(or whatever you want it to look like on the minimap)

  3. For each plane change the layer to 'minimap' and Voila! a proper minimap

Comment

People who like this

0 Show 0 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Welcome to Unity Answers

If you’re new to Unity Answers, please check our User Guide to help you navigate through our website and refer to our FAQ for more information.

Before posting, make sure to check out our Knowledge Base for commonly asked Unity questions.

Check our Moderator Guidelines if you’re a new moderator and want to work together in an effort to improve Unity Answers and support our users.

Follow this Question

Answers Answers and Comments

2 People are following this question.

avatar image avatar image

Related Questions

Assigning UV Map to model at runtime 0 Answers

GL.LINES cannot switch colors 1 Answer

How to render GL.Line in front of UI canvas? 0 Answers

Create a circle or ellipse with the GL class 1 Answer

GL.Line help? Cannot see line drawn... draw grid using gl.line 4 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges