<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
	<title type="html"><![CDATA[Infinity Code Forum — How to make 3D map fullscreen?]]></title>
	<link rel="self" href="https://forum.infinity-code.com/extern.php?action=feed&amp;tid=650&amp;type=atom" />
	<updated>2017-09-21T11:29:57Z</updated>
	<generator>PunBB</generator>
	<id>https://forum.infinity-code.com/viewtopic.php?id=650</id>
		<entry>
			<title type="html"><![CDATA[Re: How to make 3D map fullscreen?]]></title>
			<link rel="alternate" href="https://forum.infinity-code.com/viewtopic.php?pid=2831#p2831" />
			<content type="html"><![CDATA[<p>You are going in the wrong direction.<br />You do not need to make a round fullscreen map.<br />In your case, this is much easier.<br />You just need to set up fog and &quot;Camera / Clipping Planes / Far&quot; in your scene.<br />Something like:<br /><a href="http://forum.infinity-code.com/viewtopic.php?pid=1423#p1423">http://forum.infinity-code.com/viewtopi … 1423#p1423</a></p>]]></content>
			<author>
				<name><![CDATA[Alex Vertax]]></name>
				<uri>https://forum.infinity-code.com/profile.php?id=2</uri>
			</author>
			<updated>2017-09-21T11:29:57Z</updated>
			<id>https://forum.infinity-code.com/viewtopic.php?pid=2831#p2831</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: How to make 3D map fullscreen?]]></title>
			<link rel="alternate" href="https://forum.infinity-code.com/viewtopic.php?pid=2829#p2829" />
			<content type="html"><![CDATA[<p>Thank you, it makes the map size equal to screen size initially, but if I will change the angle of the camera I will see the map &quot;floating in the air&quot;. Is there a way to always keep it fullscreen, just like in a car navigator apps for example?</p>]]></content>
			<author>
				<name><![CDATA[Rumata]]></name>
				<uri>https://forum.infinity-code.com/profile.php?id=537</uri>
			</author>
			<updated>2017-09-20T15:04:07Z</updated>
			<id>https://forum.infinity-code.com/viewtopic.php?pid=2829#p2829</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: How to make 3D map fullscreen?]]></title>
			<link rel="alternate" href="https://forum.infinity-code.com/viewtopic.php?pid=2805#p2805" />
			<content type="html"><![CDATA[<p>Hello.</p><p>Example:<br /></p><div class="codebox"><pre><code>using UnityEngine;

public class AdjustMapToScreen2 : MonoBehaviour
{
    private int screenWidth;
    private int screenHeight;

    private void ResizeMap()
    {
        screenWidth = Screen.width;
        screenHeight = Screen.height;

        int mapWidth = screenWidth / 256 * 256;
        int mapHeight = screenHeight / 256 * 256;
        if (screenWidth % 256 != 0) mapWidth += 256;
        if (screenHeight % 256 != 0) mapHeight += 256;
        OnlineMapsTileSetControl.instance.Resize(mapWidth, mapHeight);

        OnlineMapsTileSetControl.instance.cameraDistance = screenHeight * 0.9f;
    }

    private void Start()
    {
        ResizeMap();
    }

    private void Update()
    {
        if (screenWidth != Screen.width || screenHeight != Screen.height) ResizeMap();
    }
}</code></pre></div>]]></content>
			<author>
				<name><![CDATA[Alex Vertax]]></name>
				<uri>https://forum.infinity-code.com/profile.php?id=2</uri>
			</author>
			<updated>2017-09-14T23:20:42Z</updated>
			<id>https://forum.infinity-code.com/viewtopic.php?pid=2805#p2805</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[How to make 3D map fullscreen?]]></title>
			<link rel="alternate" href="https://forum.infinity-code.com/viewtopic.php?pid=2802#p2802" />
			<content type="html"><![CDATA[<p>How can I make a 3D map to always take a full screen of the phone, regardless of the screen orientation?<br />Thank you!</p>]]></content>
			<author>
				<name><![CDATA[Rumata]]></name>
				<uri>https://forum.infinity-code.com/profile.php?id=537</uri>
			</author>
			<updated>2017-09-14T18:13:39Z</updated>
			<id>https://forum.infinity-code.com/viewtopic.php?pid=2802#p2802</id>
		</entry>
</feed>
