After I came across Mask extension, I thought of a way I might be able to use it to do a multi-viewport game since it seems multiple view ports aren’t supported yet.
Here is a link to the game I was able to create. It’s a simple game where four players sail pirate ships and fire their cannons at each other until only one remains. Full code download available here:
I did this by making clone objects for every game object, one for each viewport, that are masked by the viewport so each player effectively gets their own camera. Two main problems I had were:
- Mask extension only works with sprites
- Creating all these extra clone objects and updating them to match the game objects every frame is bad for performance. On my PC its still playable though, but wouldn’t work with a much larger game.
I’m not sure how to improve it further from here; if anyone has any suggestions I’d love to know.
Has anyone tried any other solutions to make a multi-viewport local multiplayer game?