Hi everyone.
I've been working on a video game for a while now
I posted on the play store, I don't know if I should post a link because I did it as a paid app, maybe I shouldn't spam.
But here's my question:
My game is space shooter style (that's the name of the game). With some differences, for example there are images of approximately x100/200 px which I then resize (I will try to reduce the dimensions to a minimum but they are artistic images so I cannot reduce them to 10x10.
But I created all the levels by inserting spaceships, asteroids, etc... in each layout measuring 50000 x 480 (the maximum).
however I inserted objects up to a maximum of 20000 px.
The viewport continuously moves to the right showing incoming enemies, up to the level width entered in a dictionary object.
Here's the question:
The fact of already having all the objects created in the layout (there can be 50-60 plus the small star images of 20x20 px created randomly at the beginning of the layout which can even be more than 100!)
Does it greatly affect the performance of the game?
Would it make sense to record all the objects with their properties in a dictionary, change the layout size to 854 x 480 px and create the objects at 1000px and make everything move to the left?
That is, creating a dictionary with example:
time 1sec. --> asteroid(height 200, size, variables, etc...) time 3 sec --> enemy (height etc...)
And make a function that creates enemies like that?
it's a job that takes some time because I want to recover all my levels as they are.
Does it make sense to do it?
Because I see my game lagging on my smartphone, and it will lag even more in the future.
What is best to do?