CONTROLLER INPUT in Unity!

  Рет қаралды 373,275

Brackeys

Brackeys

Күн бұрын

Пікірлер: 750
@Brackeys
@Brackeys 4 жыл бұрын
Hey everyone! To those of you who can't find the package: Unity has moved the "Show Preview Packages". You can now find it under Edit -> Project Settings -> Package Manager -> Enable Preview Packages. If you check that box, you should see preview packages in the Package Manager! :-) Stay awesome!
@thanitsakleuangsupornpong2449
@thanitsakleuangsupornpong2449 4 жыл бұрын
Anyone please. Should I use Incrontrol from Asset Store or Unity new Input System? Thanks in advance. What is better?
@filgas0892
@filgas0892 4 жыл бұрын
I does not find it, can change by unity version?
@Triarawn
@Triarawn 4 жыл бұрын
@@filgas0892 You can now find it in Package Manager, under the 'Advanced' tab. Hope this helps!
@filgas0892
@filgas0892 4 жыл бұрын
Triarawn I find it
@pedror1439
@pedror1439 4 жыл бұрын
uhh for me it’s causing errors from my player movement, is it because of the input? i tried deleting the input but I think it destroyed my game
@anthonyroseiro
@anthonyroseiro 4 жыл бұрын
If you can't select stick : click on Action -> action type -> value, then under it you can select stick. Now you can bind your stick and don't forget to save asset !
@lukascook8477
@lukascook8477 4 жыл бұрын
What a pro. This is why I love the internet. Thanks.
@loater
@loater 3 жыл бұрын
thx dude
@ilovemuffins1337
@ilovemuffins1337 3 жыл бұрын
For those wondering, "Action" is located when you press the green icon bar that we named "Move" (dont click the plus). There, it will show "Action" in the same place that binding normally shows
@minibuffness
@minibuffness 3 жыл бұрын
Thanks, very helpful!
@tageueland
@tageueland 3 жыл бұрын
Thank you
@Mattggiano
@Mattggiano 5 жыл бұрын
Only we programmers could be happy to see a cube spinning in an empty space. Thank you so much for the tutorial!
@kevinguiboche2359
@kevinguiboche2359 5 жыл бұрын
Lmao
@timgates8885
@timgates8885 4 жыл бұрын
:D
@blossumgames9443
@blossumgames9443 3 жыл бұрын
I somehow feel happy reading this :3
@JordanMaster-oe9jg
@JordanMaster-oe9jg 3 жыл бұрын
Gamers: This game is so boring Us programmers: It ToOk Me An HoUr To MaKe ThIs
@moonwatchereclipse5291
@moonwatchereclipse5291 3 жыл бұрын
@@JordanMaster-oe9jg lmao
@lAcedUpLiss
@lAcedUpLiss 3 жыл бұрын
My year 1 uni assignment is due and I wanted to use controller input. Thank you so much, this tutorial is a lifesaver! I'm so sad that you retired from YT, hands down my favourite teacher on here.
@PogPenguin
@PogPenguin 4 ай бұрын
hes back baby
@PixelDough
@PixelDough 5 жыл бұрын
Once I heard you say "allow us to avoid using strings" I immediately fell in love with this new input system. 10/10 tutorial.
@47Mortuus
@47Mortuus 4 жыл бұрын
if (Input.GetKeyDown(KeyCode.Return)) Sorry, i fail to see any strings...................
@PixelDough
@PixelDough 4 жыл бұрын
47Mortuus sure, yeah, if you’re using straight up keyboard inputs. We’re talking about controller support, which requires using the Input system’s “actions” with axis settings.
@47Mortuus
@47Mortuus 4 жыл бұрын
@@PixelDough I guess so - that what the new system is best at: controller and especially cross-platform support. But even then - I don't see how 10 bytes of garbage per frame (unless you don't have an input manager and actually call Input.GetAxisRaw() form more than one script) has any significance.
@tobihudiat
@tobihudiat 4 жыл бұрын
@@47Mortuus He meant Input.GetAxis("Horizontal") for example
@GameBientStudio
@GameBientStudio 4 жыл бұрын
Using movement that way has a really odd behaviour in which the movement of the stick isn't updated every time. Instead, I wrote move = controls.Gameplay.Move.ReadValue(); inside Update() and everything is working absolutely fine now. Hopefully this will help others watching this video. Thanks anyways to the Brackeys team educating me about how the new Input System works!
@JoelAbad
@JoelAbad 4 жыл бұрын
Unity 2019.3.12f1 on MacOS and Xbox One Controller. I wasn't able to select the "Left Stick" option on the Binding Path, only its child (Up, Down, Left, Right). What I did was select any of the child and pressing the small "T" button I changed the text to "/leftStick" and now it works fine.
@Glaas_
@Glaas_ 4 жыл бұрын
Thanks buddy, I was looking for this !
@elirockenbeck6922
@elirockenbeck6922 4 жыл бұрын
Sweet! Thank you!
@robert.lafferty
@robert.lafferty 4 жыл бұрын
I was looking at another video on how to do multiplayer with this system and they showed exactly how to do it without this workaround. Click on "Move" (for example), change Action Type to "Value", and then change the Control Type to "Stick". Then when you click listen, it'll show up as "Left Stick". Hope this helps! kzbin.info/www/bejne/emnRhnxubbWCi5o
@jacinthdanielmoses3647
@jacinthdanielmoses3647 4 жыл бұрын
What I did was was in the parent of the binding I turned the action type to “value” and the control type to “any”
@gabrielserra
@gabrielserra 4 жыл бұрын
LIFESAVER. thank you!
@White_Wolf_Studios_Gaming
@White_Wolf_Studios_Gaming 2 ай бұрын
I was stuck for three hours following other tutorials and documentation. This video worked in one try, thank you!
@kuteninja
@kuteninja 5 жыл бұрын
Beware when using lambda expressions on non volatile objects, since it's not possible to substract them, unless you save a reference to the lambda you'll create a new one if you write it again which won't be present on the action list.
@scorpion666lair
@scorpion666lair 5 жыл бұрын
I totally agree with this
@play4fun599
@play4fun599 5 жыл бұрын
And what objects are non volatile?
@michaelberna4836
@michaelberna4836 2 жыл бұрын
@@play4fun599 Hard drives
@MasterofGalaxies4628
@MasterofGalaxies4628 2 жыл бұрын
I'm sure there are at least a few users watching this wondering how to go about setting up multiple unique controllers for co-op/local multiplayer, and keeping any given input asset instance from receiving input data from EVERY SINGLE active device. Having struggled to figure this out myself months ago, especially since I also wanted to make it work with the auto-generated C# class feature as well to take advantage of all the safety features C# provides when working with it, I thought I'd share the solution I came up with, which uses a lesser-talked about feature of the New Input System called Input Users (note that in my example, "InputReference" is the name of the input action asset and by extension the C# class): using UnityEngine.InputSystem; using UnityEngine.InputSystem.Users; public class Player { public readonly InputReference Input; private InputUser User { get; } public Player(params InputDevice[] devices) { Input = new InputReference(); User = InputUser.CreateUserWithoutPairedDevices() User.AssociateActionsWithUser(Input); for (int i = 0; i < devices.Length; i++) InputUser.PerformPairingWithDevice(devices[i], User, i == 0 ? InputUserPairingOptions.UnpairCurrentDevicesFromUser : InputUserPairingOptions.None); } public void Decommission() { User.UnpairDevicesAndRemoveUser(); } } With this class, I could create a unique Player object for each active player. Notice in the constructor that in addition to the input action asset instance, an InputUser is also created, with which the input asset instance is then paired. Once that's done, each input device passed in to the constructor (the params allows for any number, letting me pass in, say, either a single controller, or a keyboard and mouse as a pair), is also paired to the InputUser. Now, the input asset instance will only receive events _from those specific devices_, which lets me register for a specific player's move/jump/whatever as opposed to _every_ player's move/jump/whatever and then needing to figure out which device it originated from. Note there's also a decommissioning method, to clear the user and pairings out if you need to deactivate a player. This will ensure device pairings, input user entries, and other behind-the-scenes things get cleaned up when you no longer need them.
@spotlessapple
@spotlessapple 2 жыл бұрын
Thank you! This solved my issue. Had to make a few small modifications to the original script being used in the video to reference this class, but works like a charm. In my case, I was using xbox controls (hence, XInputController class, see docs on the input system for other supported classes like DualShock). In my case, I named the same class you have above as "UniqueLocalMultiplayer": using UnityEngine.InputSystem; using UnityEngine.InputSystem.XInput; ... ... XInputController xboxInputController = (XInputController)GetComponent().devices[0]; var ulm = new UniqueLocalMultiplayer(xboxInputController); // Declared "input = new InputReference()" in class I copied from you, used lowercase for mine controls = ulm.input; controls.Player.Movement.performed... controls.Player.Movement.canceled... controls.Player.Jump.performed... ...
@Pardaleco2
@Pardaleco2 Жыл бұрын
Hello, is there any way I could talk with you somehow about this solution?
@aktchungrabanio6467
@aktchungrabanio6467 Жыл бұрын
@@Pardaleco2 I'm sorry babe but that can't happen
@cubeflinger
@cubeflinger 4 жыл бұрын
I dont know how I'm going to do this without you.
@noobgamerrd8366
@noobgamerrd8366 2 ай бұрын
I had so much trouble to understand the new input system as i have no programming background but this made my day thank you for the very easy to understand tutorial.
@jonteboimakesgames
@jonteboimakesgames 5 жыл бұрын
Thank you soooo much for the tutorial!!!!! I’ve been looking for this for soooo long! Awesome tutorial Brackeys!
@BartintVeld
@BartintVeld 5 жыл бұрын
I always created an InputManager that would fire events when a button was pressed. This completely removes the need to make an InputManager, COOL!
@ram97tabla
@ram97tabla 5 жыл бұрын
Hell ya thank you Brackeys, your smile and positive energy plus great content really keeps me motivated and learning as I learn the ins and outs of Game Development. Thank you so much!
@welltypedwitch
@welltypedwitch 5 жыл бұрын
Now what about multiple controllers (a.k.a. couch-coop)?!?
@TheAzuratis
@TheAzuratis 5 жыл бұрын
That's the same question I have.
@ZoidbergForPresident
@ZoidbergForPresident 5 жыл бұрын
Several ways of doing it: 1 Different actions per player: movePL1, movePL2 or 2 Different actions maps per player: gameplayPL1, gameplayPL2
@TheAzuratis
@TheAzuratis 5 жыл бұрын
And how do you differ bedween to two connected Gamepads?
@welltypedwitch
@welltypedwitch 5 жыл бұрын
@@ZoidbergForPresident Have you tried that? Itt doesn't seem like you can differentiate between Gamepads.
@synsam12345
@synsam12345 5 жыл бұрын
I would recommend the plug-in Rewired. It also handles different input from different gamepads.
@arcadebox
@arcadebox 4 жыл бұрын
dude u dont know how much i love your job always very simple to understand even if im not english and the best tuto on youtube THANKS
@robertcohn8858
@robertcohn8858 4 жыл бұрын
This is an exceptionally well-done tutorial. The content level, step-by-step instructions and subject matter are very clear. Thank you!
@MissAllesmere404
@MissAllesmere404 5 жыл бұрын
Oh my goodness this is SO much easier than Unity's old system! Can you use this same system to set multiple controller types, that the player can switch between? Such as switching between Keyboard/mouse and Controller, and using a config to set prefered actions to different keys? This could make accessibility access SO much easier to manage!
@AllyG1967
@AllyG1967 4 жыл бұрын
Thank, just what we were looking for. This is a great starting point. Next steps for us is to find out how to trigger animations using this method. Walk, Run, Jump, Punch, Kick.
@superzova
@superzova 5 жыл бұрын
THIS is the video I've been waiting for. Thank you!
@Manuel-cm1jg
@Manuel-cm1jg 5 жыл бұрын
can you make a multiplayer tutorial for unity 2019?
@brandonlee0115
@brandonlee0115 5 жыл бұрын
yesyesyesyesyes
@dan-mechanics2014
@dan-mechanics2014 5 жыл бұрын
Please
@dedovagency
@dedovagency 5 жыл бұрын
@@Goferek5 will it?
@gbnp5579
@gbnp5579 5 жыл бұрын
@@dedovagency i think its too coplicated to make a tutorial like that
@dedovagency
@dedovagency 5 жыл бұрын
@@gbnp5579 he's shown how to make FPS multiplayer game, it's not that hard for him to make updated multiplayer tutorial.
@zdvy
@zdvy 5 жыл бұрын
Can you make videos were you play games created or suggested by fans and this allows you to give them tips on what they can improve on and what you like about their game. That would be amazing to watch!
@a1be31s8x9
@a1be31s8x9 3 жыл бұрын
TY Brackeys you were a god among youtubers
@afluffycat9522
@afluffycat9522 5 жыл бұрын
I spent like a month trying to get it to work and now you're here telling me that the new input system makes it easy! DAMN IT Edit: I actually tried to recreate you're ballgame
@MikaelL
@MikaelL 2 жыл бұрын
Thanks Brackeys for this tutorial🙂
@theloafdude8304
@theloafdude8304 5 жыл бұрын
seriously. I've waited so long now, finally
@Gooseguy1000-1
@Gooseguy1000-1 2 жыл бұрын
I’m definitely comfortable with the getkey method of doing inputs but this seems like a great system to switch to for lots of reasons. Thanks Brackeys :)
@abhisheksuper20
@abhisheksuper20 5 жыл бұрын
Been waiting for way too long to get this video. Thanks Brackeys !!
@MSibrava
@MSibrava 4 жыл бұрын
OMG Thank you! Finally a simple explanation to what I walked into when I imported the new Input System!
@swiftgames5382
@swiftgames5382 5 жыл бұрын
Excellent! this is what I've been waiting for. Many thanks Brackeys.
@BilalKas
@BilalKas 2 жыл бұрын
great tutorial, searched for a lot of but this one was by far the best for me
@insertusernamehere8125
@insertusernamehere8125 4 жыл бұрын
Thanks! This helped because im making a fun local multiplayer fighting game real quick that I can play with my brother and friends
@huntserston3579
@huntserston3579 5 жыл бұрын
Nice! Now I can effectively switch between types of controllers or ways to play!
@fightinggamescombos6820
@fightinggamescombos6820 4 жыл бұрын
Never paid too much attention but not looking into it deeper it is much better indeed.
@iggythemad8701
@iggythemad8701 5 жыл бұрын
Hey there Brackeys! First of all: Thank you so much. Your tutorials are helping me a lot in my game dev journey. Second: I've got 2 questions. Why is this better than the old input system? Aaaand... Could you make a tutorial on navigating a UI with a controller? Like an inventory or something. Love youuu
@advaith_31
@advaith_31 3 жыл бұрын
HE LEFT US ;(
@ryanshirvani
@ryanshirvani 5 жыл бұрын
good video Brackeys the input for controllers works on lots of platforms thanks.
@mykytamarkianov4870
@mykytamarkianov4870 5 жыл бұрын
Thank you for this video! Sad... Jason's courses are to expensive for me(((
@Devsplorer
@Devsplorer 3 жыл бұрын
This was very helpful to understand the new Input System 🙌 I really liked using context
@tl9826
@tl9826 3 жыл бұрын
If you want to move the player on x and z axis, do the following: Change variable "Vector2 move;" to -> "Vector3 move;" The "void Awake()" section will not change, what you need to change is the "void Update()" part: From: Vector2 m = new Vector2(-move.x, move.y) * Time.deltaTime; To: Vector3 m = new Vector3(-move.x, 0, -move.y) * Time.deltaTime; Note that Vector3 takes 3 values(x, y, z). Use 0 in y and use "-move.y" as the z Same as for x move, the minus is to have that "non-inverted" behavior/feeling
@dane4944
@dane4944 3 жыл бұрын
Whoever you are, you just saved my skin and stopped me from going insane over this Thank You!!
@Radiofloyd
@Radiofloyd 3 жыл бұрын
Thank you.
@waynehawkins654
@waynehawkins654 3 жыл бұрын
Thank you so much, this was a well demo video. But we are now out of beta. I love to see a updated using the new Player Input and with the Behavior using 'Invoke C Sharp Events'
@michelangelobaroni938
@michelangelobaroni938 4 жыл бұрын
thank you!!! I really appreciate these tutorials! Something things get tricky, yet find errors is much satisfying :) DON'T GIVE UP!!!
@ImInfenix
@ImInfenix 5 жыл бұрын
THANK YOU was looking for it for now a month and wasn't able to find anything interesting allowing me to do what i wanted to
@Xeculus
@Xeculus 5 жыл бұрын
EXACTLY WHAT I WAS LOOKING FOR! No need to look elsewhere now lol
@noahhildebrandt1298
@noahhildebrandt1298 5 жыл бұрын
Thank you for the video - I was wondering how this new system was turning out. From first glance, this looks unnecessarily clunky and complicated. I'm happy I invested in Rewired awhile ago - much easier/cleaner syntax and setup, and it handles every controller I've ever tried.
@SlothHuntOnYou
@SlothHuntOnYou 5 жыл бұрын
I am on the same, Rewired is good
@krazykase3419
@krazykase3419 Жыл бұрын
even if this comment is late. thank you brackeys this video helped me learn more about the input system and how to use it
@CarlitoProductions
@CarlitoProductions 4 жыл бұрын
I'm looking forward to seeing this come out of preview, it reduces spaghetti code so much; need to get used to the syntax, but it makes things so much cleaner
@reprdev
@reprdev 2 жыл бұрын
The cool cats of front-end web development refer to "Lamba Expressions" as "Arrow Functions"😎 Great tutorial!
@SwitchStop
@SwitchStop 5 жыл бұрын
Glad to see you’re using the *best* controller in the thumbnail 😁
@nostalgia5031
@nostalgia5031 5 жыл бұрын
I don’t care about consoles, I only care about how fast it runs
@somnia3423
@somnia3423 5 жыл бұрын
@@nostalgia5031 sowhat? controllers are a pc thing too
@DreadKyller
@DreadKyller 5 жыл бұрын
@@nostalgia5031 many people use controllers on PC as well because the fine control of an analog stick over the either off or on control of buttons like WASD.
@nostalgia5031
@nostalgia5031 5 жыл бұрын
@@DreadKyller He changed the logo... Lol
@thecrin5843
@thecrin5843 2 жыл бұрын
ohhhhh thanks, when I saw all the options that Unity gave to connect a control, with your video I finally managed to understand how to use the Input System library. Unfortunately in my language there was not a good tutorial on how to do this, many games already made with the scripts already made and since I did not have that project they were working with, It was impossible for me to know how the package worked when they used ready-made programs, instead of showing how each command worked. Anyway thanks
@dishdash3314
@dishdash3314 5 жыл бұрын
Your almost at 1 mil subs, YOU CAN DO IT :D
@Pavloh
@Pavloh 5 жыл бұрын
mil no mill yes haha :)
@nostalgia5031
@nostalgia5031 5 жыл бұрын
So close!!
@nostalgia5031
@nostalgia5031 5 жыл бұрын
@Auom 120 Swnasiqubulotosife He is at 800-900K
@SplooflagerFun
@SplooflagerFun 5 жыл бұрын
Man ... I wish you got 10 Millions Subs ! You rock
@WadeStar
@WadeStar 4 жыл бұрын
11:20 Very important. Remember to enable the damn thing.
@VagrantOfTheWorld
@VagrantOfTheWorld 4 жыл бұрын
Omg thank you so much you saved my day!!
@WadeStar
@WadeStar 4 жыл бұрын
@@VagrantOfTheWorld lol, no problem!
@jorge5161
@jorge5161 3 жыл бұрын
Someone give this person a medal
@cesarperalta4959
@cesarperalta4959 3 жыл бұрын
That keyboard sounds so good!
@AhmedA44
@AhmedA44 5 жыл бұрын
Thanks, I was really struggling with this today. Right on time
@ilovemuffins1337
@ilovemuffins1337 3 жыл бұрын
Hello, welcome from the future! This example only works in the 1.0.0+ version if you call .Enable() on your PlayerControls variable before assigning action callbacks
@GGOOSEO
@GGOOSEO 2 жыл бұрын
i spent like 1 day trying to fucking fix this holy shit you saved my game lol
@Mikelica69
@Mikelica69 2 жыл бұрын
Thanks Brackeys! 😭😭
@Infinity-dp8cd
@Infinity-dp8cd 5 жыл бұрын
Ahah,I tried to find how to make a controller input yesterday at your channel and there is a video today,you are the best!
@dbzlinkinpark99
@dbzlinkinpark99 4 жыл бұрын
at 15:20 the only reason he has to invert the X axis, is like he said, he has his camra flipped and facing the back of the cube, if it weefacing the front of the cube he wouldn't have to invert th X axis. Small things he probably just forgot while setting up his camera, or did on purpose for the purpose of learning and letting you know if you flipped you camera, invert the axis you flipped your camera by
@faustNebel
@faustNebel 5 жыл бұрын
Exactly what I was struggling with like 2 weeks ago ! Thanks a lot!
@GenuineXray
@GenuineXray 5 жыл бұрын
Let's show off a black controller on a black background, wearing a black shirt!
@zentergames1622
@zentergames1622 5 жыл бұрын
😂
@3333-x8m
@3333-x8m 5 жыл бұрын
What
@Nikko911
@Nikko911 5 жыл бұрын
well, his name is blackeys for a reason.
@shinadouzake3095
@shinadouzake3095 5 жыл бұрын
hmmmmm
@Adkinsy85
@Adkinsy85 5 жыл бұрын
PS4 IS BETTER
@lemetamax
@lemetamax 5 жыл бұрын
I've got one question Brackeys: Do you have telepathic powers? First ragdoll physics, now game controller. The exact series I need to create a realistic humanoid movement script. Thanks!!!!!!!!
@kpredkiewicz
@kpredkiewicz 5 жыл бұрын
Like, i recently went trough hell making input system for xbo controller, and now you are uploading a tutorial... witch is great, but now i see my life is kinda ironic
@paulogodinho3275
@paulogodinho3275 5 жыл бұрын
I believe you made a conscious decision to use the Lambda Functions there as they add unnecessary complexity, you could just made functions with the Context Parameter. Nice to see the ramp up in complexity on your videos, with shader work and now Lambdas, thank you so much for your videos!
@darkwyvern9796
@darkwyvern9796 5 жыл бұрын
Great tutorial! Do you think you could make a video in the future about multiple gamepads using the new input system?
@Shodan-0101
@Shodan-0101 3 жыл бұрын
Man I miss them so much!!
@alexfranco2048
@alexfranco2048 4 жыл бұрын
If you have the issue where wasd works but a joystick doesn't (InvalidOperationException: Cannot read value of type 'float' from control...blah blah error) Use a simple binding for map the joystick. Set the Action to "Pass Through" and " Vector 2". That worked for me
@ASandwall
@ASandwall 5 жыл бұрын
I saw the gamecube controller on the thumbnail, and I clicked. Does this mean I'm a simple person?
@Rumplestiltzchen
@Rumplestiltzchen 4 жыл бұрын
I did the same lol 💪😂👌
@themedievalbrick
@themedievalbrick 4 жыл бұрын
I dunno, probably not.
@ddotbuk
@ddotbuk 5 жыл бұрын
I think the explanation of Lambda functions is possibly confusing, it doesn't really explain anonymous parameters and doesn't explain how it can be used in a real sense, other than to ignore the parameters being passed in and 'make it work' for this case. What's wrong with passing the parameter in anyway and just ignoring it? It's easier to read than some complex syntax that could be hard to understand in certain situations.
@gilireeves4956
@gilireeves4956 2 жыл бұрын
This is such a great video! I love this package; it's so user friendly and easy to implement. It was so easy to update from the old system even after having multiple places where I used it.
@aadityakiran_s
@aadityakiran_s 4 жыл бұрын
Great video. Too bad that you had to stop. You should in some way get back to it. Thanks.
@intimidate2161
@intimidate2161 8 ай бұрын
Great tutorial. Easy to understand.
@otsugua_b2155
@otsugua_b2155 5 жыл бұрын
You are the best ! I have an idea, why not make a tutorial for a fighting game like Tekken or Super Smash Bros ?
@jojo.s
@jojo.s 5 жыл бұрын
pause at 0:00 btw another great video!
@juniorgoncalves4535
@juniorgoncalves4535 3 жыл бұрын
Dude, awesome content! Really well explained! Thank's a bunch!
@mlggeek1812
@mlggeek1812 5 жыл бұрын
Great video as always! I would love it if You could make a video on building a game for console and how to play it on a console.
@54games25
@54games25 5 жыл бұрын
The only way to do so is to be a certified dev with that console's company.
@MrJohnweez
@MrJohnweez 5 жыл бұрын
I don't think everyone appreciates just how easy it is now to set up a controller or almost any kind!
@michaelderosier3505
@michaelderosier3505 2 жыл бұрын
Quick-Accurate-SimpleTerms! TY
@SonicDash-zi8bf
@SonicDash-zi8bf 5 жыл бұрын
Can you make a tutorial for water physics? (Mario swimming style) I think you should try to make a water tag for the tutorial as well!
@aquaarmour4924
@aquaarmour4924 5 жыл бұрын
Just slow down the gravity and movement underwater, add force with the press of a button. Too simple for a video. Do the research yourself
@SonicDash-zi8bf
@SonicDash-zi8bf 5 жыл бұрын
@@aquaarmour4924 Well I'm a bit of a beginner so I need to learn how to make that code.
@dailydrawings506
@dailydrawings506 5 жыл бұрын
Well shoot, this input system seems alot better than the old one, I will have to mess around with this one.
@j-t-ogamingblahblah3025
@j-t-ogamingblahblah3025 5 жыл бұрын
once again, brilliant - gonna be so much easier save so much time. thx again mate.
@supapaw
@supapaw 4 жыл бұрын
Thank you so much, gotta love a well explained tutorial.
@CoolJosh3k
@CoolJosh3k 5 жыл бұрын
Designing a remapping/rebinding option menu using this system?
@NestedMango
@NestedMango 5 жыл бұрын
Thanks for Sharing 😘
@HolidayAtHome
@HolidayAtHome 3 жыл бұрын
super useful ! Thanks =D
@EricR971
@EricR971 5 жыл бұрын
this video is just in time, love you
@Nkkdxn45j
@Nkkdxn45j 4 жыл бұрын
Very useful video as a starting point. I am very new to this (24 hours post Unity install!) but I come to this with a software developer's perspective. So some basic questions: I want to to use whatever controller I find plugged in for drone control. This might be a standard PSx controller etc, but more likely an RC transmitter, might be USB or Wireless connected. These controllers can be configured by the user any which way as to number of channels (stick control, buttons etc) and the ordering of those channels. Some might be inverted, and some appear to give out a signed value (-128 to +127) and some signed (0 to 2047). The point is, you don't know what you might find for any given controller, and the end user therefore has to set all this up for his/her specific controller in a game configuration page - at run time therefore, NOT in some IDE dialogue. Now I notice a lot of setup was done in the input manager IDE dialogue. My question therefore is, where do I find information to get below that to the raw data itself? Basically, what I really want to do is enumerate all controllers installed, and for each one, enumerate all channels they put out, and then read their values as they are manipulated. Connection / disconnection events wiuld be useful but not essential. Sounds pretty simple, but I cannot quite see how/where to do it? Any information available at that level?
@Rumplestiltzchen
@Rumplestiltzchen 4 жыл бұрын
for some reason when I do this it gives me an error - Object reference not set to an instance of an object PlayerControls.Initialize () (at Assets/PlayerControls.cs:22)
@FatRogSlim
@FatRogSlim 4 жыл бұрын
PlayerControls is the name he gives to his object at the step where he create a new input action. Check the c# file you created at the step "generate c# script". select the name of the class (it looks like how you named the input action) and replace "PlayerControls" by it in your code, and voila
@ManasJoshi
@ManasJoshi 3 жыл бұрын
I am getting the same error. I just don't know why this is happening.
@wolfqgamming1219
@wolfqgamming1219 5 жыл бұрын
Can you make a video using this for 2 or more controllers too pleaseeeee :'(
@beleventh3998
@beleventh3998 5 жыл бұрын
Nice video 😊. I'm wondering though how this will map to the UI event system 🤔
@russellhinkley7449
@russellhinkley7449 5 жыл бұрын
perfect timing!
@myburghroux
@myburghroux 4 жыл бұрын
Hello. I keep getting this error Assets\Cube.cs(16,18): error CS1061: 'PlayerControls' does not contain a definition for 'Gameplay' and no accessible extension method 'Gameplay' accepting a first argument of type 'PlayerControls' could be found (are you missing a using directive or an assembly reference?)
@myburghroux
@myburghroux 4 жыл бұрын
nvm, fixed. had to check auto save in the player controls window
@xinerayt
@xinerayt 4 жыл бұрын
thanks man, that solved my issue
@allecksy8261
@allecksy8261 5 жыл бұрын
Can you please make a video to explain the new multiplayer system of unity 2019
@juschu85
@juschu85 5 жыл бұрын
When you use a lambda function as callback you don't need the Grow function anymore. You're using a function just to call a function that has a single line of code instead of putting that single line of code directly into the lambda function. Using a labda function to call another function defies the whole concept of lambda functions.
@elpainto1
@elpainto1 5 жыл бұрын
I think in this case you'd be right, but the idea seems to be that you can call a function of you have something a bit more complex than a single line
@philunityunreal7228
@philunityunreal7228 4 жыл бұрын
This is best tutorial i have ever seen for teaching Gamepad in Unity. However, I have s small question: I am currently developing a PC game and I just did the input from the keyboard. Is there a way to adapt this into GamePad? This tutorial seems to be good for making a game from scrash but not to pit in GamePad what it is already done in keyboard. Thanks for your attention. Greetings.
@bersanguzel2263
@bersanguzel2263 2 жыл бұрын
If you have an error smae to me; 'The 32-bit Windows player is not currently supported by the Input System. HID input will not work in the player. Please use x86_64, if possible.', Go to main screen Go to upper left on screen File>Build Settings...>Architecture x86 to x86_64 . That works for me, I hope work for you :)
@gregoryfenn1462
@gregoryfenn1462 5 жыл бұрын
It would be useful if this video showed the ActionMap C# script, or at least where it’s located. It’s a little confusing to see the inspector magically know what action maps and actions to suggest when configuring controls
@blastergames7867
@blastergames7867 2 жыл бұрын
In case you couldn't access to the action map from code, just click save asset from the input action window
@LaLegionNoir
@LaLegionNoir 4 жыл бұрын
Hi Guys, just to inform you that you video is probably outdated already, you chould check the new version of the Input System. Btw, thx for this video, it's awesome !!!!
@zillionradzy
@zillionradzy 4 жыл бұрын
Hey Brackeys, I have a ps4 controller but I have a problem. Where you put a function for the left stick and the right stick, I made one for LS (left stick) left and LF right and you get the point. Why did I do it? Because Unity wouldn’t let me pick “leftStick [Gamepad]” Can you please help me? Thanks
@eli_777
@eli_777 3 жыл бұрын
Just select any of the child and press the small "T" button and change the text to "/leftStick"
TOP DOWN MOVEMENT in Unity!
22:30
Brackeys
Рет қаралды 1,2 МЛН
Using Menus with A Controller/Keyboard in Unity
14:34
gamesplusjames
Рет қаралды 78 М.
Trick-or-Treating in a Rush. Part 2
00:37
Daniel LaBelle
Рет қаралды 46 МЛН
How Much Tape To Stop A Lamborghini?
00:15
MrBeast
Рет қаралды 201 МЛН
Unity's NEW input system in 13 minutes
13:02
BiteMe Games
Рет қаралды 26 М.
How to: Virtual Mouse with Gamepad (Input System Unity Tutorial)
25:09
Why you should switch to Unity's New Input System (and how easy it is)
9:51
Jason Weimann (GameDev)
Рет қаралды 34 М.
HOW TO GAME JAM!
9:01
Brackeys
Рет қаралды 281 М.
Новая Input System в Unity
11:49
GDev Academy
Рет қаралды 15 М.
How to make a Video Game - Godot Beginner Tutorial
1:17:12
Brackeys
Рет қаралды 2,3 МЛН
How to use Unity's Input System
31:47
samyam
Рет қаралды 150 М.
FIRST PERSON MOVEMENT in Unity - FPS Controller
23:53
Brackeys
Рет қаралды 3,2 МЛН
I Made the Same Game in 8 Engines
12:34
Emeral
Рет қаралды 4,2 МЛН
Trick-or-Treating in a Rush. Part 2
00:37
Daniel LaBelle
Рет қаралды 46 МЛН