I’m struggling to find a way to change the velocity to get Sonic to speed up going down a hill and slow down going up. For the moment all he does is move at the same constant speed throughout.
I’m thinking that if I can get Sonic to speed up a lot going down the last hill before the loop as seen in my photo maybe he’ll have enough momentum to finally make it through the loop.
I did look at many Tutorials before posting this thread.
Please use code-tags when posting code and not plain-text. Also whilst someone might want to debug your code in their head, most won’t and you should endeavour to explain what you’re doing, what specifics are not working etc.
As MelvMay said, it’s simply not worth reading plain-text code.
I will say that if you get the tangent of a raycast hit from the player straight down to the ground and look at the tangent that will give you the slope angle which you can use to modify the velocity.