Unity for 3DS. How to map 3DS Triggers

  • Thread starter Thread starter jvncti0n
  • Start date Start date
  • Views Views 1,056
  • Replies Replies 0

jvncti0n

Member
Newcomer
Joined
Jul 11, 2023
Messages
10
Solutions
1
Reaction score
0
Trophies
0
Location
Canada
XP
66
Country
Canada
I'm using the 3DS Input System (using UnityEngine.N3DS;) and I'm trying to port a few games to 3DS, I have everything figured out except triggers

if (GamePad.GetButtonHold(N3dsButton.Y))
{
this.playerSpeed = this.runSpeed;
if (this.rb.velocity.magnitude > 0.1f & !this.hugging & !this.sweeping)
{
this.ResetGuilt("running", 0.1f);
}
}
if (GamePad.GetButtonRelease(N3dsButton.Y))
{
this.playerSpeed = this.walkSpeed;
}



This is the code for sprinting. I'm using the Y button but I would like to use the right trigger for sprinting not the Y button as I would like to use the X, B buttons for forwards and backwards movement and Y, A buttons for left and right.

Which brings me to my next thing how would I do that.
This is the code for movement controls:

a = base.transform.forward * Input.GetAxis("Horizontal");
b = base.transform.right * Input.GetAxis("Vertical");
 

Site & Scene News

Popular threads in this forum