How do I load section of sprite

Get help using Construct 2

Post » Mon Mar 10, 2014 11:20 pm

i use larger images that has animations on them on specific coordinates and i want to load a frame from x,y,width,height from a loaded sprite then have a loop and get all frames for animation,
why, you ask?
minimize requests of loading a lot of frames, you have on image that contains all frames, sure it might be larger but your app doesnt have to download every single frame.it should save loading time and have a neater directory structure.
B
9
S
2
Posts: 76
Reputation: 709

Post » Tue Mar 11, 2014 6:03 am

C2 loads all images at the beginning regardless
B
84
S
22
G
15
Posts: 1,039
Reputation: 15,249

Post » Tue Mar 11, 2014 8:03 am

if so my method will save a few requests...
B
9
S
2
Posts: 76
Reputation: 709

Post » Tue Mar 11, 2014 8:17 am

C2 automatically gather all animations on one big texture on export, so under the hood it exactly does what you are suggesting.
B
66
S
22
G
14
Posts: 1,484
Reputation: 16,511

Post » Tue Mar 11, 2014 3:59 pm

awesome
B
9
S
2
Posts: 76
Reputation: 709


Return to How do I....?

Who is online

Users browsing this forum: brunopalermo, Colludium, Kin, worm1 and 30 guests