villaskin.blogg.se

Two player gravity guy
Two player gravity guy




two player gravity guy

The moves of the personalities are smooth as well as the number of attacks including slow activity kills make. G-Switch 3 is an exciting runner game with multiplayer mode. The stick numbers might not electric man 2 seem sensible however when you start playing the game you recognize that its not so important. UnityEngine.Vector3 moveDir = (0f, targetAngle, 0f) * Ĭontroller.Move(moveDir.normalized * speed * Time. Electric Man is a combating game with instead poor graphics however simply fantastic gameplay. UnityEngine.Vector3 direction = new UnityEngine.Vector3(horizontal, 0f, vertical).normalized įloat targetAngle = Mathf.Atan2(direction.x, direction.z) * Mathf.Rad2Deg + įloat angle = Mathf.SmoothDampAngle(, targetAngle, ref turnSmoothVelocity, turnSmoothTime) Movement script: public class ThirdPersonMovement : MonoBehaviourįloat horizontal = Input.GetAxisRaw("Horizontal") įloat vertical = Input.GetAxisRaw("Vertical")

Two player gravity guy how to#

I made the Gravity script myself but I followed a tutorial on the player movement script because I have no idea how to make third person movement so I don't really know what is going on in the movement script. The reason I am using a gravity script is that the third person movement doesn't support using a rigidbody with position and rotation enabled, so I have frozen the position and the rotation inside the rigidbody (which turns off gravity in the rigidbody).

two player gravity guy

I am quite new to unity and I have two scripts, one for gravity and one for player movement as the names suggest.






Two player gravity guy