Trying to make this script flip the vehicle when the player presses F, but only if the vehicle is on the ground. The way I’m checking this is setting a range Y coordinate. The whole script works, but this new line breaks it. This is the error I get:
The vehicle is a plane, so if I use orientation, this means that players can just press Y to turn the engine off in the air and then press F, allowing to them to hover completely still for a moment. In a dogfight this is unfair because if another player is chasing them the person chasing will just sail past them, and now the person who flipped midair now is chasing the other player.
So how can i specify a range between 0 -15 on the y axis?
edit: maybe an orientation check could go with this too. like seat.Position.Y == 0-15 and seat.Orientation == -90 - 180
If you are parenting the Gui to the Player’s PlayerGui - that will not be the location of the seat. You will have to get the seat from workspace - not relative from the Gui’s location.
So in order to do that, you will need to identify the plane is the player’s plane.