Page 1 of 1
RTS-ish system for multiple 'entities'
Posted: Tue Nov 04, 2014 1:37 am
by RonanZero
Whatever you call it, think RTS or grunt enemies, I need a LOT of the exact same 'entity' as I call it on the screen at once. Ya it's just a table with x and y values and some images and of course it's own think/draw function. Now I would just call draw function in the normal love.draw but that only let's me make one of them, if I add more it will use a hivemind (exact same values I guess) or something.
Re: RTS-ish system for multiple 'entities'
Posted: Tue Nov 04, 2014 8:18 am
by undef
Uhm, is there a question?
Re: RTS-ish system for multiple 'entities'
Posted: Tue Nov 04, 2014 12:10 pm
by s-ol
RonanZero wrote:Whatever you call it, think RTS or grunt enemies, I need a LOT of the exact same 'entity' as I call it on the screen at once. Ya it's just a table with x and y values and some images and of course it's own think/draw function. Now I would just call draw function in the normal love.draw but that only let's me make one of them, if I add more it will use a hivemind (exact same values I guess) or something.
Read up on lua OOP (object orientated programming)!