I am working on a game using javafx. I have coded some games in awt before, so I have a basic sense of how games work. (I used bufferedimages) However, with so all the new stuff in the javafx api, I am questioning if my old game architecture still applies to javafx. This is the current logic of my game:
This is how my rendering works:
List<Entity> entities= new ArrayList<Entity>;
GraphicsContext gc; ///imagine that I created a new GraphicsContext object
inside the render method it basically looks like this:
for(Entity e : entities)
{
gc.drawImage(e.getX(),e.getY(),e.getImage());
}
However, since javafx has so many new features, I am wondering if this approach is obsolete or inefficient. Should I move these entities or should I move the Image themselves? I am working on a space shooting game, so will Interpolate() and Transition improve my game?
There are not a lot of specific javafx game tutorials available, so I have to seek some help here... Thank you!