I hope someone can help me? I have a noobie sort of problem that I just can't work out.
If I have an enemy type that I created, say TEnemy and I want to be able to create them one by one, how can I do it using a TList to track them? I think what I mean is can I just create a TEnemy on the fly in memory that remains there (without just using a variable to hold it), and can be referenced by pointer using a TList? I have used arrays of TEnemy so far, but an array just doesnt seem the right way to do it.
I want to create a TEnemy in memory, point to it using the TList (easy), but how can I just create an object that will occupy its own memory somewhere?
I think part of my problem is not fully understanding classes, types and objects :x
Bookmarks