added -P for should_do_judge_according_time()

This commit is contained in:
2025-09-20 23:11:50 +08:00
parent 09b2c9441b
commit 0f97f588ab
5 changed files with 195 additions and 3 deletions
+24
View File
@@ -1,6 +1,30 @@
#ifndef __MY_VERTIX_H__
#define __MY_VERTIX_H__
typedef struct {
int from;
int to;
} time_period_t;
typedef struct {
// 如果in为0,则表示需要再这段时间,否则,表示在这段时间之外
bool in;
int size;
time_period_t *periods;
} time_gap_t;
extern time_gap_t global_time_gap;
int should_do_judge_according_time();
// 获取今天的秒数
int get_today_seconds();
// 将16:05:00类似的字符串,转换成一天的秒数
int get_all_time_period_from_arguments(const char *str);
typedef struct
{
float x;