using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class BowlingBall : MonoBehaviour
{
public float forwardForce;
public float leftBorder;
public float rightBorder;
public float moveIncrement;
public Rigidbody rig;
public void Bowl ()
{
rig.AddForce(transform.forward * forwardForce, ForceMode.Impulse);
}
public void MoveLeft()
{
transform.position += new Vector3(-moveIncrement, 0, 0);
}
}
Preview:
downloadDownload PNG
downloadDownload JPEG
downloadDownload SVG
Tip: You can change the style, width & colours of the snippet with the inspect tool before clicking Download!
Click to optimize width for Twitter