Jump to content

Await

Inactive Member
  • Posts

    6
  • Joined

  • Last visited

  • Feedback

    0%

Posts posted by Await

  1. M2 Download Center

    This is the hidden content, please
    ( Internal )

    Through this piece of code you will be able to attach the specular on NPCs and Monsters.

     

    // 1. Search:
    bool CInstanceBase::Create(const SCreateData& c_rkCreateData)
    {
    	[...]
    	return true;
    }
    
    // 2. Add this piece of code above the return true;
    
    struct SAttachSpecularData
    {
    	DWORD race;
    	float specularPower;
    };
    
    const int SPECULAR_MAX_NUM = 5;
    static SAttachSpecularData structInfo[SPECULAR_MAX_NUM] =
    {
    	{ 101,	0.09f },
    	{ 102,	0.06f },
    	{ 9001,	0.04f },
    	{ 9002,	0.01f },
    	{ 9005,	0.09f },
    //	{ npc_vnum,	specular }, Warning: When you add new NPCs / Monsters inside the structure, you must increase the SPECULAR_MAX_NUM
    };
    
    for (DWORD i = 0; i < SPECULAR_MAX_NUM; i++)
    {
    	if (GetRace() == structInfo[i].race)
    	{
    		SMaterialData data;
    		data.pImage = NULL;
    		data.isSpecularEnable = TRUE;
    		data.fSpecularPower = structInfo[i].specularPower;
    		data.bSphereMapIndex = 1;
    		m_GraphicThingInstance.SetMaterialData(0, NULL, data);
    	}
    }

     

    Credit: @VegaS™

    • Metin2 Dev 58
    • Think 2
    • Confused 2
    • Good 24
    • Love 12
    • Love 30
  2. I don't see any particular errors in the attached file. Check

    def __OnValueUpdate(self):

    in the uiCommon.py file.

     

    It should be:

    	def __OnValueUpdate(self):
    		ui.EditLine.OnIMEUpdate(self.inputValue)
    
    		text = self.inputValue.GetText()
    
    		money = 0
    		if text and text.isdigit():
    			try:
    				money = long(text)
    			except ValueError:
    				money = 199999999
    
    		self.moneyText.SetText(self.moneyHeaderText + localeInfo.NumberToMoneyString(money))

     

  3.  

    This error occurs when there is no code inside interfaceModule and the function is called, in our case from game.py

     

    You have to add code like this: (It's only an example)

    # Find
    	def __init__(self):
    		...
    		self.wndGuildBuilding = None
        
    # Add
    		self.wndDungeonInfo = None
    
    # Find
    	def __MakeWindows(self):
      		...
    		self.wndChatLog = wndChatLog
    # Add
    		self.wndDungeonInfo = uiDungeonInfo.DungeonInfo()
    		self.wndDungeonInfo.Load()

     

     

    Contact the guy where you bought the system, he will surely give you a hand 

×
×
  • 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.