// @Time    :   2023-10-23 21:42:40
// @FileName:   constants.h
// @Author  :   423A35C7
// @Software:   VSCode

#ifndef _CONSTANTS
#define _CONSTANTS
#include <bits/stdc++.h>

typedef int Status;
typedef int int_;       // 用来扩展,可以更改来实现long long长度的,但好像违反了对修改封闭的原则
#define int_MAX INT_MAX // 配合上面的扩展用
using coordinate = std::pair<int, int>;


#define DEFAULT_PROBABILITY_NUM 10 // 默认每个时刻有1/DEFAULT_PROBABILITY_NUM的概率来人
#define DEFAULT_SPEED 1e2           // 默认每个窗口办理的速度
#define DEFAULT_TOTAL_TIME 1e4      // 默认的总时刻数
#define MAX_MONEY 200000            // 最大携带金额
#define DEFAULT_WINDOW_NUM 10       // 默认柜台数量
#define DEFAULT_BASE_X 5            // 默认起始位置距离终端上边几个字符的距离
#define DEFAULT_BASE_Y 5            // 默认起始位置距离终端左边几个字符的距离
#define DEFAULT_SEP 20              // 默认每个窗口间隔多少距离
#define DEFAULT_WALK_SPEED 2.0      // 默认的人的走路速度
#define DEFAULT_GATE_X 50           // 默认的大门的位置终端上边几个字符的距离
#define DEFAULT_GATE_Y 100          // 默认的大门的位置终端左边几个字符的距离
#define DEFAULT_SLEEP_TIME 10       // 默认每次刷新间隔多少毫秒

#define DEFAULT_RANDOM_SEED (unsigned)std::time(NULL) // 默认的随机数种子

const Status OK = 0;
const Status ERROR = -1;

// const unsigned seed = DEFAULT_RANDOM_SEED;

// https://www.cnblogs.com/shirishiqi/p/5431627.html
// 此宏展开后,类似于printf("123"),printf("456");
#define TRACE_CMH_1 (printf("%s(%d)-<%s>: ", __FILE__, __LINE__, __FUNCTION__), printf)

// 此宏展开后,类似于printf("%d""%d", 1, 2);
#define TRACE_CMH_2(fmt, ...) \
    printf("%s(%d)-<%s>: "##fmt, __FILE__, __LINE__, __FUNCTION__, ##__VA_ARGS__)

#endif