1
This commit is contained in:
parent
b79c4c972a
commit
9912e197b7
@ -2301,6 +2301,9 @@ void Creature::UpdateMove()
|
||||
if (GetMovement()->UpdatePosition()) {
|
||||
} else {
|
||||
if (!GetMovement()->IsFindPath()) {
|
||||
if (room->GetGasData().GetGasMode() == GasInactive &&
|
||||
room->IsSandTableRoom()) {
|
||||
} else {
|
||||
GetMovement()->CalcTargetPos(mt::Param::s().move_step_len);
|
||||
if (!GetMovement()->UpdatePosition()) {
|
||||
if (IsPlayer()) {
|
||||
@ -2316,6 +2319,7 @@ void Creature::UpdateMove()
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
room->grid_service->MoveCreature(this);
|
||||
if (room->IsPveRoom() && IsEntityType(ET_Hero) && IsNearGas()) {
|
||||
GetMutablePos() = old_pos;
|
||||
@ -2961,6 +2965,10 @@ float Creature::GetSpeed()
|
||||
}
|
||||
|
||||
*/
|
||||
if (room->GetGasData().GetGasMode() == GasInactive &&
|
||||
room->IsSandTableRoom()) {
|
||||
return mt::Param::s().sand_table_move_speed / SERVER_FRAME_RATE;
|
||||
}
|
||||
if (HasBuffEffect(kBET_Jump)) {
|
||||
finaly_speed = GetHeroMeta()->jump_speed();
|
||||
} else if (HasBuffEffect(kBET_Down)) {
|
||||
|
@ -37,6 +37,7 @@ namespace mt
|
||||
s_.match_choose_time = GetIntParam("match_choose_time", 0);
|
||||
s_.match_lock_time = GetIntParam("match_lock_time", 0);
|
||||
s_.pickup_weapon_replace_type = GetIntParam("pickup_weapon_replace_type", 0);
|
||||
s_.sand_table_move_speed = GetIntParam("sand_table_move_speed", 500);
|
||||
#if 1
|
||||
s_.match_lock_time++;
|
||||
#endif
|
||||
|
@ -99,6 +99,8 @@ namespace mt
|
||||
int box_open_delay = 0;
|
||||
|
||||
int compose_mode = 1;
|
||||
float sand_table_move_speed = 500;
|
||||
|
||||
};
|
||||
static void StaticPostInit();
|
||||
static const S& s() { return s_; };
|
||||
|
@ -172,6 +172,9 @@ void Player::InternalUpdate(int delta_time)
|
||||
if (!GlmHelper::IsEqual2D(*sand_table_target_pos, GetPos().ToGlmVec3())) {
|
||||
moving = true;
|
||||
moved_frames = 0;
|
||||
} else {
|
||||
moving = false;
|
||||
GetMovement()->ClearPath();
|
||||
}
|
||||
} else {
|
||||
moving = false;
|
||||
|
Loading…
x
Reference in New Issue
Block a user