I am wanting to make a game that has each level loaded from an image.
I want to draw up the whole level in Photoshop, and then set it as the background and allow the player to walk over it.
I want another invisible image to go over top which will be black in all places that I want to collide with.
The reason I don’t want to use tiles, which are much easier with rectangle collision and such, is because there will be complex corners and not everything will be rectangle.
Is this a good idea, and is it possible to do easily?
Would this be a big CPU hog or is there a better way to do this?
Level image

Obstacles shown in red

This could be achieved by drawing and dealing with
ShapeandAreainstances. E.G.Edit
At start-up, use the source seen in the Smoothing a jagged path question to get an outline of the red pixels (see the
getOutline(Color target, BufferedImage bi)method). Store thatAreaas the single obstacle on start-up.