Pinning an angel

0 favourites
  • 7 posts
From the Asset Store
A various fantasy RPG characters sprites for creating a 2D platformer or sidescroller game.
  • Hi all, i want to know how the pin plug in works so i can do it it construct but only with angel, i am missing a bit of logic.So i want to be able to "pin" object 1's angle to object 2 for a while and then if object 2 is at a certain point i want to cancel the pin. But ONLY the angel please thank you.

  • Let's say you have item A and item B and you want to pin A to B

    Select item A in the layout editor and add the PIN behaviour

    Now in the event editor create an event that you want to use to actually pin the items. You could just use AT START OF LAYOUT

    Then for that event create a new action and click item A. Select PIN TO OBJECT. In the next box select object B as the object to pin to and ANGLE ONLY as the mode.

    That's it. From now on the items will move around together.

    Once item B is where you want it to unpin from item A you just check using an event for item B. It's as simple as creating an UNPIN action for that event.

  • vandinz I know how to do that i dont want the objects to move around together only the angels should be the same.

  • Here's a quick cap I made. Hope this helps.


    You will notice the angles are NOT the same. This is because you MUST set the angles to match before pinning them. All pinning does is rotate them the same amount. It's a simple case of setting ITEM A's angle to ITEM B BEFORE pinning them if you want the angles to match.

    EDIT - I've updated the CAPX to match the angles in case you needed that. Just omit that if you don't.

  • It's pretty simple to do without the pin behaviour, you can just use the "Set angle" action:

    AnglePin.capx (r101)

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Thanks for the help but now i want object A to begin rotating again but with the same amout of differance in angel between A and B (makes sense?)And i am using an old construct 2 that doesn't have the option of only angle pin.

  • thanks i downloaded a newer construct 2 and fixed it with pin but would stil like to know how to do it with event's

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)