mirror of
https://github.com/EQEmu/Server.git
synced 2025-12-11 21:01:29 +00:00
[Bug Fix] Prevent NPE when creating DZ using ad-hoc version IDs (#4141)
* initial commit * corrected based on hgtw feedback
This commit is contained in:
parent
74f1eac401
commit
e6a3d5e1c5
@ -2290,8 +2290,8 @@ void ClientTaskState::CreateTaskDynamicZone(Client* client, int task_id, Dynamic
|
||||
}
|
||||
|
||||
// dz should be named the version-based zone name (used in choose zone window and dz window on live)
|
||||
auto zone_info = zone_store.GetZone(dz_request.GetZoneID(), dz_request.GetZoneVersion());
|
||||
dz_request.SetName(zone_info->long_name.empty() ? task->title : zone_info->long_name);
|
||||
auto zone_info = zone_store.GetZoneWithFallback(dz_request.GetZoneID(), dz_request.GetZoneVersion());
|
||||
dz_request.SetName(zone_info && !zone_info->long_name.empty() ? zone_info->long_name : task->title);
|
||||
dz_request.SetMinPlayers(task->min_players);
|
||||
dz_request.SetMaxPlayers(task->max_players);
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user