My Learning
Pathways
Guided learning journeys
Embark on a guided experience where you unlock free assets, prepare to get Unity Certified, and earn shareable badges to demonstrate your learning to future employers.
Unity Essentials
Pathway
Foundational
+600 XP
2 Weeks
Designed for anyone new to Unity, this guided learning journey is your first step toward gaining the background, context, and skills you need to confidently create in the Unity Editor and bring your vision to life. Experience hands-on learning as you discover what’s possible with Unity and unlock free assets to support you in creating your best projects. Completing this Pathway will equip you with the foundation you need to further your learning and specialize in your area of interest.  
Junior Programmer
Pathway
Beginner
+3000 XP
12 Weeks
Welcome to Junior Programmer! Designed for anyone interested in learning to code or obtaining an entry-level Unity role, this pathway assumes a basic knowledge of Unity and has no math prerequisites. Junior Programmer prepares you to get Unity Certified so that you can demonstrate your job-readiness to employers.
Browse
TOPICS
Editor EssentialsScriptingGraphics & Visual Effects2DMobile & TouchXRPhysicsUser InterfaceFor EducatorsAI & NavigationMore
Pathway
Mission
Course
Project
Tutorial
Guided learning experiences
Gain the Unity skills you need to advance your goals and bring your vision to life.
Unity Essentials
Pathway
Foundational
+600 XP
2 Weeks
Designed for anyone new to Unity, this guided learning journey is your first step toward gaining the background, context, and skills you need to confidently create in the Unity Editor and bring your vision to life. Experience hands-on learning as you discover what’s possible with Unity and unlock free assets to support you in creating your best projects. Completing this Pathway will equip you with the foundation you need to further your learning and specialize in your area of interest.  
Junior Programmer
Pathway
Beginner
+3000 XP
12 Weeks
Welcome to Junior Programmer! Designed for anyone interested in learning to code or obtaining an entry-level Unity role, this pathway assumes a basic knowledge of Unity and has no math prerequisites. Junior Programmer prepares you to get Unity Certified so that you can demonstrate your job-readiness to employers.
Live
TOPICS
Browse All Topics
ALL
TUTORIALS
PROJECTS
COURSES
MISSIONS
PATHWAYS
See all 0 Results
FAQ
Create a Unity ID
Sign in
FK
Flemming Kejs
Jul 17, 2020
I can't get the two-player game to work. The problem is getting the input from the players. I have tried in Unity to go to Edit -> Project Settings -> Input -> Axes. Here I have changed the name of the first Horizontal and Vertical to P1_Horizontal and P1_Vertical - and inside the definitions I defined Negative Button to a and s respectively and the Positive Button to d and w respectively - the Alt buttons were blanked.
Similarly I changed the name of the later Horizontal and Vertical to P2_Horizontal and P2_Vertical, and here I used left, right, down, up instead of a, d, s, w.
The PlayerController script was then set to use GetAxis("P1_Horizontal") (and Vertical - and same for P2), but when I run the game, only player1 works - player2 does not get any input.

I have downloaded the solution, and they use GetAxis("Vertical" + inputID) - meaning they have used Vertical1 and Vertical2, where I used P1_Vertical and P2_Vertical.

So my idea seems right - it just doesn't work. Does anybody have a clue about what I am doing wrong?

Comments
FK
Flemming Kejs
9 months ago
I guess you are right, Simon Jordan. I saw the web session, and here we were shown how to duplicate the Horizontal and Vertical definitions and changing the names. When I did the same, everything worked fine.
0
SJ
Simon Jordan
9 months ago
I think the later set of "Horizontal" and "Vertical" are specifically for Joypad support.
1
Copyright © 2021 Unity Technologies
Legal
Privacy Policy
Cookies
Cookies Settings
Language:
English
简体中文
한국어
日本語
Русский
Español
Français
Deutsch
Português