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

Why am I getting this error CS1061 ?!

$
0
0
Hey! im following a tutorial on 3d movement based on Unity's more recent input system. The error that I'm getting is: 'PlayerControls' does not contain a definition for 'PlayerMovement' and no accessible extension method 'PlayerMovement' accepting a first argument of type 'PlayerControls' could be found (are you missing a using directive or an assembly reference?) [Assembly-CSharp]csharp(CS1061) My code: using System.Collections; using System.Collections.Generic; using UnityEngine; public class InputManager : MonoBehaviour { PlayerControls playerControls; public Vector2 movementInput; private void OnEnable() { if (playerControls == null) { playerControls = new PlayerControls(); playerControls.PlayerMovement.Movement.performed += i => movementInput = i.ReadValue(); } playerControls.Enable(); } private void OnDisable() { playerControls.Disable(); } }

Viewing all articles
Browse latest Browse all 2891

Trending Articles



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