Index: src/map/skill.c
===================================================================
--- src/map/skill.c (revision 17319)
+++ src/map/skill.c (working copy)
@@ -10396,15 +10396,7 @@
break;
case LG_OVERBRAND:
- {
- int width;//according to data from irowiki it actually is a square
- for( width = 0; width < 7; width++ )
- for( i = 0; i < 7; i++ )
- map_foreachincell(skill_area_sub, src->m, x-2+i, y-2+width, splash_target(src), src, LG_OVERBRAND_BRANDISH, skill_lv, tick, flag|BCT_ENEMY,skill_castend_damage_id);
- for( width = 0; width < 7; width++ )
- for( i = 0; i < 7; i++ )
- map_foreachincell(skill_area_sub, src->m, x-2+i, y-2+width, splash_target(src), src, skill_id, skill_lv, tick, flag|BCT_ENEMY,skill_castend_damage_id);
- }
+ skill_overbrand(src, skill_id, skill_lv, x, y, tick, flag);
break;
case LG_BANDING:
@@ -14284,6 +14276,45 @@
/*=========================================
*
*-----------------------------------------*/
+void skill_overbrand(struct block_list* src, uint16 skill_id, uint16 skill_lv, uint16 x, uint16 y, unsigned int tick, int flag)
+{
+ struct s_skill_unit_layout *layout;
+ int i, ux[53], uy[53];
+ layout = skill_get_unit_layout(skill_id,skill_lv,src,x,y);
+ short dir = map_calc_dir(src,x,y);
+ if(dir > 0 && dir < 4) {
+ for(i = 0; i < 53; i++) {
+ ux[i] = layout->dy[i];
+ uy[i] = layout->dx[i] * -1;
+ }
+ } else if(dir == 4) {
+ for(i = 0; i < 53; i++) {
+ ux[i] = layout->dx[i];
+ uy[i] = layout->dy[i];
+ }
+ } else if(dir > 4) {
+ for(i = 0; i < 53; i++) {
+ ux[i] = layout->dy[i] * -1;
+ uy[i] = layout->dx[i];
+ }
+ } else {
+ for(i = 0; i < 53; i++) {
+ ux[i] = layout->dx[i];
+ uy[i] = layout->dy[i] * -1;
+ }
+ }
+ for( i = 0; i < 53; i++ ) {
+ if(i < 12) { //Close range hits twice
+ map_foreachincell(skill_area_sub, src->m, x+ux[i], y+uy[i], splash_target(src), src, LG_OVERBRAND_BRANDISH, skill_lv, tick, flag|BCT_ENEMY,skill_castend_damage_id);
+ map_foreachincell(skill_area_sub, src->m, x+ux[i], y+uy[i], splash_target(src), src, skill_id, skill_lv, tick, flag|BCT_ENEMY,skill_castend_damage_id);
+ } else if(i > 11 && i < 45) //Far sides do knockback damage
+ map_foreachincell(skill_area_sub, src->m, x+ux[i], y+uy[i], splash_target(src), src, skill_id, skill_lv, tick, flag|BCT_ENEMY,skill_castend_damage_id);
+ else //Far middle does piercing damage
+ map_foreachincell(skill_area_sub, src->m, x+ux[i], y+uy[i], splash_target(src), src, LG_OVERBRAND_BRANDISH, skill_lv, tick, flag|BCT_ENEMY,skill_castend_damage_id);
+ }
+
+}
+
struct square {
int val1[5];
int val2[5];
@@ -17530,6 +17561,18 @@
memcpy(skill_unit_layout[pos].dy,dy,sizeof(dy));
}
break;
+ case LG_OVERBRAND: {
+ static const int dx[] = {-1,-1,-1,-1, 0, 0, 0, 0, 1, 1, 1, 1,
+ -5,-5,-5,-5,-4,-4,-4,-4,-3,-3,-3,-3,-2,-2,-2,-2, 2, 2, 2, 2, 3, 3, 3, 3, 4, 4, 4, 4, 5, 5, 5, 5,
+ -1,-1,-1, 0, 0, 0, 1, 1, 1};
+ static const int dy[] = { 0,-1,-2,-3, 0,-1,-2,-3, 0,-1,-2,-3,
+ 0,-1,-2,-3, 0,-1,-2,-3, 0,-1,-2,-3, 0,-1,-2,-3, 0,-1,-2,-3, 0,-1,-2,-3, 0,-1,-2,-3, 0,-1,-2,-3,
+ -4,-5,-6,-4,-5,-6,-4,-5,-6};
+ skill_unit_layout[pos].count = 53;
+ memcpy(skill_unit_layout[pos].dx,dx,sizeof(dx));
+ memcpy(skill_unit_layout[pos].dy,dy,sizeof(dy));
+ }
+ break;
default:
ShowError("unknown unit layout at skill %d\n",i);
break;
Index: src/map/skill.h
===================================================================
--- src/map/skill.h (revision 17319)
+++ src/map/skill.h (working copy)
@@ -333,6 +333,7 @@
int skill_sit (struct map_session_data *sd, int type);
void skill_brandishspear(struct block_list* src, struct block_list* bl, uint16 skill_id, uint16 skill_lv, unsigned int tick, int flag);
+void skill_overbrand(struct block_list* src, uint16 skill_id, uint16 skill_lv, uint16 x, uint16 y, unsigned int tick, int flag);
void skill_repairweapon(struct map_session_data *sd, int idx);
void skill_identify(struct map_session_data *sd,int idx);
void skill_weaponrefine(struct map_session_data *sd,int idx); // [Celest]
Index: db/re/skill_db.txt
===================================================================
--- db/re/skill_db.txt (revision 17319)
+++ db/re/skill_db.txt (working copy)
@@ -889,7 +889,7 @@
2314,1,6,1,-1,0,0,1,1,no,0,0,0,weapon,0, LG_RAGEBURST,Rage Burst
2315,0,6,4,0,0x2,3,3,1,yes,0,0,0,none,2, LG_SHIELDSPELL,Shield Spell
2316,0,6,4,0,0x1,0,5,1,yes,0,0,0,none,0, LG_EXEEDBREAK,Exceed Break
-2317,1,6,2,-1,0x2,5,5,1,yes,0,0,0,none,3:4:5:6:7, LG_OVERBRAND,Over Brand //CHECK I know the splash is needed somehow for the strange AoE it gives.
+2317,0,6,2,-1,0x2,0,5,1,yes,0,0,0,none,3:4:5:6:7, LG_OVERBRAND,Over Brand //CHECK I know the splash is needed somehow for the strange AoE it gives.
2318,0,6,4,0,0x1,0,5,1,yes,0,0,0,none,0, LG_PRESTIGE,Prestige
2319,0,6,4,0,0x1,3,5,1,no,0,0,0,weapon,0, LG_BANDING,Banding //CHECK Splash isnt needed right? Banding has its own UNIT ID.
2320,0,6,4,-1,0x2,3,5,1,yes,0,0,0,weapon,0, LG_MOONSLASHER,Moon Slasher
Index: db/re/skill_unit_db.txt
===================================================================
--- db/re/skill_unit_db.txt (revision 17319)
+++ db/re/skill_unit_db.txt (working copy)
@@ -127,6 +127,7 @@
2303,0xd0, , 3, 0, -1,all, 0x2018 //SC_BLOODYLUST
2304,0xd1, , 0, 2, -1,enemy, 0x000 //SC_FEINTBOMB
+2317,0xec, , -1, 0, -1,enemy, 0x000 //LG_OVERBRAND
2319,0xec, , 0, 3,5000,all, 0x000 //LG_BANDING
2414,0xda, , 0, 0,1000,enemy, 0x008 //WM_REVERBERATION