|
|
--女神
|
|
GoddessVo = GoddessVo or BaseClass(BaseVo)
|
|
local GoddessVo = GoddessVo
|
|
function GoddessVo:__init()
|
|
end
|
|
|
|
function GoddessVo:__defineVar()
|
|
return {
|
|
_class_type = self,
|
|
_iid = _in_obj_ins_id,
|
|
_use_delete_method = false,
|
|
vo_type = SceneBaseType.Artifact,
|
|
pos_x = 0, --X像素坐标(int16)
|
|
pos_y = 0, --Y像素坐标(int16)
|
|
hp = 100, --当前hp(int32)
|
|
maxHp = 100, --最大hp(int32)
|
|
name = "", --名字(string)
|
|
move_speed = 160, --速度(int16)
|
|
ghost_mode = 0,
|
|
hide_flag = 0 , --是否不可见(int8)
|
|
warGroup = 0, --战斗分组(int8)
|
|
goddess_id = 0, --精灵ID(int32)
|
|
model_id = 0, --模型id
|
|
texture_res = 0, --贴图
|
|
poseState = PoseState.STAND,
|
|
birth_angle = 270, --出生角度 水平向右为0 逆时针一圈为360度
|
|
owner_id = 0, --所属玩家id
|
|
owner_vo = nil, --所属玩家
|
|
}
|
|
end
|
|
|
|
function GoddessVo:SetVo(owner_vo)
|
|
self.owner_vo = owner_vo
|
|
self.owner_id = owner_vo.id
|
|
self.goddess_id = owner_vo.escort_state
|
|
if self.owner_vo then
|
|
self.name = owner_vo.name .. "的女神"
|
|
end
|
|
end
|
|
|
|
--取模型id
|
|
function GoddessVo:GetGoddessClotheId()
|
|
local cfg = nil --Config.Artifactconfig[self.goddess_id]
|
|
cfg = Config.ConfigGoddess[(self.goddess_id%100)]
|
|
if cfg then
|
|
return cfg.model_id
|
|
end
|
|
return 0
|
|
end
|
|
|
|
function GoddessVo:GetTextureId()
|
|
if tonumber(self.texture_res) ~= 0 then
|
|
return self:GetGoddessClotheId() .. "_" .. self.texture_res
|
|
end
|
|
end
|
|
|
|
function GoddessVo:__delete()
|
|
end
|
|
|
|
function GoddessVo:SetGoddessId(goddess_id)
|
|
self.goddess_id = goddess_id
|
|
end
|