Jump to content
×
×
  • Create New...

How To Add Metin Stones on Minimap


Recommended Posts

M2 Download Center

Download Here ( Internal )

InstanceBase.h

find

            NAMECOLOR_WAYPOINT, 


            
add

            NAMECOLOR_METIN,

 

PythonCharacterManagerModule.cpp

find

    PyModule_AddIntConstant(poModule, "NAMECOLOR_MOB", CInstanceBase::NAMECOLOR_NORMAL_MOB);

add

    PyModule_AddIntConstant(poModule, "NAMECOLOR_METIN", CInstanceBase::NAMECOLOR_METIN);

 

InstanceBaseEffect.cpp

find

    else if (IsPoly())
    {
        return NAMECOLOR_MOB;
    }

add

    else if (IsStone())
    {
        return NAMECOLOR_METIN;
    }


 

PythonMiniMap.cpp

find

    m_NPCPositionVector.clear();


        
add

    m_MetinPositionVector.clear();

    
find

        else if (pkInstEach->IsNPC())
        {
            aMarkPosition.m_fX = ( m_fWidth - (float)m_WhiteMark.GetWidth() ) / 2.0f + fDistanceFromCenterX + m_fScreenX;
            aMarkPosition.m_fY = ( m_fHeight - (float)m_WhiteMark.GetHeight() ) / 2.0f + fDistanceFromCenterY + m_fScreenY;

            m_NPCPositionVector.push_back(aMarkPosition);
        }

add

        else if (pkInstEach->IsStone())
        {
            aMarkPosition.m_fX = ( m_fWidth - (float)m_WhiteMark.GetWidth() ) / 2.0f + fDistanceFromCenterX + m_fScreenX;
            aMarkPosition.m_fY = ( m_fHeight - (float)m_WhiteMark.GetHeight() ) / 2.0f + fDistanceFromCenterY + m_fScreenY;

            m_MetinPositionVector.push_back(aMarkPosition);
        }

 

find

    // NPC
    STATEMANAGER.SetRenderState(D3DRS_TEXTUREFACTOR, CInstanceBase::GetIndexedNameColor(CInstanceBase::NAMECOLOR_NPC));
    aIterator = m_NPCPositionVector.begin();
    while (aIterator != m_NPCPositionVector.end())
    {
        TMarkPosition & rPosition = *aIterator;
        m_WhiteMark.SetPosition(rPosition.m_fX, rPosition.m_fY);
        m_WhiteMark.Render();
        ++aIterator;
    }

add

    // Metin
    STATEMANAGER.SetRenderState(D3DRS_TEXTUREFACTOR, CInstanceBase::GetIndexedNameColor(CInstanceBase::NAMECOLOR_METIN));
    aIterator = m_MetinPositionVector.begin();
    while (aIterator != m_MetinPositionVector.end())
    {
        TMarkPosition & rPosition = *aIterator;
        m_WhiteMark.SetPosition(rPosition.m_fX, rPosition.m_fY);
        m_WhiteMark.Render();
        ++aIterator;
    }
    


PythonMiniMap.h

find

		TInstanceMarkPositionVector		m_NPCPositionVector;

add

		TInstanceMarkPositionVector		m_MetinPositionVector;


root/colorinfo.py

find

CHR_NAME_RGB_WARP = (136, 218, 241)

add

CHR_NAME_RGB_METIN = (240, 255, 255)

You can select another color from here
    
   
root/introloading.py

find

            chrmgr.NAMECOLOR_WAYPOINT : colorInfo.CHR_NAME_RGB_WAYPOINT,

add

            chrmgr.NAMECOLOR_METIN : colorInfo.CHR_NAME_RGB_METIN,

 

 

  • Metin2 Dev 13
  • Love 29
  • Love 4
  • Good 8
Link to comment
Share on other sites

  • 4 months later...

 

1205 13:26:44228 :: Traceback (most recent call last):

1205 13:26:44276 ::   File "introLoading.py", line 208, in LoadData

1205 13:26:44276 ::   File "introLoading.py", line 283, in __RegisterColor

1205 13:26:44276 :: AttributeError
1205 13:26:44276 :: : 
1205 13:26:44276 :: 'module' object has no attribute 'NAMECOLOR_METIN'
1205 13:26:44276 :: 

 

Link to comment
Share on other sites

  • 2 weeks later...
  • 2 months later...
  • 4 weeks later...
  • 10 months later...
  • 3 years later...

Anyone has solution how to fix it? I want minimalize filter like classic mobs..

 

https://ctrlv.cz/mPoW

Thanks!

Edit: Fix by yourself..

This:

// Metin
		STATEMANAGER.SetRenderState(D3DRS_TEXTUREFACTOR, CInstanceBase::GetIndexedNameColor(CInstanceBase::NAMECOLOR_METIN));
		aIterator = m_MetinPositionVector.begin();
		while (aIterator != m_MetinPositionVector.end())
		{
			TMarkPosition & rPosition = *aIterator;
			m_WhiteMark.SetPosition(rPosition.m_fX, rPosition.m_fY);
			m_WhiteMark.Render();
			++aIterator;
		}

Not under this:

// NPC
	STATEMANAGER.SetRenderState(D3DRS_TEXTUREFACTOR, CInstanceBase::GetIndexedNameColor(CInstanceBase::NAMECOLOR_NPC));
	aIterator = m_NPCPositionVector.begin();
	while (aIterator != m_NPCPositionVector.end())
	{
		TMarkPosition & rPosition = *aIterator;
		m_WhiteMark.SetPosition(rPosition.m_fX, rPosition.m_fY);
		m_WhiteMark.Render();
		++aIterator;
	}

But under this:

// Monster
		STATEMANAGER.SetRenderState(D3DRS_TEXTUREFACTOR, CInstanceBase::GetIndexedNameColor(CInstanceBase::NAMECOLOR_MOB));//m_MarkTypeToColorMap[TYPE_MONSTER]);
		aIterator = m_MonsterPositionVector.begin();
		while (aIterator != m_MonsterPositionVector.end())
		{
			TMarkPosition & rPosition = *aIterator;
			m_WhiteMark.SetPosition(rPosition.m_fX, rPosition.m_fY);
			m_WhiteMark.Render();
			++aIterator;
		}

 

Edited by Cunoo
  • Metin2 Dev 1
  • Love 1
  • Love 1
  • Good 3
Link to comment
Share on other sites

  • 10 months later...

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


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.