Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //==========AI.h===========
- #ifndef AI_INCLUDED
- #define AI_INCLUDED
- //=================================
- // included dependencies
- #include "Object.h"
- #include <string>
- //=================================
- class AI_Stuff
- {
- private:
- int _rate_count=0;
- std::string _key_buffer[6]= {"", "", "", "", "", ""};
- void holdKey(int keyindex);
- void tapKey(int keyindex, float rate);
- void releaseKey(int keyindex);
- void updateControls(objcopy * objcop);
- void pushKey(int keyid);
- void clearKeyBuffer();
- public:
- int _current_target=4321;
- /*
- 0: Up; 1: Down; 2: Left; 3: Right;
- 4: Attack; 5: Defend; 6: Jump; 7: Special;
- */
- bool _keys[8]= {false, false, false, false, false, false, false, false};
- void setTarget(objcopy * objcop, LOAD * LOADED);
- void playAI(objcopy * objcop, LOAD * LOADED);
- };
- #endif // AI_INCLUDED
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement