示例#1
0
    // Start is called before the first frame update
    void Start()
    {
        balloonRb    = GetComponent <Rigidbody2D>(); //get rigidbody2D component
        balloonHinge = GetComponent <HingeJoint2D>();

        playerSwipe     = FindObjectOfType <WindSwipe>();
        theCam          = FindObjectOfType <CameraController>();
        theLM           = FindObjectOfType <LevelManager>();
        balloonPopSound = GameObject.Find("Balloon Pop Sound").GetComponent <AudioSource>();
    }
    private void Start()
    {
        playerRb = GetComponent <Rigidbody2D>();

        theBalloon = FindObjectOfType <Balloon>();
        theWind    = FindObjectOfType <WindSwipe>();

        timeBefChangeWind = startTimeBefChangeWind; //set time to be starting time

        //StartCoroutine(RunGame());
    }
    // Start is called before the first frame update
    void Start()
    {
        LevelStrings();
        starsHolder.SetActive(true);

        starCount = 0;

        PlayerPrefs.GetInt(highScore); //get the max stars count for this level

        playerSwipe = FindObjectOfType <WindSwipe>();
        theStars    = FindObjectOfType <StarScript>();
        theCam      = FindObjectOfType <CameraController>();

        //by default, win and lose screens are set inactive at start
        winScreen.SetActive(false);
        loseScreen.SetActive(false);
    }
示例#4
0
    // Start is called before the first frame update
    void Start()
    {
        LevelStrings();
        starsHolder.SetActive(true);

        starCount = 0;

        PlayerPrefs.GetInt(highScore);     //get the max stars count for this level
        PlayerPrefs.GetInt("TypeOfCrate"); //get the type of crate selected

        theAdsController = FindObjectOfType <AdController>();
        playerSwipe      = FindObjectOfType <WindSwipe>();
        theStars         = FindObjectOfType <StarScript>();
        theCam           = FindObjectOfType <CameraController>();
        balloonScript    = FindObjectOfType <Balloon>();

        //by default, win and lose screens are set inactive at start
        winScreen.SetActive(false);
        loseScreen.SetActive(false);
    }