コード例 #1
0
    // Use this for initialization
    void Start()
    {
        objectMesh = GetComponent<MeshRenderer>();

        // Disable the mesh renderer component
        objectMesh.enabled = false;

        // Get all the cube pickups in the level
        getPickUps();

        // Reference the playerSphere
        getPlayer();

        // Reference the hudManager
        mainHUD = FindObjectOfType<hudManager>();
    
        // Get the audio source component
        getClockAudioSource();

        // Set clock audio clip
        setClockAudioClip();

        clockSoundManager = FindObjectOfType<ClockSoundManager>();

        playerScore = 0;

        targetScore = setTargetScore;

        defaultClockLength = clockLength;

        print(targetScore);

    }
コード例 #2
0
ファイル: flinch.cs プロジェクト: JamesIdahosa/Game-Sample
 void Start()
 {
     if (isLocalPlayer)
     {
         hudmanager = GameObject.Find("Canvas").GetComponent <canvasManager> ().hud;
     }
 }
コード例 #3
0
 // Start is called before the first frame update
 void Start()
 {
     isInControl = !isMenuScreen;
     fadeOut(6f);
     hudManager = GameObject.Find("MainUI").GetComponent <hudManager>();
     fadedTime  = 1.5f;
     fadeinTime = 0.6f;
     exit       = GameObject.Find("Exit");
     StartCoroutine(LateStart());
 }
コード例 #4
0
 void Awake()
 {
     if (_instance != null && _instance != this)
     {
         Destroy(this.gameObject);
     }
     else
     {
         _instance = this;
     }
 }
コード例 #5
0
 // Start is called before the first frame update
 void Start()
 {
     hudManager = GameObject.Find("MainUI").GetComponent <hudManager>();
     gm         = GameObject.Find("GameManager").GetComponent <GameManager>();
 }
コード例 #6
0
ファイル: hudManager.cs プロジェクト: PCtzonoes/Unity
 public hudManager()
 {
     Singleton = this;
 }