there is a bug in my game ....

Get help using Construct 2

Post » Sun Aug 30, 2015 11:27 am

hi, i am working on a ragdoll game and i placed a pin behavior on the head, but the problem is when i run the game, the ragdoll moves automatically to the head position ... example : if the head is pointing to the right, the ragdoll moves to the right.
can anyone help me with that?
C2 Intermediate Developer
Feel free to contact me
B
7
S
2
Posts: 111
Reputation: 908

Post » Mon Aug 31, 2015 1:54 am

Start by taking a look at the imagepoint of the head. Without looking at your code, it's difficult to say specifically. Also remove the pin behavior and see what happens.
Image
B
75
S
23
G
3
Posts: 673
Reputation: 9,293

Post » Mon Aug 31, 2015 7:38 am

ok but where could i put the imagepoint, i tried every imagepoint position before posting this topic, and... i can screenshot my head events if u want. and if i removed the pin behavior,one bug will be removed but another one wil be created. so i dont know what to do.
C2 Intermediate Developer
Feel free to contact me
B
7
S
2
Posts: 111
Reputation: 908

Post » Mon Aug 31, 2015 7:48 am

this is the condition and actions...
Condition : On start of layout
Actions :
Image
C2 Intermediate Developer
Feel free to contact me
B
7
S
2
Posts: 111
Reputation: 908

Post » Mon Aug 31, 2015 11:37 am

Seems you are creating three different joints at the same position AND pinning the head..

Why 3 different joints and why use the pin behaviour at all?
I told my dentist I had trouble with my teeth and asked her to fix it without looking in my mouth..
B
54
S
16
G
8
Posts: 6,160
Reputation: 19,775

Post » Mon Aug 31, 2015 1:24 pm

when i remove the pin behavior, the head gets very far from the body, so i putted the pin behavior on the head so it doesn't get far.... and i putted the 3 joints because...
1.limited revolute joint : i want to make the head in an locked angle
2.distance joint : because i want to make the head in a locked position to the body.... and it seems it didnt work so i placed the pin behavior.
P.S when i placed the pin behavior, i solved one bug, but i created another bug ..
C2 Intermediate Developer
Feel free to contact me
B
7
S
2
Posts: 111
Reputation: 908

Post » Mon Aug 31, 2015 2:19 pm

@Ihab7

You should only create the limited revolute joint, and not use pin. If the joint is being created properly the head will stay where you want it.
B
99
S
35
G
20
Posts: 438
Reputation: 17,910

Post » Tue Sep 01, 2015 2:05 pm

The revolute joint is for limited angle .... i want a limited distance, from the head to the body, Anyway i tried it before but it didn't work, so i need another solution.
thanks anyway.
C2 Intermediate Developer
Feel free to contact me
B
7
S
2
Posts: 111
Reputation: 908


Return to How do I....?

Who is online

Users browsing this forum: No registered users and 7 guests