Last active
June 7, 2017 07:00
-
-
Save muzudho/fbc1db8c80c22646ebaa9af4e7897626 to your computer and use it in GitHub Desktop.
ゲーム開発を受注しようぜ<その3> Unity2Dで 画面の中にキャラクターを置こうぜ ref: http://qiita.com/muzudho1/items/4ee198296d620da0b8fa
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Tile1 ゲーム・オブジェクトを作る | |
GameObject go = new GameObject("Tile1", typeof(SpriteRenderer)); | |
// 在るものから探す場合 | |
// GameObject go = GameObject.Find("Tile1"); | |
SpriteRenderer rend = go.GetComponent<SpriteRenderer>(); | |
rend.sortingLayerName = "Ground"; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment