using System.Collections; using System.Collections.Generic; using UnityEngine; public class MapOffsetMove : MonoBehaviour { public Vector2 speed = new Vector2(0.02f, 0.02f); private MeshRenderer m_Render = null; void Start () { m_Render = GetComponent(); // mRender.material.SetTextureScale("_MainTex", new Vector2(1, 1)); } void Update () { m_Render.material.SetTextureOffset("_MainTex", new Vector2(1 + Time.time * speed.x, 1 + Time.time * speed.y)); } }