Jump to content
  • 0

modify @monsterignore


mleo1

Question


  • Group:  Members
  • Topic Count:  22
  • Topics Per Day:  0.00
  • Content Count:  123
  • Reputation:   4
  • Joined:  11/21/11
  • Last Seen:  

how do you modify @monsterignore to do this

if gm level is 70

you cannot be attacked by players but can be attacked by monsters

if gm level is 99

you can't be attacked by players and monsters

teach me please, sorry for bad english.

Link to comment
Share on other sites

4 answers to this question

Recommended Posts


  • Group:  Members
  • Topic Count:  69
  • Topics Per Day:  0.02
  • Content Count:  295
  • Reputation:   6
  • Joined:  10/14/12
  • Last Seen:  

@pk is the best solution for that. Try to find cydh's guide on source.

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  22
  • Topics Per Day:  0.00
  • Content Count:  123
  • Reputation:   4
  • Joined:  11/21/11
  • Last Seen:  

thanks for the reference

I just modified battle.c

if( sd->state.monster_ignore && flag&BCT_ENEMY )

to

if( sd->state.monster_ignore && flag&BCT_ENEMY )
 if( (pc_get_group_level(sd)!=99 && (map[m].flag.gvg_castle || map[m].flag.pvp)) || pc_get_group_level(sd)==99 )

this works for now, but still I like the answer to the first one

questions xD

1 how do you check if target is player xD?

2 how do you check if map=="prontera" for example?

Link to comment
Share on other sites


  • Group:  Developer
  • Topic Count:  153
  • Topics Per Day:  0.04
  • Content Count:  2285
  • Reputation:   745
  • Joined:  06/16/12
  • Last Seen:  

1 how do you check if target is player xD?

target->type == BL_PC

2 how do you check if map=="prontera" for example?

map[sd->bl.m].name == "prontera"

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  22
  • Topics Per Day:  0.00
  • Content Count:  123
  • Reputation:   4
  • Joined:  11/21/11
  • Last Seen:  

thanks xD. already used

if( sd->state.monster_ignore && flag&BCT_ENEMY )
	  if( (pc_get_group_level(sd)!=99 && s_bl->type==BL_PC) || pc_get_group_level(sd)==99 )

Link to comment
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.   Paste as plain text instead

  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.

×
×
  • Create New...