Jump to content
For maintenance and updates, the community will be offline on 31 December 2022 ×
  • 0

stop mob collision with rank pawn


Cripplez

Question

Hello, i'm trying to stop the collision for mobs with rank Pawn

for example like this but instead of race vnum using the rank of the mob


#ifdef ENABLE_PETS_WITHOUT_COLLISIONS
    if (rVictim.GetRace()>=34001 && rVictim.GetRace()<=34119)
        return FALSE;
#endif

something like this could be made?

    if (rVictim.GetMobRank() =< 1)
        return FALSE;

Link to comment
Share on other sites

4 answers to this question

Recommended Posts

  • 0
  • Nitro Booster
	const CPythonNonPlayer::TMobTable* pkMobTable = CPythonNonPlayer::instance().GetTable(rVictim.GetRace());
	if (pkMobTable && pkMobTable->bRank == CPythonNonPlayer::MOB_RANK_PAWN)
		return false;

You also need to include PythonNonPlayer.h

#include "../UserInterface/PythonNonPlayer.h"

 

Edited by Owsap
Link to comment
Share on other sites

  • 0
2 hours ago, Owsap said:
	const CPythonNonPlayer::TMobTable* pkMobTable = CPythonNonPlayer::instance().GetTable(rVictim.GetRace());
	if (pkMobTable && pkMobTable->bRank == CPythonNonPlayer::MOB_RANK_PAWN)
		return false;

You also need to include PythonNonPlayer.h

#include "../UserInterface/PythonNonPlayer.h"

 

Thank you for the answer 🙂 I included it but i have this prolem:
OoOWTJf.png

 

In my binary files i searched for MOB_RANK_PAWN but there isn't, only in server source.
In the binary the rank of mob i think are only here in PythonNonPlayerModule.cpp
3vChmRX.png

Edited by Metin2 Dev
Core X - External 2 Internal
Link to comment
Share on other sites

  • 0
  • Nitro Booster
24 minutes ago, Cripplez said:

Thank you for the answer 🙂 I included it but i have this prolem:
OoOWTJf.png

 

In my binary files i searched for MOB_RANK_PAWN but there isn't, only in server source.
In the binary the rank of mob i think are only here in PythonNonPlayerModule.cpp
3vChmRX.png

Just replace CPythonNonPlayer::MOB_RANK_PAWN with 0.

Edited by Metin2 Dev
Core X - External 2 Internal
Link to comment
Share on other sites

  • 0
10 minutes ago, Owsap said:

Just replace CPythonNonPlayer::MOB_RANK_PAWN with 0.

I tried replacing it with 0 but when i compile i get this errors 🤔
dzc3rAT.png

Edited by Metin2 Dev
Core X - External 2 Internal
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now


  • Activity

    1. 992

      [40250] Reference Serverfile + Client + Src [15 Available Languages]

    2. 3

      Biologist Manager (C++ & LUA)

    3. 3

      Visual studio 2022 compiling issue

    4. 63

      Metin2 | Mount System Renewal

    5. 58

      Metin2 2004 Beta Client

    6. 0

      🔥Paradise2 PVP SERVER GLOBAL!! EN-ES-PT 🕐📢Apertura 11 de diciembre 21 horas de España!

    7. 0

      Please help here ( Sush system problem )

  • Recently Browsing

    • No registered users viewing this page.
!-->
×
×
  • 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.