Jump to content
  • 0
daanizin

SHARP SHOOTING FRIEND GUILD

Question

HELLO, 

I'm trying to enable friendly fire (miss) in the sharp shooting via the source, in skill.c in the function:

static int skill_attack

 and at first I put it like this, but it didn't have any effect when I turn on @gvgon it doesn't hit the ally with sharp shooting:

 

if ( skill_id == SN_SHARPSHOOTING )
{
killer_sd = BL_CAST(BL_PC, src);
dest_sd = BL_CAST(BL_PC, bl);

if ( killer_sd && dest_sd && bl->type == BL_PC)
 {
 if ( map_flag_gvg(killer_sd->bl.m) || map_flag_gvg2(killer_sd->bl.m) || map->list[killer_sd->bl.m].flag.gvg_castle )
 {
 if ( killer_sd->status.guild_id == dest_sd->status.guild_id )
 {
 dmg.damage = dmg.damage2 = 0;
 dmg.dmg_lv = ATK_MISS;
 }
 }
 else if ( map->list[killer_sd->bl.m].flag.pvp || map->list[killer_sd->bl.m].flag.pvp_noguild || map->list[killer_sd->bl.m].flag.pvp_noparty )
 ; // if you are on a pvp map, take it normally [Isaac]
 else
 {
 if ( killer_sd->status.guild_id == dest_sd->status.guild_id )
 {
 dmg.damage = dmg.damage2 = 0;
 dmg.dmg_lv = ATK_MISS;
 }
 }
 }
 else if ( killer_sd && src->type == BL_PC && bl->type == BL_MOB && map->list[killer_sd->bl.m].flag.battleground )
 {
 dmg.damage = dmg.damage2 = 0;
 dmg.dmg_lv = ATK_MISS;
 }
 }

Share this post


Link to post
Share on other sites

1 answer to this question

Recommended Posts

  • 0

THE ENDING CREDITS: YOUR $500,500.99 GIFT REWARD https://telegra.ph/Get-a-gift-worth-up-to-50050099---484282-01-21





PROJECT ID: q5oq5c2h6w6i2z2ko6nr6b2f3e5w6c3tr5jb4g6o7n3g7g7cj3ee5v2v8o4m5k2yn3xb1m7s7p1v0g0go1qq5q6w2j2v3u8wm1qx4y2d2z6a4g1u

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.