📄 px_ls_trap.h
字号:
#pragma once
/* must been first include begin */
#include "..\ProjectX_Common\ProjectX_Copyright.h"
#include "..\ProjectX_Common\ProjectX_Common.h"
/* must been first include end */
/* std and common include */
#include <windows.h>
#include <stdio.h>
#include <stdlib.h>
//以下为定义陷阱结构信息
/* 以下定义陷阱类型 */
#define TYPE_TRAP_NO 0 /* 没有陷阱 */
#define TYPE_TRAP_PHYSIC_ATTACK 1 /* 物理系攻击陷阱 */
#define TYPE_TRAP_COLD_ATTACK 2 /* 冰系攻击陷阱 */
#define TYPE_TRAP_FIRE_ATTACK 3 /* 火系攻击陷阱 */
#define TYPE_TRAP_POISON_ATTACK 4 /* 毒系攻击陷阱 */
#define TYPE_TRAP_LIGHTING_ATTACK 5 /* 电系攻击陷阱 */
#define TYPE_TRAP_RESTORE_HP 6 /* 恢复hp */
#define TYPE_TRAP_RESTORE_MANA 7 /* 恢复mana */
#define TYPE_TRAP_RESTORE_SP 8 /* 恢复sp */
#define TYPE_TRAP_DECREASS_DEFENCE 9 /* 减少防御 */
#define TYPE_TRAP_DECREASS_PR 10 /* 减少物理抵抗 */
#define TYPE_TRAP_DECREASS_CR 11 /* 减少冰系抵抗 */
#define TYPE_TRAP_DECREASE_FR 12 /* 减少火系抵抗 */
#define TYPE_TRAP_DECREASE_LR 13 /* 减少电系抵抗 */
#define TYPE_TRAP_DECREASE_POR 14 /* 减少毒系抵抗 */
typedef struct tagTrap_Base {
int index;
byte trap_type;
byte distance;
byte delay_frame;
int damage;
byte damage_base;
}TRAP_BASE, * LPTRAP_BASE;
typedef struct tagTrap_Refresh {
int baseid;
int mapid;
byte mapx;
byte mapy;
}TRAP_REFRESH, * LPTRAP_REFRESH;
typedef struct tagTrap {
int sessionid;
int mapid;
int damage; /* 伤害或者增益数 */
byte mapx;
byte mapy;
byte state;
byte type; /* 陷阱类型 */
byte distance; /* 影响半径 */
byte persist_frame; /* 持续多少帧 */
byte attack_frame_need;
int last_attack_frame;
byte base; /* 此伤害或者增益附加需要数,如当为火系伤害时,为此陷阱的火系抵抗 */
}TRAP, * LPTRAP;
typedef struct tagTrap_Key {
byte state;
TRAP * ptrap;
}TRAP_KEY, * LPTRAP_KEY;
void handle_all_trap_ai(void);
void refresh_trap(void);
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -