Character arm joints and weapon problem

0 favourites
  • 11 posts
From the Asset Store
Futuristics Weapons Vol 1 includes 8 different weapons, in a total of 216 sounds
  • Hello, I decided to finally register and ask experts here because this problem is literally driving me crazy, I have spent two entire days trying to figure out how to do this, without success.

    I absolutely love Construct 2. <img src="smileys/smiley32.gif" border="0" align="middle" /> I am using it to create my vision of what a great game should be, I have been working at it for the past month doing character design and animation, inventory management, jetpack behavior, etc...

    I'm very excited to share it with you all as soon as it meets the standards I'm aiming for. I believe this is something lots of people will have fun with. But for now, I simply can't figure out how to set the proper behavior for my character arms and weapon(s).

    I have a sprite with the body only, sprites for upper arms, lower arms, hands and weapon(s), I have tried everything I could, set position on body from start, pin, apply physics, etc... I have read all the tutorials I could find on physics, tried to compare with existing capx exemples I could find in Construct 2 folder and on this forum, it just never behaves like I expect it... It either rotates like crazy, or explodes... I am almost starting to believe that it simply is too complex to be done that way.. but I have done other complex things like a whole inventory management with items positionning according to a whole lot of conditions so I don't know.. <img src="smileys/smiley5.gif" border="0" align="middle" />   

    The character is supposed to aim at 'Mouse.X & Mouse.Y' with the weapon, having upper arm pinned on 'position only' to ImagePoint1 on the body which is Left shoulder and the rest in the same logical way. Aiming up or down would make the arms and hand follow in a realistic/rope way.

    I understand this might be quite a complex request (at least for me it's a total mistery so far on how to do this) but if you manage to see what I intend to do and can explain to me how to achieve it that would trully be amazing. I could keep moving forward on the game creation.

    Here's a quick Capx I made to recreate the elements I'm working with.

    dl.dropbox.com/u/995217/Arm%20joints%20and%20Weapon.capx

    Also, If someone has a better way of doing it (also running and aiming at mouse with weapon, standing and keeping the aim), I'm interested in hearing your idea!

    Thanks for reading me!

  • It is actually quite simple. Set the angle of the arm to Mouse.X and Mouse.Y

    Good luck with your game

  • I wish it was that simple but it's not. If I do that, the elements don't remain linked to one another like they're supposed to.

    Weapon attached to the body and rotating on it, hand attached to handle, lower arm attached to hand, upper arm pinned on body shoulder and attached to lower arm. All of this moving accordingly to the Weapon aiming at the Mouse and with the back arm and hand too.

  • Ah, yeah that is a lot more difficult. The main problem you have in the capx file is the way you set up the angles of the body parts in the beginning. Look at how I have set them up, all angle 0 and facing right.

    I have a beginning here for you, don't want to do everything for you haha :P

    Good luck

    Donwload it here

  • Thank you! I will give a look at this as soon as I get home!

  • Construct considers the right side of the sprite to be the front. So all rotation should take that into account.

  • Biino I can't save your file, it redirects me to a "Server Error in '/' Application. The resource cannot be found. " page.

    Alright for the starting angle, but what about linking them all between them? Should I use physics? I noticed it doesn't seem very reliable on small items or maybe is it just me setting things up the wrong way. Or should I use "pin"? Or are there any other better methods to do it?

  • Can anyone help please?

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Telyko, here's the link (right-click save-as): http://www.berryijmker.com/games/HelpbyBiino.capx

  • Oh that seems like a nice base. I'm going to see if I can set it up the way I want now. I'll let you know!

    Thank you!

  • Ow sorry for the error, but thanks for solving it jayjay :)

    Glad I could help :)

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