コード例 #1
0
 private void Start()
 {
     motor    = GetComponent <playerMotor>();
     joint    = GetComponent <ConfigurableJoint>();
     animator = GetComponent <Animator>();
     setJointSettings(jointSpring);
 }
コード例 #2
0
 void Awake()
 {
     if (pc == null)
     {
         pc = gameObject.GetComponent <playerController> ();
     }
     if (pmotor == null)
     {
         pmotor = gameObject.GetComponent <playerMotor> ();
     }
 }
コード例 #3
0
    void Start()
    {
        /*   Debug.Log(canvasManager.instance.text.text);
         * if(Application.isMobilePlatform)
         * lookSensitivity=float.Parse(canvasManager.instance.text.text);
         */
        lookSensitivity   = 3.0f;
        lookInputStopping = new Vector2(1, 1);
        motor             = gameObject.GetComponent <playerMotor>();

        rightFingerId = -1;

        // only calculate once
        halfScreenWidth = Screen.width / 2;

        //PlayerController.lookSensitivity=sens;

        // calculate the movement input dead zone
        //moveInputDeadZone = Mathf.Pow(Screen.height / moveInputDeadZone, 2);
    }
コード例 #4
0
ファイル: score.cs プロジェクト: facybenbook/subway-surfers
    private void Start()
    {
        Instance     = this;
        completedBar = new Color32(51, 202, 9, 255);
        motor        = GameObject.FindGameObjectWithTag("Player").GetComponent <playerMotor>();

        //set images unactive
        loveContainer.SetActive(false);


        //get skill bars
        skill1_level1 = GameObject.Find("skill1 lvl 1");
        skill1_level2 = GameObject.Find("skill1 lvl 2");
        skill1_level3 = GameObject.Find("skill1 lvl 3");

        skill2_level1 = GameObject.Find("skill2 lvl 1");
        skill2_level2 = GameObject.Find("skill2 lvl 2");
        skill2_level3 = GameObject.Find("skill2 lvl 3");

        skill3_level1 = GameObject.Find("skill3 lvl 1");
        skill3_level2 = GameObject.Find("skill3 lvl 2");
        skill3_level3 = GameObject.Find("skill3 lvl 3");


        if (skill1_points >= 1) //sports
        {
            skill1_levelUp();
        }
        else if (skill2_points >= 1) //arts
        {
            skill2_levelUp();
        }
        else if (skill3_points >= 1) //brains
        {
            skill3_levelUp();
        }
        else
        {
            return;
        }
    }
コード例 #5
0
ファイル: playerController.cs プロジェクト: Jos3Luiz/RPGDP_2
 void Start()
 {
     //main camera avaiable in the  scene
     camera = Camera.main;
     motor  = GetComponent <playerMotor>();
 }
コード例 #6
0
 void Start()
 {
     currentplayer = PlayerPrefs.GetString("CurrentPlayer");
     PM            = GetComponent <playerMotor> ();
 }
コード例 #7
0
 private void Start()
 {
     motor = GetComponent <playerMotor>();
 }
コード例 #8
0
 void Start()
 {
     motor = GetComponent <playerMotor>();
     anim  = GetComponent <Animator>();
 }
コード例 #9
0
    void Start()
    {
        motor = GetComponent <playerMotor>();

        audioSource = GetComponent <AudioSource>();
    }
コード例 #10
0
 // Use this for initialization
 void Start()
 {
     cam   = Camera.main;
     motor = GetComponent <playerMotor>();
 }
コード例 #11
0
 private void Awake()
 {
     player = GameObject.FindGameObjectWithTag("player").GetComponent <playerMotor>();
 }
コード例 #12
0
 void Start()
 {
     //Cursor.lockState = CursorLockMode.Locked; // Locks the mouse pointer in center and make it invisible.
     motor = GetComponent <playerMotor>();
 }
コード例 #13
0
ファイル: EnemyMotor.cs プロジェクト: ABilesck/Clicker-Game
 // Start is called before the first frame update
 void Start()
 {
     player        = GameObject.FindGameObjectWithTag("player").GetComponent <playerMotor>();
     currentHealth = MaxHealth;
     animator      = GetComponent <Animator>();
 }