I've been kicking around an idea for a top-down shoot em up, but it's going to require a splitscreen effect similar to the one Yann made here on this thread. Basically, i need something that works similarly in that it splits the screen when the two player characters move apart, and rejoins it when they are nearby.
I thought I could just modify the code for the example CAPX Yann linked to, but apparently it's a little more complex than i thought. For a platformer, the code works great, but when you switch to a game that needs to move in the Y direction too, it breaks.
I have a CAPX here that's hopelessly broken. It is, of course, based on Yann's excellent platformer splitscreen example:
CAPX
If i'm close, i think i've figured out that i need 2 canvas screens (one for each player)? I might not be close though.
Another way i was thinking of that might work is just figuring out how to do a Y-axis (up and down) split screen, and then combining that with an X-axis (side to side) one somehow. Would that actually work smoothly though? For example, the game that I'm working on would need smooth 360 movement. Would i be able to get away with doing a "if player2 is moving up or down, use THIS form of splitscreen" and a "if player2 is moving side to side, use THAT form of splitscreen"?