To clarify, I know why my game is running slow. I have a lot of different objects in the current area and it has to tick and render all of those objects. I just don't know how to fix the problem without just making less objects.
The answer I am looking for is more of a concept of how I can go about fixing this problem rather than just making a bunch of code for me to paste into my game.
I am designing my games based off of tutorials by RealTutsGML. There where some issues I had to work around with his method of building games, but I figured them out.
So every tick in my game, I have to look through all of the objects that currently exist. The more objects that exist, the longer it takes to process all of them. I need to find a way to help free up memory if those objects are currently not in view, for example. I know games like Minecraft use chunks to free up unused memory. (Blocks outside of the view distance are not generated) What can I do to allow for an environment with many objects without causing so much lag? I want to be able to have a big level without having so much lag from all the objects that have to be ticked and rendered.
Another thing that I will clarify is that all of the objects loaded into the levels are held in a LinkedList so that I can easily create and destroy objects. Every tick, I run a for loop through those linked lists to process every objects behavior and how they are rendered.
[EDIT APRIL 28]
The objects in the game I was working on are organized in a very grid-like format. So that includes the tiles, the player, and all of the other game objects.