Beispiel #1
0
    void GenMap0()
    {
        Map map = new Map();
        map.Init();
        //扰乱边缘
        NoisyEdges noisyEdge = new NoisyEdges();
        noisyEdge.BuildNoisyEdges(map);

        new MapTexture(TextureScale).AttachTexture(GameObject.Find("Map"), map, noisyEdge);
    }
Beispiel #2
0
    void GenMap0()
    {
        Map map = new Map();

        map.Init();
        //扰乱边缘
        NoisyEdges noisyEdge = new NoisyEdges();

        noisyEdge.BuildNoisyEdges(map);

        new MapTexture(TextureScale).AttachTexture(GameObject.Find("Map"), map, noisyEdge);
    }
Beispiel #3
0
    private void GenMap()
    {
        Random.seed = 1;
        _txtTexture = GetTextTexture();

        Map.Width = Width;
        Map.Height = Height;
        Map map = new Map();
        map.SetPointNum(_pointNum);
        map.Init(CheckIsland());
        //扰乱边缘
        NoisyEdges noisyEdge = new NoisyEdges();
        noisyEdge.BuildNoisyEdges(map);

        new MapTexture(TextureScale).AttachTexture(_showMap, map, noisyEdge);
    }
Beispiel #4
0
//    void Update()
//    {
//        if (_map != null && _map.SelectedCenter != null)
//        {
//            _selector.transform.localPosition = new Vector3(_map.SelectedCenter.point.x, _map.SelectedCenter.point.y, 1);
//        }
//    }

	void Awake ()
	{
        _selector = GameObject.Find("Selector");

        //Random.seed = 1;
            
        _map = new Map();
        _map.Init();

        GameObject.Find("Main MyCamera").GetComponentInChildren<MyCamera>().Map = _map;

        //ÈÅÂÒ±ßÔµ
        NoisyEdges noisyEdge = new NoisyEdges();
        noisyEdge.BuildNoisyEdges(_map);

        new MapTexture(_textureScale).AttachTexture(GameObject.Find("Map"), _map,noisyEdge);
	}
Beispiel #5
0
    private void GenMap()
    {
        Random.seed = 1;
        _txtTexture = GetTextTexture();

        Map.Width  = Width;
        Map.Height = Height;
        Map map = new Map();

        map.SetPointNum(_pointNum);
        map.Init(CheckIsland());
        //扰乱边缘
        NoisyEdges noisyEdge = new NoisyEdges();

        noisyEdge.BuildNoisyEdges(map);

        new MapTexture(TextureScale).AttachTexture(_showMap, map, noisyEdge);
    }
Beispiel #6
0
//    void Update()
//    {
//        if (_map != null && _map.SelectedCenter != null)
//        {
//            _selector.transform.localPosition = new Vector3(_map.SelectedCenter.point.x, _map.SelectedCenter.point.y, 1);
//        }
//    }

    void Awake()
    {
        _selector = GameObject.Find("Selector");

        //Random.seed = 1;

        _map = new Map();
        _map.Init();

        GameObject.Find("Main MyCamera").GetComponentInChildren <MyCamera>().Map = _map;

        //ÈÅÂÒ±ßÔµ
        NoisyEdges noisyEdge = new NoisyEdges();

        noisyEdge.BuildNoisyEdges(_map);

        new MapTexture(_textureScale).AttachTexture(GameObject.Find("Map"), _map, noisyEdge);
    }