Search code examples
c#dictionaryunity-game-enginescaleresolution

how to adapt the resolution of a map according to the altitude of an airplane in unity?


I have a map with fixed size and I want to vary the resolution of map according to the altitude of my airplane. So I think to change the scale of my plane when the plane is on the ground since I have the constraint of size of land that is fixed. Any unity code to solve my problem ?


Solution

  • Make the camera part of the object hierarchy you want to follow. Move the camera at the top of the object facing downwards. In that way if the object changes altitude, the map will automatically be un-zoomed.

    If you face a problem making this kind of map you may follow this link to learn to create one. https://www.youtube.com/watch?v=28JTTXqMvOU

    I have made this kind of map previously, it just works fine.