我把框架整理了一遍
东西都放到了一个命名空间里
其他没啥更新
安装方式和b_game.h1.2一样
#ifndef b_game #define b_game #include#include #include #include #include #include #include #include using namespace std; namespace _game { //常量 const long long ESC=27, Enter=13, Tab=9, Shang=38, Xia=40, Zuo=37, You=39, Kong=' ', z_sb=VK_LBUTTON, y_sb=VK_RBUTTON, Shift=VK_SHIFT, z_Shift=VK_LSHIFT, y_Shift=VK_RSHIFT, Ctrl=VK_CONTROL, z_Ctrl=VK_LCONTROL, y_Ctrl=VK_RCONTROL, Alt=VK_MENU, z_Alt=VK_LMENU, y_Alt=VK_RMENU, A='A', B='B', C='C', D='D', E='E', F='F', G='G', H='H', I='I', J='J', K='K', L='L', M='M', N='N', O='O', P='P', Q='Q', R='R', S='S', T='T', U='U', V='V', W='W', X='X', Y='Y', Z='Z'; //结构体 struct cdhs//存档结构体 { void out(int n, string name)//输出存档 { ofstream cd(&name[0]); cd << n; return; } void out(long long n, string name) { ofstream cd(&name[0]); cd << n; return; } void out(bool n, string name) { ofstream cd(&name[0]); cd << n; return; } void out(char n, string name) { ofstream cd(&name[0]); cd << n; return; } void out(string n, string name) { ofstream cd(&name[0]); cd << n; return; }//重载 void in(int& n, string name)//读入存档 { ifstream cd(&name[0]); cd >> n; return; } void in(long long& n, string name) { ifstream cd(&name[0]); cd >> n; return; } void in(bool& n, string name) { ifstream cd(&name[0]); cd >> n; return; } void in(char& n, string name) { ifstream cd(&name[0]); cd >> n; return; } void in(string& n, string name) { ifstream cd(&name[0]); cd >> n; return; }//重载 }; struct hl//行列 { long long h,l; }; //函数 bool axj(long long key) { return (GetKeyState(key)<0); } void bout(string n, long long s=50,bool f=0,char key=13)//输出 { for (long long i = 0; i < n.size(); i++) { if (f&&GetKeyState(key)<0) { cout<



