diff options
Diffstat (limited to 'src/map')
-rw-r--r-- | src/map/clif.cpp | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/map/clif.cpp b/src/map/clif.cpp index 184bb9d..2208291 100644 --- a/src/map/clif.cpp +++ b/src/map/clif.cpp @@ -1085,7 +1085,7 @@ int clif_spawnmob(dumb_ptr<mob_data> md) } // custom mob names - if (md->name != MobName() && md->name != get_mob_db(md->mob_class).name) + if (md->name != MobName() && md->name != get_mob_db(md->mob_class).name && md->name.size() >= 4) { Packet_Fixed<0x0095> fixed_95; fixed_95.block_id = md->bl_id; @@ -2640,7 +2640,7 @@ void clif_getareachar_mob(dumb_ptr<map_session_data> sd, dumb_ptr<mob_data> md) } // custom mob names - if (md->name != MobName() && md->name != get_mob_db(md->mob_class).name) + if (md->name != MobName() && md->name != get_mob_db(md->mob_class).name && md->name.size() >= 4) { Packet_Fixed<0x0095> fixed_95; fixed_95.block_id = md->bl_id; @@ -3835,10 +3835,12 @@ RecvResult clif_parse_GetCharNameRequest(Session *s, dumb_ptr<map_session_data> case BL::MOB: { dumb_ptr<mob_data> md = bl->is_mob(); - nullpo_retr(rv, md); - fixed_95.char_name = stringish<CharName>(md->name); + if (md->name != MobName() && md->name != get_mob_db(md->mob_class).name && md->name.size() >= 4) + fixed_95.char_name = stringish<CharName>(md->name); + else + fixed_95.char_name = stringish<CharName>(get_mob_db(md->mob_class).name); send_fpacket<0x0095, 30>(s, fixed_95); } break; |