Fixed Hocus and Improvised Song ignoring mapflags (#4488)
* Fixed skills casted by SA_ABRACADABRA and WM_RANDOMIZESPELL ignoring critical mapflags
This commit is contained in:
@@ -791,7 +791,7 @@ bool skill_isNotOk(uint16 skill_id, struct map_session_data *sd)
|
|||||||
|
|
||||||
struct map_data *mapdata = map_getmapdata(sd->bl.m);
|
struct map_data *mapdata = map_getmapdata(sd->bl.m);
|
||||||
|
|
||||||
if (mapdata->flag[MF_NOSKILL] && skill_id != ALL_EQSWITCH)
|
if (mapdata->flag[MF_NOSKILL] && skill_id != ALL_EQSWITCH && !sd->skillitem) //Item skills bypass noskill
|
||||||
return true;
|
return true;
|
||||||
|
|
||||||
// Epoque:
|
// Epoque:
|
||||||
@@ -810,10 +810,10 @@ bool skill_isNotOk(uint16 skill_id, struct map_session_data *sd)
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* It has been confirmed on a official server (thanks to Yommy) that item-cast skills bypass all the restrictions above
|
* It has been confirmed on a official server (thanks to Yommy) that item-cast skills bypass all mapflag restrictions
|
||||||
* Also, without this check, an exploit where an item casting + healing (or any other kind buff) isn't deleted after used on a restricted map
|
* Also, without this check, an exploit where an item casting + healing (or any other kind buff) isn't deleted after used on a restricted map
|
||||||
*/
|
*/
|
||||||
if( sd->skillitem == skill_id && !sd->skillitem_keep_requirement )
|
if( sd->skillitem == skill_id && !sd->skillitem_keep_requirement && !sd->state.abra_flag)
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
uint32 skill_nocast = skill_get_nocast(skill_id);
|
uint32 skill_nocast = skill_get_nocast(skill_id);
|
||||||
|
|||||||
Reference in New Issue
Block a user