//以下变量只需要初始化一次 staticint iInitedHookPos = 0; if(0==iInitedHookPos) { iInitedHookPos = 1; //钩子初始位置值初始化 g_fHookStartPosX = dGetSpritePositionX("GoldHook"); g_fHookStartPosY = dGetSpritePositionY("GoldHook"); //金子可以出现的边界范围初始化 g_iGoldBornMinX = dGetWorldLeft()+5; g_iGoldBornMaxX = dGetWorldRight()-5; g_iGoldBornMinY = dGetWorldTop()+20; g_iGoldBornMaxY = dGetWorldBottom()-5; }
2024/7/26 12:30:16
3.59MB
C语言
1