FOV in a game

I was wondering how to add an FOV effect to my game, so that you could only see in an area around you.
This is the game so far: https://arcade.makecode.com/S95387-15127-91144-46579
Thank you in advance!

1 Like

I suggest the Shadow casting extension or the Lanterns extension!

2 Likes

First of all, nice game, Second of all, welcome to the forum, third of all, I don’t think raycasting works for gravity/up and down games, but I’m not sure. You should ask @richard about it. He knows all of the nooks and crannies of makecode arcade.

Ok! Thanks for the welcoming arms, how should i ask him?

1 Like

okay, three comments from me, a person who loves when they can easily do stuff with the controls. firstly, why is left and right A and B? that seems a little confusing. you could just use the left and right buttons instead. two, why is the button to go up, down? is that a mistake, or is it another confusing game mechanic like the A and B thing? three, if the game is a maze, and you make it have a FOV, you are making the game way to hard. I mean, everyone likes a challenge, but that would be frustrating, and especially if you add something that can kill you. I mean, how do you solve a maze when you can’t see. blocking what you can see is good, but FOV from my understanding makes it so you basically can only see a certain area around you, whether or not it’s behind a wall. I may be incorrect on that, but if I am right with that being the meaning, I suggest you use the shadow casting extension as suggested by Randomuser.

@JD10YL you can just @ me for questions!

but i’d just tell you exactly what @randomuser suggested. let me know if you run into any trouble using those extensions!

Sorry for the buttons mix up, I put in the wrong link. These controls were just me messing with my friends. And I intend for the movement of the game and overall style to completely change before i am finished. Thanks for the recommendations though!