示例#1
0
    private void SpawnMole(SpawnpointInGrass target)
    {
        mMoleWorking             = true;
        mMole.isDigging          = false;
        mMole.transform.position = target.transform.position;
        mMole.transform.rotation = target.transform.rotation;
        mMole.SetSortingLayer(target.sortingLayerName);

        mMole.ShowSprites();
        //mMole.Appear(AppearComplete);
    }
示例#2
0
    public void SpawnBee(SpawnpointInGrass target)
    {
        GameObject spawnedBee = GameObject.Instantiate(beePrefab, target.transform.position, Quaternion.identity) as GameObject;

        spawnedBee.GetComponent <SpriteRenderer>().sortingLayerName = target.sortingLayerName;

        if (isNight)
        {
            spawnedBee.GetComponent <SpriteRenderer>().color = nightTint;
        }

        beeNextSpawnTime = Time.time + beeSpawnTimeSpan;
    }