dual stick problem

0 favourites
  • 5 posts
From the Asset Store
This is a twin stick shooter similar to Enter the gungeon,Nuclear Throne, Helldivers & Soul knight for the mobile device
  • I'm new to this program, so I have been reading tutorials, watching videos, etc.. as I have been working on a basic top down shooter to get my feet wet. I have an image sprite that I can move around with my left analog stick, and rotate with my right analog stick, and fire bullets with my right trigger. My problem is that when I release the right analog stick, my sprite automatically rotates back to its starting angle instead of staying at it's last angle. I've used the angle(0,0,Gamepad.Axis(0,2),Gamepad.Axis(0,3)) to allow it to rotate and keep it at the position it is at as long as my analog stick. Is there a way to make the sprite not automatically rotate back to it's original angle?

    Thanks for any help, and for patience with what are probably silly questions.

  • newbie99

    Hey mate, not sure how your events are structured but I'll hazard a guess you have it on an "Every Tick > Set Angle to: angle(0,0,Gamepad.Axis(0,2),Gamepad.Axis(0,3))" kind of thing?

    As long as you don't care to much about deadzones.. you could Try using "Compare Axis" instead, if "Right Analog X" is "not equal to" to 0 then > set angle to...

    hope it helps

  • I tried using hte Compare Axis, and I'm still having it return back to it's original point. It's not a huge deal, but I'll keep playing with it to see if I can get it working right.

  • I can take a look at your code for you if like if you want to upload/attach it?

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • I'm new to this program also and had the same problem. I did it this way.

    [attachment=0:771yj36o][/attachment:771yj36o]

    Seems to work.

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