diff --git a/server/gameserver/car.cc b/server/gameserver/car.cc index 9cc9f108..ead28f77 100644 --- a/server/gameserver/car.cc +++ b/server/gameserver/car.cc @@ -57,8 +57,8 @@ void Car::Initialize() ( App::Instance()->AllocTempHeroUniId(), hero_meta_, - App::Instance()->AllocTempWeaponUniId(), - GetCurrWeapon()->meta, + GetCurrWeapon() ? App::Instance()->AllocTempWeaponUniId() : 0, + GetCurrWeapon() ? GetCurrWeapon()->meta : 0, 0, nullptr );