question about how many actors in a scene is aloud?

CodeMonsterCodeMonster ACT, AustraliaMember Posts: 1,078
so i was wondering since im making a big platformer game, how many actors can i have in one scene without it being laggy would you reckon? each block of ground 140 width and height 12, (these are ground actors/platforms) and the actor well is two actors being played at once basically, so im just asking how much of these platforms could i put in one scene without it going cray cray :/?

Comments

  • SocksSocks London, UK.Member Posts: 12,822
    edited November 2013
    Lots ! : ) Do some quick tests, I expect it's hundreds if they contain only very simple rules.

    A 12 x 140 (assuming a 12 x 140 pixel image) will use a 16 x 256 pixel chunk of memory, not normally a concern but if you are going to have hundreds of actors on screen it will soon add up.

    Also even with a big scene (bigger than the screen) you don't need to have all your actors 'live' at once, they could be spawned just off screen as you approach them (and destroy them once they leave the screen area), so the target device only really has to deal with what's on screen.
  • CodeMonsterCodeMonster ACT, AustraliaMember Posts: 1,078
    alright awesome yes 256 pixel :/ shouldnt matter to much, i defently wont have over 60 platforms per level, and thanks @socks
  • SocksSocks London, UK.Member Posts: 12,822
    alright awesome yes 256 pixel :/ shouldnt matter to much, i defently wont have over 60 platforms per level, and thanks @socks
    60 actors @ 12x140 pixels is only 100,800 pixels.
    But 60 actors @ 16 x 256 is 245,760 pixels, so by using such an inefficient size you will be using over twice the amount of memory you really need.
  • ChunkypixelsChunkypixels Member Posts: 1,114
    Shouldn't that only be an issue though if each of the 60 actors has a different graphic? I'm guessing that a majority of the platforms will just be repeats.... So should use the same graphic file that's already loaded into memory?

    Your right though that for efficiency, if you could make/use platforms that are 16x128 instead of 12x140 they fit better into memory.
  • willkeslingwillkesling Member, PRO Posts: 123
    Is there a way in gamesalad to compute how much texture memory is being used? I know we could do this in LUA/ Corona SDK.
Sign In or Register to comment.