Download the Project (for FREE): www.vrcreators.io/codedownloads
@tatepayton73682 жыл бұрын
This is just what I was waiting for! A simple way to make things like backpacks and stuff with sockets. Thank you so much for helping out the VR community!
@JustinPBarnett2 жыл бұрын
You're so welcome!
@thaFoxy2 жыл бұрын
great Patreon! it has everything I needed.
@tientam7792 жыл бұрын
Once agin, great and simple to understand tutorial. I like that you're always checking up on XR toolkit from Unity and making new tutorials about it, allows anyone new to just jump right in and get started with those tool!
@JustinPBarnett2 жыл бұрын
Glad to help!
@FusedVR3 жыл бұрын
Super comprehensive. Very nicely done!
@JustinPBarnett3 жыл бұрын
Thanks!!
@Ollie_sm3 жыл бұрын
could you do a tutorial on how to make it possible to climb and glide and even an accurate gliding mode where you can steer up and down using your hands
@JustinPBarnett3 жыл бұрын
Ooo that’s a cool idea! I’ll add that to my list!
@Ollie_sm3 жыл бұрын
@@JustinPBarnett thank you so much!
@Ollie_sm3 жыл бұрын
@@JustinPBarnett mechanics similar to this would be great kzbin.info/www/bejne/oHbMfJVoYqmXerM much better than gliding in most vr games
@4per8 Жыл бұрын
immana use this for a debug menu in the game im working on, might be cool
@shayaltshue17912 жыл бұрын
Insanely useful tutorial. Thanks Justin!!
@JustinPBarnett2 жыл бұрын
You’re welcome!
@SimpleDays1012 жыл бұрын
Once again, I must proclaim that you are, in fact, the MVP. Thanks for the great tutorials!
@JustinPBarnett2 жыл бұрын
Awe thanks so much!
@HenshinAsset3 жыл бұрын
Thank god you did this tutorial. I would have problems this Sunday 😆
@JustinPBarnett3 жыл бұрын
You’re welcome!
@kathy02158 Жыл бұрын
who can tell me if i want use xr sockets apply in slot and become 2d image ,how should i do?
@jaimejia862 жыл бұрын
Hi Justin, Im using the Oculus interaction (OVR) but i can find any snap or socket script, please help me
@andreramiro7322 жыл бұрын
Same problem here. Youve got the solution?
@bones999993 жыл бұрын
Very nice tutorial. Thanks. My new favorite channel. Could you do a tutorial on Hand interaction with colliders on say a desk or wall? Specifically, where if you push the controller through the desk, that the hand stays on the desk until you bring the controller back to the hand position and it will track with the controller again. Or is this built-in to the tool kit? I know some VR interaction tool kits have this feature.
@JustinPBarnett3 жыл бұрын
It's not built into the toolkit, but I have made a video about physics hands! Check it out: kzbin.info/www/bejne/iKiqeqyIrpJ_qdU
@bones999993 жыл бұрын
@@JustinPBarnett cheers. I saw that after I wrote the message. Thanks
@infectedgoat993 жыл бұрын
How did you figure all this out on your own? Incredible video, super helpful. ALSO for anyone struggling with getting the hammer to face the right direction when holding, make sure in the XR Grab Interactable script that you drag your empty game object "Attach Point" onto the "Attach Transform" otherwise the object wont use your attach points!
@JustinPBarnett3 жыл бұрын
Lots of testing and just playing around in Unity 😜 and thanks for the tip!
@V-ROCstudios3 жыл бұрын
Thanks. I kept thinking I needed to rotate a component.
@k1ng4013 жыл бұрын
haha just worked this out myself and then thought "someone else must have had this problem..."
@tommedenney2 жыл бұрын
Thank you soooo much omg tried to figure this out for an hour and a half before coming here
@tylerjones91972 жыл бұрын
Heads up, Toolkit is spelled wrong in your title. It says tookit. Great tutorial keep em up!!
@JustinPBarnett2 жыл бұрын
Holy cow, totally missed that! Thanks!
@1998natan3 жыл бұрын
Very nice tutorial. But i don't know how to launch my project on quest 2. Do i need to do something special? Cheers
@JustinPBarnett3 жыл бұрын
Like build your project to the quest or just run it in play mode?
@1998natan3 жыл бұрын
@@JustinPBarnett Thanks for answering! Got help on your discord. I had to disable air link and then plug in cable and enable on quest. 👍💪
@JustinPBarnett3 жыл бұрын
@@1998natan awesome!!
@torstenknodt6866 Жыл бұрын
Great video, thanks! Is there a way to check dynamically whether a socket interactable could really be dropped on a socket interactor or there is some use-case specific condition which does not allow it?
@catalinpop3423 жыл бұрын
The timing on this video couldn't have been better. Ran into the missing XR Interaction Toolkit issue yesterday when I updated to 2021.2.6f1 and today I decided to check out my go-to Unity VR resource on KZbin...and what do you know? :)) Massive thanks for all the content, would take me forever to figure this stuff out on my own.
@JustinPBarnett3 жыл бұрын
Ayyy you’re so welcome!
@_Garm_3 жыл бұрын
Hi Justin, great tutorial! would you be able to show how to do power cables with the Obi Rope addon like plug in and un plug :)
@JustinPBarnett3 жыл бұрын
That’d be cool! I haven’t used it but I’ll look into it
@k1ng4013 жыл бұрын
How do we make the hammer and shield collide with each other when held? or is that not possible. I see they collide with the world and they collide with each other when not held but I can't bang them together while holding them. I don't know if I ever will want to but it might be handy to know
@JustinPBarnett3 жыл бұрын
Change the grab interactable component grab type from instantanious to velocity tracking
@k1ng4013 жыл бұрын
Only renders in the Left eye. Did I accidently click something I shouldn't have?
@JustinPBarnett3 жыл бұрын
Try going to project settings > OpenXR > and swap render mode to multi-pass
@k1ng4013 жыл бұрын
@@JustinPBarnett Yep! That fixed it. NOTE i have both the PC and Android OpenXR setting and first I tried it on the Android part and it made no difference so I did it on the PC setting part and it worked. So basically it's the PC Settings that matter when streaming from the PC to the headset and the Android if you Build and send the file to the headset to play it there? is that correct?
@k1ng4013 жыл бұрын
@@JustinPBarnett as a side benefit I now know how to simulate a pirate player character with a patch on his right eye if I ever create a swashbuckling VR game 😁
@BlackDev3 жыл бұрын
I love your vids self taught inspiring game dev have been binge watching your vid and using them as projects but i cant figure out where im going wroong here my line visiuals arent tracking they just go up and down
@JustinPBarnett3 жыл бұрын
Thanks! Join the discord and we can help you out!
@cryptopedia72573 жыл бұрын
hey justin really love the conent. can you make a video on unity vs unreal engine 5 for vr development !!!!!
@JustinPBarnett3 жыл бұрын
Yea! I actually dabbled around in unreal for a bit before coming over to unity. I talked about it a bit in my “What you need to start VR” video
@k1ng4013 жыл бұрын
Did you miss a step? Were you supposed to make the Attach Points selected in the Attach Transform selection? Until I did that, it was ignoring my Attach Points completely and the hammer was facing the wrong way, the shield was being held right in the centre
@JustinPBarnett3 жыл бұрын
Yes I did that!
@Magiak3 жыл бұрын
Hello Justin. Could you please help me find out why I can see only black screen in my Oculus Quest 2? I step by step followed the first section 'How to set up a VR project in Unity 2021.2'. of video, Then I switched the platform to Android, selected device and pressed 'Build and run'. It created the apk and uploaded it to the quest but only thing I can see on my Oculus is black screen. Could you please help me what to do? I tried older Unity 2019, 2020 and it's OK but I would like to use Unity 2021. Thank you for awesome video!
@JustinPBarnett3 жыл бұрын
Hmmm maybe ask in the Discord. May need some screenshots or more specific details to help fix
@Magiak3 жыл бұрын
@@JustinPBarnett Do you have any example project in Unity 2021 configured for Oculus Quest I could try to run?
@Calactic2 жыл бұрын
Thanks for this, helped a tonne. I'm just wondering, how would you go about making items being able to stack up on each other? Our game is a survival/horror game and we want players able to put more than one of the same item into a hotbar, which is a sphere socket interactor. Our game takes heavy inspiration from "A Township Tale" if you're familiar.
@firizz2 жыл бұрын
have you found the answer? plese let me know if you do
@dracula92023 жыл бұрын
Impressive! Thanks for sharing! I wonder if there is a workaround so that only objects that are being grabbed atm can be selected in the socket. I already tried to play around with some things in the public override bool CanSelect(XRBaseInteractable interactable) interactable.isSelected.. but nothing seems to work xD Thanks in advance if anyone has a hint^^
@JustinPBarnett3 жыл бұрын
I was actually playing around with that today and couldn’t find a solution for that either 🤔
@Acilianus2 жыл бұрын
I know it has been 4 weeks now, but It was tricky and I found a (mostly satisfactory) solution so posting it here for you in case it is still relevant. What I did is I switched the layermask on the interactable when the interactable hovers over the socket (OnHoverEnter interaction event) to a layer which can not interact with the socket, on the condition that an XRDirectInteractor is not currently selecting the interactable. The tricky part here is that you have to switch back to the originla layermask. First my intuition was to do it on the OnHoverExit event, but since the interactable was moved to another interaction layer, the socket was not detecting events on it anymore... So instead I implemented a coroutine which resets the layer mask on the interactable if the interactable is selected, or moves away a certain distance from the socket. This mostly works well, the only hiccup is that when the (ungrabbed) interactable falls into the socket, it still stops for a second before falling through it. However, the socket will not pick up the interactable even if the interactor rests right on top of it. Here is the code for reference (the disableInteractor method is bound to the OnHoverEnter event of the socket. Note that interaction layer numbering starts from 1 not 0. Also note that when the interactable hovers above the socket it already counts as selected. ): // Disable the interactable if it is not grabbed when placed into the socket (e.g. it conincidentally falls/bumps in it) public void disableInteractor( HoverEnterEventArgs eventargs ) { XRGrabInteractable interactable = (XRGrabInteractable) eventargs.interactableObject; if ( interactable.interactorsSelecting[0].GetType() != typeof( XRDirectInteractor ) ) { //interactable.GetComponent( ).enabled = false; interactable.interactionLayers = 2; StartCoroutine( reEnableInteractor( interactable, interactable.interactorsSelecting[0] ) ); }; } // Reenable the interactor after an accidental fall/bump into the socket private IEnumerator reEnableInteractor( XRGrabInteractable interactable, IXRSelectInteractor interactor ) { while ( Vector3.Distance( interactable.gameObject.transform.position, interactor.transform.position ) < 0.2f ) { if ( interactable.isSelected && interactable.interactorsSelecting[0].GetType( ) == typeof( XRBaseInteractor ) ) { interactable.interactionLayers = 1; break; } else { yield return new WaitForSeconds( 0.1f ); } } interactable.interactionLayers = 1; } Hope this might help some people.
@leventebotos69273 жыл бұрын
Hi guys! I want to ask that how can i address an xr origin in code? Sorry if it's a stupid question but i can't find a solution on the internet.
@JustinPBarnett3 жыл бұрын
It's the "XROrigin" class!
@leventebotos69273 жыл бұрын
@@JustinPBarnett Hey Justin! Could you explain this please?
@JustinPBarnett3 жыл бұрын
@@leventebotos6927 join the discord and we can answer more detailed
@ivani5543 Жыл бұрын
Thank you for your wonderful tutorial. If using xrit to splice objects, similar to LEGO, how can they be connected one by one? Do you have any good suggestions?
@thegamingcoder47892 жыл бұрын
how do you use the socket interactor to trigger code events
@JustinPBarnett2 жыл бұрын
In the inspector there should be interaction events you can attach scripts to
@trumancoburn33353 жыл бұрын
Hey quick question, is there anyway to get a held input for my joystick? I'm trying to make a sprint system but I cant get an unpressed thing back from it, so I cant make the speed go back to the original when you unpress the joystick.
@trumancoburn33353 жыл бұрын
Found a solution!
@JustinPBarnett3 жыл бұрын
What was your solution?
@Riprog3 жыл бұрын
Hey Justin! Love your content, keep it up! I have an issue with using XR Socket Interactors in multiplayer applications using Photon (PUN 2), so far I've gotten no response on the Unity forums. The problem I face is that if a player puts an object in a socket and then grabs it again, the item remains in the socket for other players (not seeing that a player has a grabable in hand). The item has a photon view component on it and also a photon rigidbody view component, I suppose you need to add some component to the socket interactor? Thanks in advance!
@АндрійНесвідомін3 жыл бұрын
I have the same problem, just yesterday I saw your post on the Unity forum :). Justin, if you can give any advice would be very grateful too!
@JustinPBarnett3 жыл бұрын
So my initial guess is that is has something to do with parenting the object. Maybe try adding a script to have it follow the socket attach point every frame instead of parenting it. Just a guess though.
@petitwhito31962 жыл бұрын
Hi ! I have the same issue, have you found the solution to the problem ?
@HenshinAsset3 жыл бұрын
OMG, can't believe they changed it all again 😫
@JustinPBarnett3 жыл бұрын
Right?!?!
@patty__3 жыл бұрын
hey, great video. just wanted to ask if i should continue with unity 2020 or if you think i should use 2021 instead? i'm only up to importing hands in 2020 so it wouldn't waste much time to start the 2021 version.
@JustinPBarnett3 жыл бұрын
If you're building a game to release go with the latest 2020.x LTS version, but if you're just learning then I'd recommend using the latest non-beta version! Does that make sense?
@patty__3 жыл бұрын
@@JustinPBarnett yeah that makes sense, thanks. i do want to make a small first game so i'll stick with 2020, thanks!
@Ctorresification2 жыл бұрын
Great tutorial! Is there any way to make it so the player has to place the interactable object into the socket? I have a socket attached to my players finger for attaching rings and I can pick up the ring with one hand and put it onto the finger of the other hand just fine, but I can also just move my hand over a ring sitting on a table and it will snap to the socket automatically. I want the player to manually drop the ring onto the finger.
@wisdomkhan10 ай бұрын
Any idea how to make a Lego VR game?
@andreramiro7322 жыл бұрын
How can i do this with the Oculus Integration (OVR)?
@gnomge3 жыл бұрын
ayo hold on, letss goo, exactly what i needed. btw i need to add a simple bean to act as the character, like follow the xr rig, cuz when i put it under the xr rig it doesnt follow the camera movement, but when i move it under the camera, it breakdances on me. oh and also how the hell do i stop my character from being able to fly when holding an interactable ways to recreate: create basic xr rig (action based) create an interactable, hold the interactable under the player.
@JustinPBarnett3 жыл бұрын
You can checkout my VR movement video for getting the collider to follow your camera. And in order to prevent held things from interacting you should set them to an “interactable” layer and set the player to a “player” layer and then in your project settings > physics make sure in the grid that the checkbox between the layers is unchecked so they don’t interact
@gnomge3 жыл бұрын
@@JustinPBarnett thanks a lot! also does ur video include adding a visual character to the xr rig? cuz my project is a vr shooter and it needs the character to not only to have a body, but the body to have a collider. so how the hell do i set up the character model (i only need it to be a bean) to the xr rig?
@JustinPBarnett3 жыл бұрын
@@gnomge I do have another video about that! Inverse kinematics
@franciscoflor65723 жыл бұрын
I followed all these steps yet interaction toolkit does not come up
@JustinPBarnett3 жыл бұрын
You typed it in correctly to the package manager?
@OTAKUBLOCKU3 жыл бұрын
@@JustinPBarnett Yes even re did it a couple times too. And tried different versions of Unity. How is that possible?
@JustinPBarnett3 жыл бұрын
@@OTAKUBLOCKU Strange.... does it show up in 2020 for you if you enable pre-release packages?
@OTAKUBLOCKU3 жыл бұрын
@@JustinPBarnett yeah that’s what’s so weird about it. I do have an “error refreshing packages and features,see console” in the package manager. In console it says; “Cannot perform upm operation: unable to perform online search:” And “Error searching for packages” My wife is connected though.
@OTAKUBLOCKU3 жыл бұрын
@@JustinPBarnett okay I figured it out I needed to create a new rule for my firewall to accept unity updates from internet. Thank you for responding.
@djmedina502 жыл бұрын
Hello Justin, I like so much your videos. I have one question. I've followed your tutorial to try to do an inventory but at the moment I hide de canvas all the items that I have shocked falls down. What can I do to make the Items be hiden with the canvas and showed again. The inventory is a canvas with Slots that can be showed and hided pressing the button X of the left controler in Oculus quest 2. Thanks and best regards.
@doktor13502 жыл бұрын
Can I use XR Interaction Toolkit with SteamVR plugin hands?
@kwani_2 жыл бұрын
Everytime i press play my hands are not attached, it just stay where it is and I can't see them, anyone knows how to fix this please ?
@christopherarendt35312 жыл бұрын
There is no Default Input Actions under XR Interaction Toolkit Samples
@JustinPBarnett2 жыл бұрын
It's changed to another name, but still in the same place
@alejandrodelgado743 жыл бұрын
Awesome thanks so much….. unity should by default setup your scene….
@JustinPBarnett3 жыл бұрын
Yea that'd be nice. There is a VR template, but it's not really that great
@bhargavgaurav9870 Жыл бұрын
Xr toolkit inputfield active perform tha meta quest pro
@steampunkengi58052 жыл бұрын
How weird; my Socket Interaction's Hover Mesh isn't in a static location, but follows/rotates with the object I want to put in! Even more so, it's not even IN that object, it's some distance away
@JustinPBarnett2 жыл бұрын
Very strange. Sometimes socket stuff has a mind of its own
@hynesie112 жыл бұрын
damn i thought this was gonna be about web sockets :(