Production week 2
Hi there, lesser beings in the universe of PewPewPantheon
As you may or may not know our game features a continuous screen.
This means that whenever an object leaves the screen on side it appears on the other.
The result is that the game is faster en the playspace feels smaller.
The implementation of the feature requires a lot of edge case solutions.
At first we solved the problem by placing 4 extra camera's in the scene.
One in each direction next to the main camera.
This way an object that leaves the top of the screen is rendered at the bottom by the camera above.
A script then teleports the object back to the bottom once it is fully out of the main camera.
This looks fine visually but it brings a ton of issues.
While planets appear to be on the other side while passing through the border of the screen, they actually aren't.
This made it so that there is no collision there, and something that is important is well. The gravity caused by the planets wasn't copied to the other side.
We could of course copy all objects * 4 and make them copy the transform of the planet in the center camera. This would work but makes it really hard to duplicate stuff like animations and decals.
The solution we came up with is a mix between making a copy of objects and using multiple camera's.
We duplicate a planet's collision, gravity and other important components but not the renderer.
This way all collision works and everything behaves accordingly. Small objects like bullets and players don't need all of this. They are so small that the hitbox doesn't matter if it's copied over or not.
Planets have to be handled this way because they often exist on both sides of the screen for a long time.
This didn't fix everything. Objects that are in the corner still behave weird. An object in the bottom left will be copied to bottomright and topleft but it should also appear topright.
To fix this we added yet another 4 camera's and 4 more copies of all planets.
This results in every planet existing 9 times and having 9 camera's. This doesn't sound very performant does it?
Well the copies off the planets are no problem because they get created at loadtime and don't cause much overhead besides that. The camera's could be a problem.
But, our game is rather simple and doesn't too many objects at once. After some testing we didn't find any performance issues yet so we will use this solution unless we run into issues.
The result is a cluttered debug space.
The art department have been working really hard as well. One big issue we still had was to implement assets without obstructing gameplay.
So we added some buildings we made randomly to the planets and figured that buildings should be sized to the player or smaller.
Since the planets are locked in rotation on the y and x axis we don't have to worry about collision as long as we don't
spawn any objects on the walk able area.
Another feat was the completion of the character models. These are the 4 playable characters in our game.
Each character will be available in multiple color schemes to accommodate for multiplayer with the same character.
The models have rather large heads and this suits the gimmicky style of the game. Their heads will be placed on a spring and will act like bobble-heads while playing.
Feel free to download our latest test. It supports both Xbox controllers and keyboard.
Thank you for reading and until next week.
Greetings, Group 15.
Get [Group15]Pew Pew Pantheon
Leave a comment
Log in with itch.io to leave a comment.