setorder.cs 407 B

12345678910111213141516171819
  1. using System.Collections;
  2. using System.Collections.Generic;
  3. using UnityEngine;
  4. public class setorder : MonoBehaviour {
  5. public int Intloyout = 80;
  6. // Use this for initialization
  7. void Start () {
  8. foreach (var render in GetComponentsInChildren<Renderer>(true))
  9. {
  10. render.sortingOrder = Intloyout;
  11. }
  12. }
  13. // Update is called once per frame
  14. void Update () {
  15. }
  16. }