I’m currently in the midst of a new game that I dropped a while back, and just kind of decided to finish it. The game is about running in a hallway, to the end. There are various obstacles that each server has randomized. Now what I want, is to show the camera point of view of “The Wall” which is just a Neon Red wall that moves from the beginning of the hallway to the end, prompting the player to run towards the end. I want a viewport frame to show it’s POV, and I want everything to be seen, like the tables, players and stuff like that.
I wouldn’t use a viewport frame for this, what I would do though is just using :BindToRenderStep and setting the position of the player’s CurrentCamera to the wall’s CFrame.
If you could show some code, I can help implement it.
No no, I want to have a sort of display on their screen, like a frame, which shows how far the wall is from the player. Instead of displaying how far it is from the player, I wanted to have more immersion and wanted a frame to show the action behind them, from the walls POV.
I have no code at the moment, but I think it’s possible.
Please do not ask people to write entire scripts or design entire systems for you. If you can’t answer the three questions above, you should probably pick a different category.
I made an example place for you to test and get the code from, but you should probably search things up like this before posting: WallCamera.rbxl (56.3 KB)
Code is in StarterGui, there are comments to help you implement it in your own project.
I have encountered a bit of a problem, see my sections are up to 22500 studs long. And after a certain distance, they stop rendering. After that, even the players stop rendering.
Why not put each player’s viewport camera 30 or 40 studs ahead of them as they move and script it so it travels at the same speed they are so it sees everthing in the player’s area. This will also help with the load on the server since it would be handled on the client’s computer.
Seems it wouldn’t be too tough if you had the entire game set on (for example) the X axis, then you could CFrame the camera at +40 studs from the player’s position on the X axis and leave the Y and Z values the same.
You’re asking waaaay too much for the camera to be able to ‘see’ 22500 studs.
Yeah, but I have found a fix. Which is on set intervals, make a new handler. It should work, but as of right now I’m working on something else which is necessary to the game.