How to Make Portals in Roblox Studio
Download – Portals Script
How To – Make Portals
What’s up everyone welcome to buzzygames, my name is BuzzyGamesBeth and today I’ll be teaching you how to make portals!
- What I want to do is teleport from this blue part to the red part – it looks like a little portal! So these two portals are just composed of a bunch of part sinto a group. What we want to do is work on our blue portal over here and remember this is a model so it’s a bunch of parts composed into a model, but what we want to work on is the part that we want to teleport to that we’re touching.
- That’s going to be the middle part for me and i’ll rename that to “PortalA” and then go ahead and make sure you untick cancollide
- Cool so then once that’s done go ahead and add a script. We’re going to go ahead and delete this print statement so right now we’re going to go ahead and create our function and we’re going to do it so that anytime if our player we touch the part then the humanoid root part which is just essentially our character is going to be teleported to the position of our red portal.
- Remember how we had two portals the blue one and then the red one? The blue part is anytime we touch it, we get teleported to the red part. We want the position of our red part so vector3.new is essentially it’s just the position, rotation, size of our part that we want to manipulate or go to. So let’s go ahead and get the position of the portal part of our portal. It should be in our properties.
- Let’s go ahead and copy and paste that position inside of our script where effective 3.0 is at and that’s it!
- One more thing I forgot to set the parameter as hit and that’s all we got to do and then our code is done.