示例#1
0
    // Update is called once per frame
    void Update()
    {
        if (gameover.GetGameOver() || gameover.GetClear())
        {
            Destroy(gameObject);
        }

        pos_player = player.position;
        //移動計算式
        pos_player        += teleportation * guageController.GetTime() * Time.deltaTime;
        transform.position = pos_player;
    }
示例#2
0
    void GoGauge()
    {
        Vector2 pos = transform.position; //現在位置をposに代入

        if (!gaugeController.GetGauge())
        {
            //移動計算式
            pos += teleportation * gaugeController.GetTime() * Time.deltaTime;
            gaugeController.GetResetTime();

            if (hit)
            {
                Item.Outitem();
            }
        }
        transform.position = pos; //現在の位置にteleportationの移動距離を加算

        //if (test.gameObject.tag == "DeathZone"&&Item.getitem()) { Item.Outitem(); }
    }