Jump to content

Make ranged monsters act like melee monsters


Go to solution Solved by WolfasLycan,

Recommended Posts

Hi, I want to make all the ranged monsters(archers and magicians) attack like melee, this is, instead of attacking from distance attacking close to the char.

My first thought was to go in mob_proto.txt and change battle_type range to melee, however it didn´t make any difference, the archers and magicians keep attacking from distance. How i can implement that behaviour?

Link to comment
https://metin2.dev/topic/33750-make-ranged-monsters-act-like-melee-monsters/
Share on other sites

  • Replies 3
  • Created
  • Last Reply

Top Posters In This Topic

  • Solution

Figure it out.

 

Solution:

char_state.cpp

look for

if (self->Follow(victim, self->GetMobAttackRange() * 9 / 10))

and change to:

if (self->Follow(victim, 150 * 9 / 10))

look for :

(fDist >= GetMobAttackRange() * 1.15)

change to:

(fDist >= 150 * 1.15)

 

dont forget to change RANGE and MAGIC to MELEE in mob_proto

  • Premium
23 hours ago, betsch96 said:

GetMobAttackRange

Why didnt you just set the attackrange at the mob_proto to 150 or lower?

Because they do not use tools or sql proto so they got mad

Don't use any images from : imgur, turkmmop, freakgamers, inforge, hizliresim... Or your content will be deleted without notice...
Use : https://metin2.download/media/add/

Please use https://metin2.download/ when uploading files smaller than 100MB, otherwise the approval will take longer due to manual upload.

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
×
  • Create New...

Important Information

Terms of Use / Privacy Policy / Guidelines / We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.