Example #1
0
 public Input(int index)
 {
     this.gamepadIndex = index;
     using (StreamReader reader = new StreamReader("input.json"))
     {
         string json = reader.ReadToEnd();
         mapping = new JavaScriptSerializer().Deserialize <List <InputMapping> >(json).Single(m => m.index == index);
     }
 }
Example #2
0
 public Input(InputMapping mapping)
 {
     gamepadIndex = mapping.index;
 }