My main loop just went from this:
To this:
There's other ways you could have done this, but accessing the entities directly, and storing data in the entity structure, as opposed to storing the entity somewhere in a data structure, are by far the best/easiest/most versatile methods. This allows a totally different entity-oriented coding style, where all you need to access all parameters is the entity variable.
This is REALLY cool! It's like a new language.
For player.player=each player : updateplayer player : Next For flare.flare=each flare : updateflare flare : Next For trigger_hide.trigger_hide=each trigger_hide : updatetrigger_hide trigger_hide : Next For trigger_show.trigger_show=each trigger_show : updatetrigger_show trigger_show : Next
To this:
UpdateEntities CLASS_PLAYER UpdateEntities CLASS_FLARE UpdateEntities CLASS_TRIGGER_HIDE UpdateEntities CLASS_TRIGGER_SHOW
There's other ways you could have done this, but accessing the entities directly, and storing data in the entity structure, as opposed to storing the entity somewhere in a data structure, are by far the best/easiest/most versatile methods. This allows a totally different entity-oriented coding style, where all you need to access all parameters is the entity variable.
This is REALLY cool! It's like a new language.