1
This commit is contained in:
parent
2d57d32108
commit
6ec4ffc438
@ -1530,31 +1530,6 @@ void Creature::SummonObstacle(Buff* buff, int id, const Position& target_pos)
|
||||
float *p_rotate = nullptr;
|
||||
float rotate = 0.0f;
|
||||
Position pos = target_pos;
|
||||
if (buff->skill_meta) {
|
||||
switch (buff->skill_meta->GetMagicId()) {
|
||||
case MAGIC_20601_DJS:
|
||||
{
|
||||
if (!GlmHelper::IsZero(GetAttackDir())) {
|
||||
// 999
|
||||
#if 1
|
||||
pos.AddGlmVec3(GetAttackDir() * 100.0f);
|
||||
#else
|
||||
pos = target_pos + GetAttackDir() * 100;
|
||||
#endif
|
||||
rotate = GlmHelper::CalcAngle(GetAttackDir(), GlmHelper::UP);
|
||||
if (GetAttackDir().x < 0.00001f) {
|
||||
rotate = -rotate;
|
||||
}
|
||||
p_rotate = &rotate;
|
||||
}
|
||||
}
|
||||
break;
|
||||
default:
|
||||
{
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
RoomObstacle* obstacle = room->CreateObstacle(id, pos.GetX(), pos.GetY(), pos.GetZ());
|
||||
if (obstacle) {
|
||||
obstacle->buff_meta = buff->meta;
|
||||
|
Loading…
x
Reference in New Issue
Block a user