3.喷火枪子弹,用完后仍会有喷火特效显示

This commit is contained in:
aozhiwei 2021-06-23 07:41:00 +00:00
parent 47620300f4
commit 7f15d2d2e8

View File

@ -1699,6 +1699,13 @@ void Player::UpdateAiming()
void Player::CheckShotHoldState(Weapon* weapon)
{
if (weapon->meta->buff_meta && weapon->meta->buff_meta->i->trigger_type() == kBTT_SeriesShot) {
if (GetCurrWeapon()->weapon_idx != 0 &&
GetCurrWeapon()->ammo <= 0) {
if (shot_hold_timer) {
room->xtimer.DeleteTimer(shot_hold_timer);
}
return;
}
if (shot_hold_timer) {
if (weapon->meta->buff_meta->i->buff_id() !=
room->xtimer.MutableParams(shot_hold_timer)->param1.GetInt()) {