0 Favourites

What's the best way join physics sprites?

  • I have a game with lots of instances of the same sprite. They all have the physics behaviour. When they collide, I'd really like them to stick together ... but I always end up with a expression that looks like "On collision with Sprite ... Add revolute joint to Sprite", which doesn't work (because I can't work out how to select two different instances of the same object inside a loop).

    Below is a non-working example of what I'd like to achieve. The two balls should hit each other an join together in one physics object.

    (Apparently, even though I've got a paid licence I can't post links ... so sorry I can't post an example...)

    Any ideas on the best way to achieve this?

    Ben

  • Construct 3

    Buy Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Buy Now Construct 3 users don't see these ads
  • I think you could post the URL without hyperlink, will be easier for people to help with an example.

  • Thanks. I worked out a way to do it with Families. Basically adding sprites to a family gives you the ability to "pick by UID", which is all I needed. Not sure why you need to use a family to access "pick by UID", but there you go.

    I got the solution looking at the rope examples around the place.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)
Similar Topics Posts Views Last Post
Unread hot topic
1,941 263,207
FlyingRam's avatar
FlyingRam
Unread hot topic
0 Favourites
[BEHAVIOR] Chipmunk Physics
673 82,480
nelostic's avatar
nelostic
Unread hot topic
0 Favourites
Sprite Font Generator - v3
368 112,280
RetroDaddy's avatar
RetroDaddy