16 lines
316 B
C#
Executable file
16 lines
316 B
C#
Executable file
using System.Collections;
|
|
using System.Collections.Generic;
|
|
using UnityEngine;
|
|
|
|
public class WindForce : MonoBehaviour
|
|
{
|
|
public float WindF;
|
|
public bool IsWind;
|
|
void Start()
|
|
{
|
|
if (IsWind)
|
|
{
|
|
Physics2D.gravity = new Vector3(WindF, -9.81f);
|
|
}
|
|
}
|
|
}
|