Jump to content

Artefact

Inactive Member
  • Posts

    11
  • Joined

  • Last visited

  • Feedback

    0%

Posts posted by Artefact

  1. 11 hours ago, ridetpro said:
    
    void CInputDB::ItemLoad(LPDESC d, const char * c_pData)
    
    // You missed this part
    switch (p->window)
    {
    	case INVENTORY:
    	case DRAGON_SOUL_INVENTORY:
    	{
    		item->AddToCharacter(ch, TItemPos(p->window, p->pos));
    	}
    	break;
    
    	case EQUIPMENT:
    	{
    		if (item->CheckItemUseLevel(ch->GetLevel()))
    		{
    			if (!item->EquipTo(ch, p->pos))
    			{
    				v.push_back(item);
    			}
    		}
    		else
    		{
    			v.push_back(item);
    		}
    	}
    	break;
    }

     

    			switch (p->window)
    			{
    				case INVENTORY:
    				case DRAGON_SOUL_INVENTORY:
    #ifdef ENABLE_SPECIAL_STORAGE
    				case UPGRADE_INVENTORY:
    				case BOOK_INVENTORY:
    				case STONE_INVENTORY:
    				{
    					//sys_err("Load shit window = %d // pos = %d", p->window, p->pos);
    					item->AddToCharacter(ch, TItemPos(p->window, p->pos));
    				}
    				break;
    #endif	
    					item->AddToCharacter(ch, TItemPos(p->window, p->pos));
    					break;
    
    				case EQUIPMENT:
    					if (item->CheckItemUseLevel(ch->GetLevel()) == true )
    					{
    						if (item->EquipTo(ch, p->pos) == false )
    						{
    							v.push_back(item);
    						}
    					}
    					else
    					{
    						v.push_back(item);
    					}
    					break;
    			}
    		}

     

  2. If I`m not wrong robert installed this system for 2 servers, as I know but yeah it costs.

    You have to adapt that pet render system cause it will not work exactly the same way, you have to send the index of the race to SetModel and the vnum of the item to SetArmor.

    I didn`t have time to work on it but if I`m not wrong now is from python.

  3. 9 hours ago, TysonDMG said:

    0307 14:01:05395 :: 'module' object has no attribute 'SetArmor'
    line

            renderTarget.SetArmor(self.RENDER_TARGET_INDEX, 11499)
    can you help with this..?

    First in CRenderTarget.h find void SelectModel(DWORD index);

    add 

    		void ChangeArmor(DWORD dwVnum);
    		void ChangeWeapon(DWORD dwVnum);
    		void ChangeHair(DWORD dwVnum);

    If you named the functions in crendertarget.cpp otherwise change it as you named them

    Second in UserInterface/CPythonRenderTargetModule.cpp

    find this { "SelectModel", renderTargetSelectModel, METH_VARARGS },

    add

    		{ "ChangeArmor", renderTargetChangeArmor, METH_VARARGS },
    		{ "ChangeWeapon", renderTargetChangeWeapon, METH_VARARGS },
    		{ "ChangeHair", renderTargetChangeHair, METH_VARARGS },

    And in crendertarget.cpp should look like this

    void CRenderTarget::ChangeArmor(DWORD vnum)
    {
    	if (!m_visible || !m_pModel)
    		return;
    	
    	m_pModel->SetArmor(vnum);
    	m_pModel->Refresh(CRaceMotionData::NAME_WAIT, true);
    }

    It works for me, tell me if it helped.

  4. On 2/5/2019 at 3:10 PM, ѕeмa™ said:

    Yes u can, just add something like this:

     

    1354c1631439602d1639924f3e997622.png

     

    1f0ee007aa3b76d9814d92e132847271.png

    I`ve done like you, no error when compilating binary, but it dosen`t work on the game, it shows the monsters but not the weapons, hairs or armors.

    One more thing, the background dosen`t work for me either, is black, the files are where they should be.

    p1.png

    p2.png

    p3.png

    • Metin2 Dev 1
    • Love 1
×
×
  • 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.