This commit is contained in:
2025-08-27 08:46:45 +08:00
parent 1fddc97e20
commit 79185568a0
13 changed files with 26503 additions and 429 deletions

16
pch.h
View File

@@ -19,13 +19,14 @@
#include "sqstdstring.h"
#include "sqstdsystem.h"
#include "iconv.h"
#include<d3d9.h>
#endif //PCH_H
//# define EXPRESS "学习版"
# define SELL "售出模式"
//# define SELL "售出模式"
#define INVERSION "24112901"
@@ -38,7 +39,7 @@
static void Cutecode(char* pstr, int* pkey, int len = -1);
static void Cutecode(char* pstr, int* pkey, int len = -1, int keyLength = 5);
//单个字符解密
static char CutcodeChar(char c, int key, int key2) {
char a = (((c - 1) ^ key) ^ key2) - key;
@@ -46,10 +47,13 @@ static char CutcodeChar(char c, int key, int key2) {
}
//解密
static void Cutecode(char* pstr, int* pkey, int len) {
if (len == -1)len = strlen(pstr);
for (int i = 0; i < len; i++)
*(pstr + i) = CutcodeChar(*(pstr + i), pkey[i % 5], pkey[(i + 18) % 5]);
static void Cutecode(char* pstr, int* pkey, int len , int keyLength) {
if (len == -1) len = strlen(pstr);
for (int i = 0; i < len; i++) {
*(pstr + i) = CutcodeChar(*(pstr + i),
pkey[i % keyLength],
pkey[(i + 18) % keyLength]);
}
}