pub.h 962 B

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. #pragma once
  2. #ifndef _pub_h__
  3. #define _pub_h__
  4. #include <iostream>
  5. #include <stdlib.h>
  6. #include <vector>
  7. using namespace std;
  8. #define LEFT_FOOT 1
  9. #define RIGHT_FOOT 2
  10. //#define DANCING_THRESH 5
  11. #define DANCING_THRESH 0
  12. #define CIRCLE_CENTER 22
  13. #define ORIGINTRAJ 0
  14. #define RUNGAME 1
  15. #define DANCEGAME 2
  16. #define H5GAME 3
  17. #define RSSI_LIMIT
  18. #define PI 3.141592653
  19. #define DANCEGAME_MIN_RSSI 26
  20. #define PRESS_MIN 41000
  21. #define GAME_VERSION "0.3.5"
  22. enum CMD_MOTION
  23. {
  24. MOTION_STOP = 0,
  25. MOTION_RUN, // 跑
  26. MOTION_JUMP, // 跳
  27. MOTION_DOWN, // 蹲
  28. MOTION_LEFT, // 滑左
  29. MOTION_RIGHT, // 滑右
  30. MOTION_FRONT, // 滑前
  31. MOTION_BACK, // 滑后
  32. MOTION_LEFT_UP, // 点击-左上
  33. MOTION_LEFT_DOWN, // 点击-左下
  34. MOTION_RIGHT_UP, // 点击-右上
  35. MOTION_RIGHT_DOWN, // 点击-右下
  36. MOTION_STEP, // 点击-原地踩
  37. NUMBERS_OF_MOTION,
  38. MOTION_CANCEL = 0x0100,
  39. };
  40. struct posData
  41. {
  42. float pos_x;
  43. float pos_y;
  44. float rssi;
  45. };
  46. #endif