(Suggestion)9 patch with animations

Discussion and feedback on Construct 2

Post » Sat Sep 05, 2015 2:00 am

is it possible to add animation support for 9 patch objects?
this would be a useful feature for sprite based menus and things that people need to stretch to fit different sizes
B
13
S
6
G
1
Posts: 149
Reputation: 1,960

Post » Sat Sep 05, 2015 7:23 am

Already been asked before HERE, and the consensus appears to be no.
If your vision so exceeds your ability, then look to something closer.
Moderator
B
134
S
30
G
86
Posts: 5,415
Reputation: 59,516

Post » Mon Sep 07, 2015 11:12 pm

well dang ok then :(
B
13
S
6
G
1
Posts: 149
Reputation: 1,960

Post » Mon Sep 07, 2015 11:41 pm

Generally 9path is putting quite a strain on performance. I suggest you just create several 9path objects, each with different animation frame, and animate them trough events. Best way to do it is to create a family for it, and create family numerical variable, then set object's value of that variable representing a frame that is suppose to be displayed, and then trough simple events, create static local variable with total number of frames and another one that will hold the number of current frame, and then every x ms add 1 to current frame local var, and trough events hide 9path family objects but display the one with variable that local static variable is currently set to. when current frame local var is equal total number of frames, reset current local var to 0.

Hope that makes sense in writing ;)
My professional Royalty Free Music at Scirra Assets Store
--------------------------------
Specs: i5 2500, 16gb of ram, gtx 770, win 7, Focusrite Scarlett 8i6, Mackie mr8mk2, Alesis 320, browsing the net on chrome.
B
89
S
30
G
22
Posts: 1,985
Reputation: 20,099


Return to Construct 2 General

Who is online

Users browsing this forum: Yahoo [Bot] and 8 guests