Whathell Posted May 21, 2022 Posted May 21, 2022 Hi! Is there a way to change the rare drop announce to map only instead of global? I tried changing into this one in pc.cpp but it does not work. clif_broadcast(&sd->bl, message, strlen(message) + 1, BC_DEFAULT, ALL_SAMEMAP); Quote
0 Pride Posted May 22, 2022 Posted May 22, 2022 goto src -> map -> mob.cpp Find //A Rare Drop Global Announce by Lupus paste the below codes //A Rare Drop Global Announce by Lupus if( mvp_sd && drop_rate <= battle_config.rare_drop_announce ) { char message[128]; sprintf (message, msg_txt(NULL,541), mvp_sd->status.name, md->name, it->ename.c_str(), (float)drop_rate/100); //MSG: "'%s' won %s's %s (chance: %0.02f%%)" clif_broadcast(&sd->bl, message, strlen(message) + 1, BC_DEFAULT, ALL_SAMEMAP); } the one your showing is pc.cpp item drop by steal skill. Quote
0 Pride Posted May 22, 2022 Posted May 22, 2022 (edited) i think this will make ur server to crash if @killmonster command is used so be careful since clif_broadcast needs to have player attached ok small update on the codes to prevent mapcrash //A Rare Drop Global Announce by Lupus if( mvp_sd && drop_rate <= battle_config.rare_drop_announce ) { char message[128]; sprintf (message, msg_txt(NULL,541), mvp_sd->status.name, md->name, it->ename.c_str(), (float)drop_rate/100); //MSG: "'%s' won %s's %s (chance: %0.02f%%)" if(&sd->bl == NULL) continue; clif_broadcast(&sd->bl, message, strlen(message) + 1, BC_DEFAULT, ALL_SAMEMAP); } Edited May 22, 2022 by Pride Quote
Question
Whathell
Hi! Is there a way to change the rare drop announce to map only instead of global?
I tried changing into this one in pc.cpp but it does not work.
clif_broadcast(&sd->bl, message, strlen(message) + 1, BC_DEFAULT, ALL_SAMEMAP);
2 answers to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.