Animation Frame Amount

Discussion and feedback on Construct 2

Post » Wed Apr 09, 2014 3:51 pm

Hey everyone!

I was just curious while I was sitting at work if anyone had any experience with sprites that have a lot of animation frames and whether or not that takes a toll on performance?

I have a character with almost 200 frames (I probably won't use ALL of them) but just wondering if anyone has any experience with large amount of frames?

Thanks!

Nick
Twitter: https://twitter.com/pudgyplatypus

Learn to make a clicker game for cheap!
https://www.scirra.com/store/games-with ... e-game-666

Try out Pixel Golf on the Scirra Arcade!
https://www.scirra.com/arcade/sports-ga ... el-golf-67

Pudgy Platypus Games website!
www.pudgyplatypus.com
B
59
S
20
G
5
Posts: 212
Reputation: 7,390

Post » Wed Apr 09, 2014 4:15 pm

the more frames the more png's so the more stress for your gpu to render them every tick.
So yes depending on what platform you are aiming at might have a very big impact in performance especially if you have many instances animating 200 png's each.
now if you have an i7 it wont make any difference but try this at mobile and you will see what i mean :)
B
15
S
6
G
4
Posts: 277
Reputation: 3,948

Post » Thu Apr 10, 2014 5:49 pm

@roccinio thanks for the reply. That makes sense.

So then if you have a player character with say 5 different animations (run, jump, idle, etc), those are all eating up performance even though they are not being used until a certain button or event has occurred?

Of all my difficulties in programming, performance has been the most stressful..especially for mobile devices!

Thanks again!
Twitter: https://twitter.com/pudgyplatypus

Learn to make a clicker game for cheap!
https://www.scirra.com/store/games-with ... e-game-666

Try out Pixel Golf on the Scirra Arcade!
https://www.scirra.com/arcade/sports-ga ... el-golf-67

Pudgy Platypus Games website!
www.pudgyplatypus.com
B
59
S
20
G
5
Posts: 212
Reputation: 7,390

Post » Thu Apr 10, 2014 6:43 pm

no it uses cpu and gpu only when they render from my understanding.
what i said above is that imagine 10 instances of your enemy all going left and right with your cellphone trying to animate 200 png's per second for each!
so although when they don't animate you don't use processing power you will face another problem with many different png's.
because mobiles at the moment load all assets from all your layouts at startup the cellphone does not have enough ram and it either crashes or it exits.
there is yet no layout by layout loading.
so the more png's the more stress you put on your cellphone when the game starts for the first time.
B
15
S
6
G
4
Posts: 277
Reputation: 3,948

Post » Thu Apr 10, 2014 9:38 pm

each image from your animation also has to be loaded when you first run your game. And so your file sizes go way up as well, then download times go up, loading times etc etc.

If you have a lot of animations its best to try and make your character using a tool such as spriter to break up the body parts into parts, then all of the animations are stored in json txt data. So you are only loading 1 texture atlas, and only a few kb for the json txt document.
B
87
S
44
G
16
Posts: 1,005
Reputation: 17,938


Return to Construct 2 General

Who is online

Users browsing this forum: No registered users and 12 guests