Alright, so I’m trying to create an anti exploit for game where if the player is flying then it will punish the player accordingly. This is not a hard task to achieve normally.
The problem, for the entirety of the game you are swinging from ropes in the air. I’m not entirely sure how I could detect if the player is flying versus just swinging. I can’t have mistakes happening where the player is punished for doing nothing wrong.
I tried raycasting to check for how long the player was above absolutely nothing, I had a few friends try it and it seemed to go well, then they all started getting kicked. I’m honestly not sure what to do now.
You could maybe place a part above where they are swinging so if a player touches that part you would know they where flying. But not sure what else to do it would be easier if you did not swing on ropes.
I suggest adding a boolean value into the character and setting its value accordingly to the status if it is swinging or not, and maybe then detect if the player is flying
It’s very difficult and there is no “one” solution.
I think you should do the following though, for starters:
Set a boundary area where, if someone is outside the boundary, they should be respawned
Identify the rope mechanic and perhaps make an event to bind someone to a rope, or unbind. Also figure out a way to identify velocity etc and consider applying some kind of ML-type modelling to identify weird curves? The event won’t stop exploiters who are dedicated, but anyone who just runs a fly script will be caught out.
I don’t know enough about your game though to think up any more ideas. Just be creative, and remember - if your anti exploit punishes legitimate users, unless the exploiters are doing real damage you’re doing more damage than them!