For a 2d topdown game I have created a particle effect with libGDX that is just small slighly transparent balls floating around, changing, color, and so on to create an ambient effect. As of yet there are no world limits, you can just shoot your little spaceship as far as you would like. Obviously if I created that particle effect every, say, 50 pixels or so it gets very very laggy. So is there a way to only emit the effect near the ship? Also, what other ways can you think of to make a top down space shooter more interesting in terms of graphics? Thanks, -cMp
Anyone?
I don’t know much about the inner workings of libGDX, so can’t help there.
But if, like with Java2d, you have different render surfaces, you might want to render the effect into a smaller viewport-centered surface (layer) rather than all across the game map.
After all, effects are only necessary where the player can see them.
As for making top-down graphics interesting, an easy improvement is to work on the backgrounds. For space games, look into making cool looking planets and nebulae, rather than boring starts (plenty of games do that).
Thanks for the answer! I have always thought of putting planets in, but I have never done it ;). Thanks again
If it’s a sp game, you can probably just have it so once the particle leaves the camera projection area, the particle disappears from existence or something.
Or perhaps have it still exist, but not try to render it, just try to remember it’s position incase it hits a ship off screen or something.
As for background stuff, …stars…does the trick
In all seriousness though, as suggested, planets in the background, also maybe do some space station ruins, or the hulls of empty space ships from a massive battle floating around which would be not only in a background layer, but also a foreground layer to make if feel like the player is flying through the aftermath, rather than past it.
Shooting stars, comets, asteroid fields, nebulae, black holes, anomolies that you can make up yourself to look cool, they don’t need any explanation :P.
Random space suit floating around, some kind of space creatures in a swarm like X2 and X3 have space flies (which are illegal, but make lots of money in game)
Just go crazy with ideas, but not to the point where the player is always going to see a bit of everything, make it random enough and frequent enough so that the player will see these things, but not so frequent that the player is going to see it all the time.