-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathNunchuckState.cs
43 lines (39 loc) · 1014 Bytes
/
NunchuckState.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
using System;
using System.Collections.Generic;
using System.Text;
using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.Input;
namespace TheraWii
{
class NunchuckState : WiiControllerState
{
public ButtonState c;
public ButtonState z;
public float joyAngle;
public float joyMagnitude;
public float roll;
public float pitch;
public Vector3 accel;
public NunchuckState()
{
accel = Vector3.Zero;
}
public void Initialize()
{
c = ButtonState.Released;
z = ButtonState.Released;
joyAngle = 0;
joyMagnitude = 0;
connected = false;
}
public Boolean connected;
public Boolean isConnected()
{
return connected;
}
internal NunchuckState Copy()
{
return (NunchuckState)this.MemberwiseClone();
}
}
}