63 lines
1.2 KiB
Go
63 lines
1.2 KiB
Go
package logic
|
||
|
||
import (
|
||
"go_dreamfactory/lego/core"
|
||
)
|
||
|
||
//战斗类型枚举
|
||
type FightType uint8
|
||
|
||
const (
|
||
PVE FightType = 1
|
||
PVP FightType = 2
|
||
PVBOSS FightType = 3
|
||
)
|
||
|
||
/// <summary>
|
||
/// 技能类型枚举
|
||
///
|
||
///主动技 = 玩家可以点击、会出现在UI里
|
||
///被动技 = 玩家不可以点击,会出现在UI里
|
||
///队长技 = 玩家不可以点击,不会出现在UI里
|
||
///其他系统提供的被动技 = 玩家不可以点击,不会出现在UI里
|
||
/// </summary>
|
||
type SkillType uint8
|
||
|
||
const (
|
||
ZhuDong SkillType = 1
|
||
BeiDong SkillType = 2
|
||
DuiZhang SkillType = 3
|
||
)
|
||
|
||
//事件类型枚举
|
||
const (
|
||
OnFightStart core.Event_Key = "OnFightStart"
|
||
OnRoleStartAction core.Event_Key = "OnRoleStartAction"
|
||
OnRoleStopAction core.Event_Key = "OnRoleStopAction"
|
||
)
|
||
|
||
//
|
||
type ComType uint8
|
||
|
||
const (
|
||
ModifyHp ComType = iota // 修改血量
|
||
EmitSkill // 施放技能
|
||
AddBuff // 增加一个buff
|
||
ModifyBuff // 修改一个buff数据
|
||
)
|
||
|
||
type ComModifyOperate struct {
|
||
from byte
|
||
nv float64
|
||
}
|
||
|
||
func (this *ComModifyOperate) Recycle() {
|
||
this.from = 0
|
||
this.nv = 0
|
||
}
|
||
|
||
func (this *ComModifyOperate) ToString() string {
|
||
var str = "{this.GetType()} rid={from},nv:{nv}"
|
||
return str
|
||
}
|