源战役
Vous ne pouvez pas sélectionner plus de 25 sujets Les noms de sujets doivent commencer par une lettre ou un nombre, peuvent contenir des tirets ('-') et peuvent comporter jusqu'à 35 caractères.

51 lignes
1.7 KiB

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