help move a physics obj

Get help using Construct 2

Post » Sat Jan 28, 2012 1:18 pm


I need some help.

Im trying to create a turn based game platform / worms like.... i have a soldier with a limited revolution joint in he arms to body... works great... or not..

So, i have a button (object) menu with 2 actions, MOVE RIGHT 1X (110 pixels) and other to atack ( create a bullet from weapon in he arms)

When i click on the MOVE button the soldier runs too fast to position +110 pxls RIGHT the soldier goes crazy, cant stop in the exactly position i need and fall( needs to be exactly add 110 pixels RIGHT;;.. and the physics trow the man to ground.. or create some bugs movements.. etc...

If i dont use a physics in the soldier, the movement and all runs great! but.. i loose the importants revolutions joints im my char, itens, bag.. arm movement .. etc......


So.. anybody can help me..

I ll post the capx if necessary.

sorry my poor english...

Thanks a Lot.

updated. capx link

my capxjardelbr2012-01-28 13:54:25
B
22
S
2
G
5
Posts: 49
Reputation: 4,827

Post » Sat Jan 28, 2012 1:28 pm

Yeap CAPX is neccessary
B
42
S
19
G
12
Posts: 723
Reputation: 13,911

Post » Sat Jan 28, 2012 1:55 pm

[QUOTE=Weishaupt] Yeap CAPX is neccessary[/QUOTE]


ok.. here the capx.



capx
B
22
S
2
G
5
Posts: 49
Reputation: 4,827

Post » Sat Jan 28, 2012 2:33 pm

You could try this:

1, Give the 'body' a private variable called 'move'.

2, Add the following events:


Hope this helps.
B
19
S
6
G
7
Posts: 1,205
Reputation: 7,298

Post » Sat Jan 28, 2012 2:34 pm

Ok...here the first sightings:

If you set "prevent rotation" to "YES" on "body" it seems to work just fine...
B
42
S
19
G
12
Posts: 723
Reputation: 13,911

Post » Sat Jan 28, 2012 7:56 pm

hey cris.. thanks.. im sure its will be helpfull.
im on streets now, tonight will try ok.

weishaupt - thanks too ..i think this will work too..

thanks everybody for the help. soon as possible will post the results ok?
B
22
S
2
G
5
Posts: 49
Reputation: 4,827

Post » Sat Feb 04, 2012 2:05 am

works great. thanks. so much!!!
B
22
S
2
G
5
Posts: 49
Reputation: 4,827


Return to How do I....?

Who is online

Users browsing this forum: TELLES0808 and 22 guests