Quantcast
Channel: Questions in topic: "error message"
Viewing all articles
Browse latest Browse all 2891

PlayerController.cs(8,8): Error CS0029: Cannot implicitly convert type 'UnityEngine.Rigidbody[]' to 'UnityEngine.Rigidbody' (CS0029) (Assembly-CSharp)

$
0
0
using UnityEngine; using System.Collections; public class PlayerController : MonoBehaviour { private Rigidbody rb; void Start () { rb = GetComponents(); } void FixedUpdate () { float moveHorizontal = Input.GetAxis ("Horizontal"); float moveVertical = Input.GetAxis ("Vertical"); Vector3 movement = new Vector3 (moveHorizontal, 0.0f, moveVertical); rb.AddForce (movement); } }

Viewing all articles
Browse latest Browse all 2891

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>