How do I Move sprites to specific position?

Get help using Construct 2

Post » Thu Mar 23, 2017 2:37 pm

I am making a football themed game.

I want all the cards (players) to start in the middle before automatically dispersing into formation.

How would i do this?

thanks
B
5
S
1
Posts: 65
Reputation: 507

Post » Sun Mar 26, 2017 3:36 pm

You can either set each position manually, or you can use math.
https://www.ravenheart.ca/home
Company name changed to avoid Facebook-type shenanigans

"Someone once told me I bite off more than I can chew...

I told them I would rather choke on greatness than nibble on mediocrity."
B
22
S
6
G
1
Posts: 1,414
Reputation: 4,822

Post » Mon Mar 27, 2017 5:32 pm

gumshoe2029 wrote:You can either set each position manually, or you can use math.


I'm sorry for being unclear but I understand how to set sprites to a position but i want to actually "move" to that position rather than instantly being placed in the new position.

I'm assuming the best way to do this will be with the bullet behavior but Im unsure how to get it working.
B
5
S
1
Posts: 65
Reputation: 507

Post » Mon Mar 27, 2017 5:35 pm

try this behavior: behavior-litetween_t70700
B
68
S
17
G
2
Posts: 94
Reputation: 4,742

Post » Mon Mar 27, 2017 6:07 pm

Here is the easy answer - use Rex's moveto plugin: http://c2rexplugins.weebly.com/rex_moveto.html

Second easiest would be bullet behaviour. You'll need a "start moving" event, where you enable bullet and set the direction and speed, and a "stop moving" event where you disable bullet. The conditions for each of those are up to you. (Invisible sprites are excellent tools for this - you can set the invisible sprite as a "target" when you start and stop when you collide with it)

There are also many ways to create your own custom movement through events.
Mistakes were made.
B
49
S
24
G
107
Posts: 1,581
Reputation: 60,303

Post » Tue Mar 28, 2017 9:07 am

Thanks Buddies.
B
5
S
1
Posts: 65
Reputation: 507


Return to How do I....?

Who is online

Users browsing this forum: davidbox, Mayfly and 5 guests