How do I re scale an object over time

Get help using Construct 2

Post » Wed Mar 08, 2017 4:27 pm

i want an object in scene to reduce its scale every second. i used: every 1 second / set scale to "vida.height-5" but what i get as a result is a brief screenshot of the object at full scale (i think at the actual size of the object which is 400pixels x 400 pixels ) and then disappears, and repeats every 1 second until it completly stop after like 6 seconds. it's like it detects the virgin object and pastes it on screen.
help :roll:
B
5
Posts: 31
Reputation: 291

Post » Wed Mar 08, 2017 4:42 pm

Scale in 'set scale' is referencing to 'the virgin object'. A scale 1 means = the width & height of the virgin object (as see in the sprite editor). In your case 'vida.height-5' starts probably at 50 (or so), so 50 times the width & height of the virgin object. Yes you see a flash.

Use 'Set size'.
B
33
S
18
G
28
Posts: 2,493
Reputation: 20,950

Post » Wed Mar 08, 2017 6:39 pm

done it. but now it moves when its size changes. moves like diagonally and keeps going further and further
B
5
Posts: 31
Reputation: 291

Post » Wed Mar 08, 2017 7:15 pm

Then the origin is not in the middle.
B
33
S
18
G
28
Posts: 2,493
Reputation: 20,950

Post » Wed Mar 08, 2017 7:35 pm

99Instances2Go wrote:Then the origin is not in the middle.

now it wont get smaller. it just bumps
B
5
Posts: 31
Reputation: 291

Post » Wed Mar 08, 2017 8:11 pm

Using size. Goes from height/width to zero. Cant allow negative numbers.

https://www.dropbox.com/s/7gv0d9b2w1bag ... .capx?dl=0

Using scale. Goes from 1 to zero. Cant allow negative numbers. (and a scale factor of 2 doubles the object)

https://www.dropbox.com/s/iurucdduv7n6b ... .capx?dl=0


Side read: about origins : https://www.scirra.com/manual/63/image-points
B
33
S
18
G
28
Posts: 2,493
Reputation: 20,950


Return to How do I....?

Who is online

Users browsing this forum: ditocruz and 22 guests