源战役
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

51 rivejä
1.7 KiB

%%% -------------------------------------------------------
%%% @author huangyongxing@yeah.net
%%% @doc
%%% 运动行为(运动能量相关行为)数据定义
%%% @end
%%% -------------------------------------------------------
-ifndef(MOTION_HRL).
-define(MOTION_HRL, ok).
%% 运动能量总量上限
-define(MOTION_ENERGY_MAX, 30).
%% 运动能量每恢复1点需要的时间(毫秒)
-define(MOTION_ENERGY_RECOVER_TIME, 200).
%% 闪现无敌时间(策划暂时不要无敌了,暂时保留功能设计,时间设为-1)
-define(MOTION_FLASH_NO_INJURY, -1).
%% 运动能量消耗值
-define(MOTION_ENERGY_JUMP_COST, 10).
-define(MOTION_ENERGY_FLASH_COST, 10).
%% 以下为进程字典相关信息的KEY值,特定的移动类型才记录
%% 移动时间记录
-define(MOTION_TIME(MotionType), {move_time, MotionType}).
%% 移动相关各项资料
-define(MOTION_INFO(MotionType), {move_info, MotionType}).
%% 移动错误编号
%% 用于告知客户端错误原因
-define(MOTION_ERR_OK, 0). % 非错误[实际上不通知]
-define(MOTION_ERR_SCENE, 1). % 错误目标场景
-define(MOTION_ERR_CD, 2). % CD时间
-define(MOTION_ERR_DIS, 3). % 距离超限
%% player_status 运动能量数据结构
-record(role_motion, {
energy = 0 % 上次触发变化或计算结果能量值
,time = 0 % 上次触发变化或计算结果的时间(毫秒)
}).
%% ets_scene_user 运动能量数据结构
-record(scene_motion, {
energy = 0 % 上次触发变化或计算结果能量值
,time = 0 % 上次触发变化或计算结果的时间(毫秒)
,no_injury_time = 0 % 免受伤害效果结束时间(毫秒)
}).
-endif.