Advertisement
Guest User

Untitled

a guest
Oct 27th, 2019
205
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.27 KB | None | 0 0
  1. #include "DxLib.h"
  2.  
  3. #ifndef DEF_KEY_H //二重include防止
  4.  
  5. #define DEF_KEY_H
  6. int Key[256];
  7.  
  8.  
  9. int gpUpdateKey()
  10. {
  11.     char tmpKey[256];
  12.     GetHitKeyStateAll(tmpKey);
  13.     for (int i = 0; i < 256; i++)
  14.         (tmpKey[i] == 0) ? (Key[i] = 0) : Key[i]++;
  15.     return 0;
  16. }
  17.  
  18. #endif
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement