bool isGoUP = false; // 上方向に移動中かどうか // Use this for initialization void Start() { generalFunc = new GeneralFunc(); // 上下どちらに移動するか決定 isGoUP = generalFunc.RandomBool(); }
// Use this for initialization void Start() { generalFunc = new GeneralFunc(); // スプライトレンダラ取得 // 画像の左右反転に使用する spRender = GetComponent <SpriteRenderer>(); // ボートの向きをランダムに決める isLeft = generalFunc.RandomBool(); spRender.flipX = isLeft; }