Ejemplo n.º 1
0
 // Token: 0x06000106 RID: 262 RVA: 0x00032098 File Offset: 0x00030298
 public static void MenuKeyDown(InputResult gameInput, byte keyFlags)
 {
     gameInput.touches = 0;
     for (int i = 0; i < 4; i++)
     {
         if (InputSystem.touchData.touchDown[i] == 1)
         {
             gameInput.touchDown[gameInput.touches] = InputSystem.touchData.touchDown[i];
             gameInput.touchX[gameInput.touches]    = InputSystem.touchData.touchX[i] * GlobalAppDefinitions.SCREEN_XSIZE / InputSystem.touchWidth;
             gameInput.touchY[gameInput.touches]    = InputSystem.touchData.touchY[i] * 240 / InputSystem.touchHeight;
             gameInput.touches++;
         }
     }
 }
Ejemplo n.º 2
0
 // Token: 0x06000105 RID: 261 RVA: 0x00031F34 File Offset: 0x00030134
 public static void CheckKeyDown(InputResult gameInput, byte keyFlags)
 {
     gameInput.touches = 0;
     for (int i = 0; i < 4; i++)
     {
         if (InputSystem.touchData.touchDown[i] == 1)
         {
             gameInput.touchDown[gameInput.touches] = InputSystem.touchData.touchDown[i];
             gameInput.touchX[gameInput.touches]    = InputSystem.touchData.touchX[i] * GlobalAppDefinitions.SCREEN_XSIZE / InputSystem.touchWidth;
             gameInput.touchY[gameInput.touches]    = InputSystem.touchData.touchY[i] * 240 / InputSystem.touchHeight;
             gameInput.touches++;
         }
     }
     if ((1 & keyFlags) == 1)
     {
         gameInput.up = InputSystem.touchData.up;
     }
     if ((2 & keyFlags) == 2)
     {
         gameInput.down = InputSystem.touchData.down;
     }
     if ((4 & keyFlags) == 4)
     {
         gameInput.left = InputSystem.touchData.left;
     }
     if ((8 & keyFlags) == 8)
     {
         gameInput.right = InputSystem.touchData.right;
     }
     if ((16 & keyFlags) == 16)
     {
         gameInput.buttonA = InputSystem.touchData.buttonA;
     }
     if ((32 & keyFlags) == 32)
     {
         gameInput.buttonB = InputSystem.touchData.buttonB;
     }
     if ((64 & keyFlags) == 64)
     {
         gameInput.buttonC = InputSystem.touchData.buttonC;
     }
     if ((128 & keyFlags) == 128)
     {
         gameInput.start = InputSystem.touchData.start;
     }
 }
Ejemplo n.º 3
0
 // Token: 0x06000107 RID: 263 RVA: 0x00032140 File Offset: 0x00030340
 public static void CheckKeyPress(InputResult gameInput, byte keyFlags)
 {
     if ((1 & keyFlags) == 1)
     {
         if (InputSystem.touchData.up == 1)
         {
             if (InputSystem.inputPress.up == 0)
             {
                 InputSystem.inputPress.up = 1;
                 gameInput.up = 1;
             }
             else
             {
                 gameInput.up = 0;
             }
         }
         else
         {
             gameInput.up = 0;
             InputSystem.inputPress.up = 0;
         }
     }
     if ((2 & keyFlags) == 2)
     {
         if (InputSystem.touchData.down == 1)
         {
             if (InputSystem.inputPress.down == 0)
             {
                 InputSystem.inputPress.down = 1;
                 gameInput.down = 1;
             }
             else
             {
                 gameInput.down = 0;
             }
         }
         else
         {
             gameInput.down = 0;
             InputSystem.inputPress.down = 0;
         }
     }
     if ((4 & keyFlags) == 4)
     {
         if (InputSystem.touchData.left == 1)
         {
             if (InputSystem.inputPress.left == 0)
             {
                 InputSystem.inputPress.left = 1;
                 gameInput.left = 1;
             }
             else
             {
                 gameInput.left = 0;
             }
         }
         else
         {
             gameInput.left = 0;
             InputSystem.inputPress.left = 0;
         }
     }
     if ((8 & keyFlags) == 8)
     {
         if (InputSystem.touchData.right == 1)
         {
             if (InputSystem.inputPress.right == 0)
             {
                 InputSystem.inputPress.right = 1;
                 gameInput.right = 1;
             }
             else
             {
                 gameInput.right = 0;
             }
         }
         else
         {
             gameInput.right = 0;
             InputSystem.inputPress.right = 0;
         }
     }
     if ((16 & keyFlags) == 16)
     {
         if (InputSystem.touchData.buttonA == 1)
         {
             if (InputSystem.inputPress.buttonA == 0)
             {
                 InputSystem.inputPress.buttonA = 1;
                 gameInput.buttonA = 1;
             }
             else
             {
                 gameInput.buttonA = 0;
             }
         }
         else
         {
             gameInput.buttonA = 0;
             InputSystem.inputPress.buttonA = 0;
         }
     }
     if ((32 & keyFlags) == 32)
     {
         if (InputSystem.touchData.buttonB == 1)
         {
             if (InputSystem.inputPress.buttonB == 0)
             {
                 InputSystem.inputPress.buttonB = 1;
                 gameInput.buttonB = 1;
             }
             else
             {
                 gameInput.buttonB = 0;
             }
         }
         else
         {
             gameInput.buttonB = 0;
             InputSystem.inputPress.buttonB = 0;
         }
     }
     if ((64 & keyFlags) == 64)
     {
         if (InputSystem.touchData.buttonC == 1)
         {
             if (InputSystem.inputPress.buttonC == 0)
             {
                 InputSystem.inputPress.buttonC = 1;
                 gameInput.buttonC = 1;
             }
             else
             {
                 gameInput.buttonC = 0;
             }
         }
         else
         {
             gameInput.buttonC = 0;
             InputSystem.inputPress.buttonC = 0;
         }
     }
     if ((128 & keyFlags) == 128)
     {
         if (InputSystem.touchData.start == 1)
         {
             if (InputSystem.inputPress.start == 0)
             {
                 InputSystem.inputPress.start = 1;
                 gameInput.start = 1;
                 return;
             }
             gameInput.start = 0;
             return;
         }
         else
         {
             gameInput.start = 0;
             InputSystem.inputPress.start = 0;
         }
     }
 }