How do I create a balloon

Get help using Construct 2

Post » Sat Oct 07, 2017 11:54 am

Hi guys I have a balloon that moves to the player but how do i create the string that pinned to the player and the balloon that gets longer depending on if the balloons far away and shorter when it get closer?
Image
B
31
S
16
G
12
Posts: 318
Reputation: 9,854

Post » Sat Oct 07, 2017 12:08 pm

Create a sprite "BalloonString" - a horizontal line.
Set origin image point at its left end.
Set position of this sprite to the player's hand and pin it to the player.

Then do this:
Code: Select all
On every tick
  BalloonString -> set Width to Distance(player.x, player.y, balloon.x, balloon.y)
  BalloonString -> set Angle towards position (Balloon.x, balloon.y)
Image

Did I help to fix a problem in your game? You can buy me a cup of coffee :)
B
17
S
9
G
69
Posts: 1,048
Reputation: 37,659


Return to How do I....?

Who is online

Users browsing this forum: No registered users and 8 guests