From 5bbdbbf21bced643bb9512317337b89d59ba0337 Mon Sep 17 00:00:00 2001 From: aozhiwei Date: Thu, 30 Mar 2023 12:10:38 +0800 Subject: [PATCH] 1 --- server/gameserver/creature.cc | 20 ++++++++------------ 1 file changed, 8 insertions(+), 12 deletions(-) diff --git a/server/gameserver/creature.cc b/server/gameserver/creature.cc index fcbd1412..0fa89b06 100644 --- a/server/gameserver/creature.cc +++ b/server/gameserver/creature.cc @@ -1668,20 +1668,16 @@ Hero* Creature::SummonHero(Buff* buff, const glm::vec3& dir ) { - #if 0 - const mt::Hero* hero_meta = mt::Hero::GetById(buff->meta->_int_buff_param1); + Hero* hero = nullptr; + const mt::Hero* hero_meta = mt::Hero::GetById(buff->meta->_int_buff_param2); if (hero_meta) { - int life_time = 10000; - bool through_wall = false; - InternalSummonHero(buff, - hero_meta, - GetAttackDir(), - pos, - through_wall, - 1, - life_time); + hero = InternalSummonHero(buff, + hero_meta, + GetAttackDir(), + pos + ); } - #endif + return hero; } bool Creature::FreezeOperate()