Predefined teleporting through keypress in VR
Hey Everyone! So i set up a basic VR Environment from the standard templates and created a little university project with it (not game design related). Everything works good so far (HTC Vive).
Now i want to implement a function but i dont know how (sorry, absolute beginner): I want to move the character/player to specific, pre-defined positions on the map through simple button presses on the keyboard.
Example given: pressing 1 on the keyboard teleports me to Point A, from where i can look around and use normal teleporting movement with the vive controllers. Same goes for pressing 2, but it teleports to point B and so forth.
What and how is the easiest way to do it?
Extra: can i specify the direction of looking when teleporting the player?
Thank you very much!
with best regards, max
asked Feb 25 '18 at 11:48 PM in Blueprint Scripting
the easiest way to accomplish the teleporting to a location would be to have an actor such as a target point placed in your level for each location. then in the level blueprint have a script where when the number button is pressed it sets the actor location from the target points location. below youll see how to do this.
i cant say for sure on the setting the rotation since i dont have any vr equipment to test with but i would suggest starting by trying set actor rotation similar to the set location above or set control rotation which would involve getting the player controller. one of those options would probably work. also you may want a fade to black transition for while teleporting (cuz you know vr). these are just ideas in this paragraph because my vr knowlege is limited.
answered Feb 26 '18 at 12:06 AM
Follow this question
Once you sign in you will be able to subscribe for any updates here