Files
kichikuou_xsystem35-sdl2/modules/Confirm/Confirm.c
T
2022-09-02 20:37:26 +09:00

54 lines
1.1 KiB
C

#include "config.h"
#include <stdio.h>
#include "portab.h"
#include "system.h"
#include "xsystem35.h"
#include "modules.h"
#include "nact.h"
static void Init() {
int p1 = getCaliValue();
DEBUG_COMMAND_YET("Confirm.Init %d:", p1);
}
static void ExistKeyFile() {
const char *p1 = sl_getString(0);
int *p2 = getCaliVariable();
int *var = getCaliVariable();
*var = 1;
DEBUG_COMMAND_YET("Confirm.ExistKeyFile %s,%p,%p:",p1, p2, var);
}
static void CheckProtectFile() {
const char *p1 = sl_getString(0);
int *p2 = getCaliVariable();
int *var = getCaliVariable();
*var = 1;
DEBUG_COMMAND_YET("Confirm.CheckProtectFile %s,%p,%p:", p1,p2,var);
}
static void CreateKeyFile() {
const char *p1 = sl_getString(0);
int *p2 = getCaliVariable();
int *var = getCaliVariable();
*var = 1;
DEBUG_COMMAND_YET("Confirm.CreateKeyFile %s,%p,%p:", p1,p2,var);
}
static const ModuleFunc functions[] = {
{"CheckProtectFile", CheckProtectFile},
{"CreateKeyFile", CreateKeyFile},
{"ExistKeyFile", ExistKeyFile},
{"Init", Init},
};
const Module module_Confirm = {"Confirm", functions, sizeof(functions) / sizeof(ModuleFunc)};