Im trying to make a simple clone of flappy bird game. The tutorial that i watched used only rectangles for all the objects. But the thing is im trying to do it with nicer images. I have handled the bird and its movements but i can not generate pipes from images and terminate them after they get out of the screen.
The way i want to do is just like the tutorial. He made an arraylist of rectangles, and simply adding rectangles to that list with the position and dimension variables. When they go out of the screen, he deletes the pipes and add the new ones with "arraylist.add(new Rectangle())", and simply draws them with Graphics.fillRect(). But i cant do it with BufferedImage type or neither the Graphics2D.
Could anyone help please? I want to be able to generate random pipes like rectangles, and wanna be able to add them to an arraylist and draw them. Its pretty like creating blocks from an image in mario game
Any help would be appreciated!