Yes, this has been brought up and done SO many times before. However, it’s all scattered around various topics, and I just want to bring it into one. I came up with this by myself, but other people also came up with this before me, so I’m not going to credit anyone, including myself.
Ok. Car. How?
Let’s start with a simple scenario in which this would be useful. Let’s say you have this setup in your game:
The southernmost neighbor is lazy, and wants to get to the northernmost neighbor without walking. How do they get there? Well, they drive! With their car! Yes, that is a car. Not a bookshelf propped up by basketballs. I swear
Ok, so we have a setup, now how do we actually make the car. We’ll split this into a few steps.
STEP ONE: preventing escape
If you’re in a car, you don’t just… get out of the car while it’s driving. At least, not if you’re very smart. So, we add some barriers around the road. These will trigger whenever the player enters the car, and – while invisible – will prevent the player from leaving the road unless they stop the car.
This looks tight, but we want it to be. You aren’t switching spots from driver to passenger side in the middle of the drive. At least, not if you’re very smart.
STEP TWO: getting in and out of the car
Ok, you’ve got a random car and some random lines. It does literally nothing except get in the way right now. So we set the barriers to be inactive on game start, then add a button around the car. When this button is pressed, it will trigger a teleporter to teleport you inside the barriers which have just been activated by said button.
Make sure the teleporter teleports you INSIDE the barriers, and you can’t get out. We don’t want anyone escaping.
STEP THREE: driving, because you’re lazy
Ok, now we have gotten in the car. This is the t̶e̶r̶r̶i̶b̶l̶e fun part!
Let’s define a simple drive system. We’ll use blocks to streamline this, but you can also brute-force it, and I’ll have a small section on that in the end.
We make a property called roadPosition, or roadPos, or roadpos, or roadposition, or road pos, or road position, or road Position, or Road PoSitiOn, or whatever. For the purposes of this guide, its called roadPos. Then we make a bunch of zones. For the purpose of making this look like something other than a total loss of sanity, we use only 3 zones, but you can make these as much as you want.
We also need something to track the zones, so we use counters to do counter-property pairing.
Ok. Now, we’re going to need some blocks, so I’m gonna put in a quick
TRIGGER WARNING (get it? cus its a trigger? laugh please?)
This trigger will trigger whenever property roadPos updates. We will go into its blocks, and say, 'When Triggered", do this:
Then, for the really fun part.
STEP FOUR: pain incarnate
Make the vehicle again. As many times as you have positions on the road.
The props for each car will appear on their respective channel, so a car in the first area appears on road1, and disappears on road2. We unfortunately have to use wires (as far as I know, if someone knows better please let me know) to hide the car before, so connect each car to the car before it, and say if the car before it appears, it must disappear.
There you go, that’s how you make a fully driveable vehicle in Gimkit Creative! Thanks for reading, and have a good one!
If you have any ideas on how to combine the disappear things so we don’t have to use wires, lemme know.
shdwy out.