[BEHAVIOR] Chipmunk Physics

Post your completed addons to share with the community

Post » Thu Feb 25, 2016 8:44 pm

@AnD4D

That could be achieved by setting force (polar) to

force : max amount - clamp(distance(object.x,object.y,blackhole.x,blackhole.y),0,max amount)
angle : angle(object.x,object.y,blackhole.x,blackhole.y)
B
70
S
24
G
9
Posts: 175
Reputation: 7,539

Post » Thu Feb 25, 2016 9:35 pm

I use chipmunk for the joint capabilities, here is something I was working on last year:
Image
B
48
S
23
G
66
Posts: 1,144
Reputation: 39,059

Post » Sat Mar 05, 2016 1:41 pm

Please someone help me, I have a falling box with physics behavior i want to change his direction when i swipe, the box will move to right or to left and continue to fall as the image below
Im using chipmunk plugin
Image
B
5
Posts: 27
Reputation: 281

Post » Sat Mar 05, 2016 2:51 pm

Hello @MarkeGamer,

I've never used the touch but, basicaly I think just check the direction of the touch (with somethin like touch start and touch end, I don't know) and apply an impulse with Chipmunk physics at that direction or an angle (switch to polar when setting the impulse).
B
14
S
4
Posts: 112
Reputation: 1,287

Post » Sat Mar 05, 2016 3:05 pm

MarkeGamer you could do it like

is in touch Box Set angle towards (touch.x)
(Touch.y)
B
257
S
42
G
15
Posts: 1,991
Reputation: 41,411

Post » Sat Mar 05, 2016 3:08 pm

Nabu0001 wrote:Hello @MarkeGamer,

I've never used the touch but, basicaly I think just check the direction of the touch (with somethin like touch start and touch end, I don't know) and apply an impulse with Chipmunk physics at that direction or an angle (switch to polar when setting the impulse).

Thanks for reply can you please give me a sample example if you want im newbies in construct 2
B
5
Posts: 27
Reputation: 281

Post » Sat Mar 05, 2016 3:10 pm

Lordshiva1948 wrote:MarkeGamer you could do it like

is in touch Box Set angle towards (touch.x)
(Touch.y)


please can you tell me how with an example coz im a newbie in construct 2
B
5
Posts: 27
Reputation: 281

Post » Sat Mar 05, 2016 4:24 pm

MarkeGamer you will find demo here and many more as you are newbie in construct 2


https://www.dropbox.com/s/djjowh9avzqpb ... .capx?dl=0
B
257
S
42
G
15
Posts: 1,991
Reputation: 41,411

Post » Sat Mar 05, 2016 4:55 pm

Message: MarkeGamer can only post plain text URLS until they have 500 rep. 1 URLS modified. Why?
Lordshiva1948 wrote:MarkeGamer you will find demo here and many more as you are newbie in construct 2


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


Firstable thanks for your reply in fact it's almost what i need except one thing i want the green box, falling down to the bottom even when i change his direction as you did in your code
B
5
Posts: 27
Reputation: 281

Post » Sat Mar 05, 2016 8:26 pm

MarkeGamer See Falling demo again and let me know is that what you want?

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

many more as you are newbie in construct 2

https://www.dropbox.com/sh/eioscti86bpr ... 7YPza?dl=0
B
257
S
42
G
15
Posts: 1,991
Reputation: 41,411

PreviousNext

Return to Completed Addons

Who is online

Users browsing this forum: No registered users and 1 guest