One of the big game mechanics I’m trying out in one of my games is not allowing players to jump off some objects, such as buildings.
I found the easiest way to do this was to put transparent walls around the rooftop, like a safety net. Nice and easy.
However, that has resulted in a few issues. The biggest is you can unintentionally right-click on the transparent walls, which means a player on the ground (who can’t see the invis walls) attempts to right-click on the roof (to walk to it via a ramp), but they actually click on the invisible wall and the internal Roblox pathfiind code tries to move them to that part of the invisible wall (impossible) and the pathing fails.
The wall I’m unintentionally clicking on is Transparency = 1. The sibling invis walls I’ve made Trans=0.5, so you can see them.
To get around this issue I thought I’d make the invis walls smaller, and reduce the world’s jump setting (so they couldn’t jump over the now smaller invisible walls).
That lead to this new problem - right-click pathfinding doesn’t seem to take into account the jump setting, so it fails when there’s an object to jump over but you can’t, such as the edge of a ramp. Seen here;
I do not see the point here. If you are making a game where people jump off of things. You do not need any invisible walls. All you need are the things that the people are gonna be jumping off of and such.
And question, why are you making a game where people jump off of objects? Seems like a very odd genre of game to develop
To prevent this literally just put invisible walls, but do not put any scripts or anything else in them. Do not put the wall so many studs high from the ground, just put it at the maximum point of where the player can jump, and only to the basis of that building floor.
There are no scripts (or anything else) in the invis walls. They are just simple, transparent parts.
If the wall is too high, the right-click “mistake” happens.
If the wall is too low, the player can jump over them (and “fall”, which is what I’m trying to stop).
If the jump setting is too low, then pathfinding fails.
Actually, I might not be able to help you. I just watched your video on it and the type of game that you have created will stop me from showing an example. But I would make the invisible walls literally invisible and put a script in that will deny the cycle if someone right clicks on the invisible wall, if that is possible. I am sure it is.
I might be able to. That would tell me the use has unintentionally clicked on an invis wall. What then? What’s the user going to do? They think they’re clicking on the roof and path finding is failing. They don’t know why it’s failed, nor how to work around the problem (eg change camera angle and try clicking again).