Jump to content

Block Item's In Maps


Recommended Posts

  • Premium

M2 Download Center

This is the hidden content, please
( Internal )

Hallo

 

This Is For Block Item's In Map :

 

Beeter Then Quest :

 

 

char_item.cpp

 

Serch :

static bool IS_SUMMON_ITEM(int vnum)

after it add  :

static bool IS_ENABLE_ITEM(int vnum)
{
    switch (vnum)
    {
        case 39011:
        case 39012:
        case 39013:
            return true;
    }

    return false;
}
 

39011,39012,39013 Item's Want To Block It

 

 

Uz9tpON.png

 

Serch :

bool IS_BOTARYABLE_ZONE(int nMapIndex)
[code]
 
Befor IT Add
 
[code]
bool IS_ENABLE_ITEM_ZONE(int map_index)
{
    switch (map_index)
    {
        case 29:
        case 30:
        case 31:
            return false;
    }

    return true;
}

[/code]
 
29,30,31 Maps Index
 

 
 
 
Serch :
 
[code]
//PREVENT_TRADE_WINDOW
[/code]
 
Befor It Add :
 
[code]
    if (IS_ENABLE_ITEM(item->GetVnum()))
    {
        if (false == IS_ENABLE_ITEM_ZONE(GetMapIndex()))
        {
            ChatPacket(CHAT_TYPE_INFO, LC_TEXT("»ç؟ëاز¼ِ ¾ّ½ہ´د´ظ."));
            return false;
        }
    }

tGYQ5G2.png

 

 

Note : This System By MrLibya , For www.Arab-Dev.Org , Ida


 

Edited by Metin2 Dev
Core X - External 2 Internal
  • Metin2 Dev 14
  • Dislove 1
  • Confused 1
  • Good 3
  • Love 16

If you're going to do something, then do it right.

Link to comment
Share on other sites

Hallo

 

This Is For Block Item's In Map :

 

Beeter Then Quest :

 

 

char_item.cpp

 

Serch :

static bool IS_SUMMON_ITEM(int vnum)

after it add  :

static bool IS_ENABLE_ITEM(int vnum)
{
    switch (vnum)
    {
        case 39011:
        case 39012:
        case 39013:
            return true;
    }

    return false;
}
 

39011,39012,39013 Item's Want To Block It

 

 

Uz9tpON.png

 

Serch :

bool IS_BOTARYABLE_ZONE(int nMapIndex)
[code]
 
Befor IT Add
 
[code]
bool IS_ENABLE_ITEM_ZONE(int map_index)
{
    switch (map_index)
    {
        case 29:
        case 30:
        case 31:
            return false;
    }

    return true;
}

[/code]
 
29,30,31 Maps Index
 

 
 
 
Serch :
 
[code]
//PREVENT_TRADE_WINDOW
[/code]
 
Befor It Add :
 
[code]
    if (IS_ENABLE_ITEM(item->GetVnum()))
    {
        if (false == IS_ENABLE_ITEM_ZONE(GetMapIndex()))
        {
            ChatPacket(CHAT_TYPE_INFO, LC_TEXT("»ç؟ëاز¼ِ ¾ّ½ہ´د´ظ."));
            return false;
        }
    }

tGYQ5G2.png

 

 

Note : This System By MrLibya , For www.Arab-Dev.Org , Ida

 

he want do it in a archive txt in the server not in the source, but is a nice idea

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

  • Premium

Here it is with text file if someone still interested:
 
item_block.cpp:

#include "stdafx.h"
#include "item_block.h"
#include <fstream>
#include <sstream>

CItemBlock::CItemBlock(void)
{

}

CItemBlock::~CItemBlock(void)
{
}

void CItemBlock::Process(void)
{
	std::string strMapIndex;
	std::string strItemVnums;

	std::ifstream File("blocked_items.txt");

	if (!File.is_open())
		return;

	if (!m_map_BlockedItems.empty())
		m_map_BlockedItems.clear();

	while (!File.eof())
	{
		File >> strMapIndex >> strItemVnums;

		std::string strItemVnum;

		std::istringstream Vnums(strItemVnums);

		while (std::getline(Vnums, strItemVnum, ','))
		{
			AddItem(strtoul(strMapIndex.c_str(), NULL, 10), strtoul(strItemVnum.c_str(), NULL, 10));
		}
	}

	File.close();
}

void CItemBlock::AddItem(const long lMapIndex, const DWORD dwVnum)
{
	if (lMapIndex < 0 || dwVnum < 0)
		return;

	m_map_BlockedItems.insert(std::make_pair(lMapIndex, dwVnum));
}

void CItemBlock::RemoveItem(const long lMapIndex, const DWORD dwVnum)
{
	if (lMapIndex < 0 || dwVnum < 0)
		return;

	for (BLOCKED_ITEMS::const_iterator it = m_map_BlockedItems.begin(); it != m_map_BlockedItems.end()
	{
		if (it->first == lMapIndex && it->second == dwVnum)
			it = m_map_BlockedItems.erase(it);
		else
			++it;
	}
}

bool CItemBlock::CanUseItem(const long lMapIndex, const DWORD dwVnum) const
{
	for (BLOCKED_ITEMS::const_iterator it = m_map_BlockedItems.begin(); it != m_map_BlockedItems.end()
	{
		if (it->first == lMapIndex && it->second == dwVnum)
			return false;
	}

	return true;
}

item_block.h:

#ifndef __ITEM_BLOCK
#define __ITEM_BLOCK

class CItemBlock : public singleton<CItemBlock>
{
	public:
			CItemBlock();
			~CItemBlock();


	        void	Process(void);
	        bool	CanUseItem(const long lMapIndex, const DWORD dwVnum) const;
	        void	AddItem(const long lMapIndex, const DWORD dwVnum);
	        void	RemoveItem(const long lMapIndex, const DWORD dwVnum);

	private:
		typedef std::multimap<long, DWORD> BLOCKED_ITEMS;
		BLOCKED_ITEMS m_map_BlockedItems;
};

#endif /* __ITEM_BLOCK */

- Item can be removed runtime by using the RemoveItem(map_index, item_vnum) function.
- Item can be added runtime by using the AddItem(map_index, item_vnum) function
- To load or reload the txt file use the Process() function

 

Example of the TXT file:

50 120229,252391
51 10000,20000
52 43232
  • Love 9
Link to comment
Share on other sites

 

Here it is with text file if someone still interested:

 

item_block.cpp:

#include "stdafx.h"
#include "item_block.h"
#include <fstream>
#include <sstream>

CItemBlock::CItemBlock(void)
{

}

CItemBlock::~CItemBlock(void)
{
}

void CItemBlock::Process(void)
{
	std::string strMapIndex;
	std::string strItemVnums;

	std::ifstream File("blocked_items.txt");

	if (!File.is_open())
		return;

	if (!m_map_BlockedItems.empty())
		m_map_BlockedItems.clear();

	while (!File.eof())
	{
		File >> strMapIndex >> strItemVnums;

		std::string strItemVnum;

		std::istringstream Vnums(strItemVnums);

		while (std::getline(Vnums, strItemVnum, ','))
		{
			AddItem(strtoul(strMapIndex.c_str(), NULL, 10), strtoul(strItemVnum.c_str(), NULL, 10));
		}
	}

	File.close();
}

void CItemBlock::AddItem(const long lMapIndex, const DWORD dwVnum)
{
	if (lMapIndex < 0 || dwVnum < 0)
		return;

	m_map_BlockedItems.insert(std::make_pair(lMapIndex, dwVnum));
}

void CItemBlock::RemoveItem(const long lMapIndex, const DWORD dwVnum)
{
	if (lMapIndex < 0 || dwVnum < 0)
		return;

	for (BLOCKED_ITEMS::const_iterator it = m_map_BlockedItems.begin(); it != m_map_BlockedItems.end()
	{
		if (it->first == lMapIndex && it->second == dwVnum)
			it = m_map_BlockedItems.erase(it);
		else
			++it;
	}
}

bool CItemBlock::CanUseItem(const long lMapIndex, const DWORD dwVnum) const
{
	for (BLOCKED_ITEMS::const_iterator it = m_map_BlockedItems.begin(); it != m_map_BlockedItems.end()
	{
		if (it->first == lMapIndex && it->second == dwVnum)
			return false;
	}

	return true;
}

item_block.h:

#ifndef __ITEM_BLOCK
#define __ITEM_BLOCK

class CItemBlock : public singleton<CItemBlock>
{
	public:
			CItemBlock();
			~CItemBlock();


	        void	Process(void);
	        bool	CanUseItem(const long lMapIndex, const DWORD dwVnum) const;
	        void	AddItem(const long lMapIndex, const DWORD dwVnum);
	        void	RemoveItem(const long lMapIndex, const DWORD dwVnum);

	private:
		typedef std::multimap<long, DWORD> BLOCKED_ITEMS;
		BLOCKED_ITEMS m_map_BlockedItems;
};

#endif /* __ITEM_BLOCK */

- Item can be removed runtime by using the RemoveItem(map_index, item_vnum) function.

- Item can be added runtime by using the AddItem(map_index, item_vnum) function

- To load the txt file use the Process() function

 

Example of the TXT file:

50 120229,252391
51 10000,20000
52 43232

i like how you make a new cpp + header for easy remove when you need to

Link to comment
Share on other sites

  • 4 weeks later...
  • 3 weeks later...

 

Here it is with text file if someone still interested:

 

item_block.cpp:

#include "stdafx.h"
#include "item_block.h"
#include <fstream>
#include <sstream>

CItemBlock::CItemBlock(void)
{

}

CItemBlock::~CItemBlock(void)
{
}

void CItemBlock::Process(void)
{
	std::string strMapIndex;
	std::string strItemVnums;

	std::ifstream File("blocked_items.txt");

	if (!File.is_open())
		return;

	if (!m_map_BlockedItems.empty())
		m_map_BlockedItems.clear();

	while (!File.eof())
	{
		File >> strMapIndex >> strItemVnums;

		std::string strItemVnum;

		std::istringstream Vnums(strItemVnums);

		while (std::getline(Vnums, strItemVnum, ','))
		{
			AddItem(strtoul(strMapIndex.c_str(), NULL, 10), strtoul(strItemVnum.c_str(), NULL, 10));
		}
	}

	File.close();
}

void CItemBlock::AddItem(const long lMapIndex, const DWORD dwVnum)
{
	if (lMapIndex < 0 || dwVnum < 0)
		return;

	m_map_BlockedItems.insert(std::make_pair(lMapIndex, dwVnum));
}

void CItemBlock::RemoveItem(const long lMapIndex, const DWORD dwVnum)
{
	if (lMapIndex < 0 || dwVnum < 0)
		return;

	for (BLOCKED_ITEMS::const_iterator it = m_map_BlockedItems.begin(); it != m_map_BlockedItems.end()
	{
		if (it->first == lMapIndex && it->second == dwVnum)
			it = m_map_BlockedItems.erase(it);
		else
			++it;
	}
}

bool CItemBlock::CanUseItem(const long lMapIndex, const DWORD dwVnum) const
{
	for (BLOCKED_ITEMS::const_iterator it = m_map_BlockedItems.begin(); it != m_map_BlockedItems.end()
	{
		if (it->first == lMapIndex && it->second == dwVnum)
			return false;
	}

	return true;
}

item_block.h:

#ifndef __ITEM_BLOCK
#define __ITEM_BLOCK

class CItemBlock : public singleton<CItemBlock>
{
	public:
			CItemBlock();
			~CItemBlock();


	        void	Process(void);
	        bool	CanUseItem(const long lMapIndex, const DWORD dwVnum) const;
	        void	AddItem(const long lMapIndex, const DWORD dwVnum);
	        void	RemoveItem(const long lMapIndex, const DWORD dwVnum);

	private:
		typedef std::multimap<long, DWORD> BLOCKED_ITEMS;
		BLOCKED_ITEMS m_map_BlockedItems;
};

#endif /* __ITEM_BLOCK */

- Item can be removed runtime by using the RemoveItem(map_index, item_vnum) function.

- Item can be added runtime by using the AddItem(map_index, item_vnum) function

- To load or reload the txt file use the Process() function

 

Example of the TXT file:

50 120229,252391
51 10000,20000
52 43232

For me is not working.. it crash. The issue is this: https://metin2.download/picture/cKZ0I9ew34bxF3eyABl64lN4vMiTuq23/.png. I think because there is not a constructor (i have tried without singleton and it is work but I need singleton..) that initialize the multimap, but I think also I am doing something that is not right. I am using g++4.2.1 (default).

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

  • 2 weeks later...
  • 1 month later...

Duello event 

 

 

Hallo

 

This Is For Block Item's In Map :

 

Beeter Then Quest :

 

 

char_item.cpp

 

Serch :

static bool IS_SUMMON_ITEM(int vnum)

after it add  :

static bool IS_ENABLE_ITEM(int vnum)
{
    switch (vnum)
    {
        case 39011:
        case 39012:
        case 39013:
            return true;
    }

    return false;
}
 

39011,39012,39013 Item's Want To Block It

 

 

Uz9tpON.png

 

Serch :

bool IS_BOTARYABLE_ZONE(int nMapIndex)
[code]
 
Befor IT Add
 
[code]
bool IS_ENABLE_ITEM_ZONE(int map_index)
{
    switch (map_index)
    {
        case 29:
        case 30:
        case 31:
            return false;
    }

    return true;
}

[/code]
 
29,30,31 Maps Index
 

 
 
 
Serch :
 
[code]
//PREVENT_TRADE_WINDOW
[/code]
 
Befor It Add :
 
[code]
    if (IS_ENABLE_ITEM(item->GetVnum()))
    {
        if (false == IS_ENABLE_ITEM_ZONE(GetMapIndex()))
        {
            ChatPacket(CHAT_TYPE_INFO, LC_TEXT("»ç؟ëاز¼ِ ¾ّ½ہ´د´ظ."));
            return false;
        }
    }

tGYQ5G2.png

 

 

Note : This System By MrLibya , For www.Arab-Dev.Org , Ida
 

he want do it in a archive txt in the server not in the source, but is a nice idea

 

How do we close the duel activity in blessing others shamans character feature? So locking ability .

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

  • 4 weeks later...
  • 1 year later...
  • Premium
On 23/12/2014 at 1:15 AM, Sanchez said:

Here it is with text file if someone still interested:
 
item_block.cpp:


#include "stdafx.h"
#include "item_block.h"
#include <fstream>
#include <sstream>

CItemBlock::CItemBlock(void)
{

}

CItemBlock::~CItemBlock(void)
{
}

void CItemBlock::Process(void)
{
	std::string strMapIndex;
	std::string strItemVnums;

	std::ifstream File("blocked_items.txt");

	if (!File.is_open())
		return;

	if (!m_map_BlockedItems.empty())
		m_map_BlockedItems.clear();

	while (!File.eof())
	{
		File >> strMapIndex >> strItemVnums;

		std::string strItemVnum;

		std::istringstream Vnums(strItemVnums);

		while (std::getline(Vnums, strItemVnum, ','))
		{
			AddItem(strtoul(strMapIndex.c_str(), NULL, 10), strtoul(strItemVnum.c_str(), NULL, 10));
		}
	}

	File.close();
}

void CItemBlock::AddItem(const long lMapIndex, const DWORD dwVnum)
{
	if (lMapIndex < 0 || dwVnum < 0)
		return;

	m_map_BlockedItems.insert(std::make_pair(lMapIndex, dwVnum));
}

void CItemBlock::RemoveItem(const long lMapIndex, const DWORD dwVnum)
{
	if (lMapIndex < 0 || dwVnum < 0)
		return;

	for (BLOCKED_ITEMS::const_iterator it = m_map_BlockedItems.begin(); it != m_map_BlockedItems.end()
	{
		if (it->first == lMapIndex && it->second == dwVnum)
			it = m_map_BlockedItems.erase(it);
		else
			++it;
	}
}

bool CItemBlock::CanUseItem(const long lMapIndex, const DWORD dwVnum) const
{
	for (BLOCKED_ITEMS::const_iterator it = m_map_BlockedItems.begin(); it != m_map_BlockedItems.end()
	{
		if (it->first == lMapIndex && it->second == dwVnum)
			return false;
	}

	return true;
}

item_block.h:


#ifndef __ITEM_BLOCK
#define __ITEM_BLOCK

class CItemBlock : public singleton<CItemBlock>
{
	public:
			CItemBlock();
			~CItemBlock();


	        void	Process(void);
	        bool	CanUseItem(const long lMapIndex, const DWORD dwVnum) const;
	        void	AddItem(const long lMapIndex, const DWORD dwVnum);
	        void	RemoveItem(const long lMapIndex, const DWORD dwVnum);

	private:
		typedef std::multimap<long, DWORD> BLOCKED_ITEMS;
		BLOCKED_ITEMS m_map_BlockedItems;
};

#endif /* __ITEM_BLOCK */

- Item can be removed runtime by using the RemoveItem(map_index, item_vnum) function.
- Item can be added runtime by using the AddItem(map_index, item_vnum) function
- To load or reload the txt file use the Process() function

 

Example of the TXT file:


50 120229,252391
51 10000,20000
52 43232

 

any help?

813b77e47ecc4240b52652a66f963d80.png

https://metin2.download/picture/r3F9504x09DVmF8K988YXgTtGTP6KMUj/.gif

Edited by Metin2 Dev
Core X - External 2 Internal
if pc.get_sex() == true and npc.get_sex() == false then
	npc.purge()
end

 

Link to comment
Share on other sites

  • Premium
On 11/12/2016 at 0:06 AM, metin2-factory said:

item_block.cpp line 70 modify to the following:

for (BLOCKED_ITEMS::const_iterator it = m_map_BlockedItems.begin(); it != m_map_BlockedItems.end();++it)

i get same error in line 59. So i make the same u say.... 

 

This systems it's all bug :\ Cant compile. But ty anywat

 

 

error:  " 
item_block.cpp:61: error: no matching function for call to 'std::multimap<long int, unsigned int,

"

if pc.get_sex() == true and npc.get_sex() == false then
	npc.purge()
end

 

Link to comment
Share on other sites

40 minutes ago, EnKor said:

i get same error in line 59. So i make the same u say.... 

 

This systems it's all bug :\ Cant compile. But ty anywat

 

 

error:  " 
item_block.cpp:61: error: no matching function for call to 'std::multimap<long int, unsigned int,

"

 

 

Here if fixed :

#include "stdafx.h"
#include "item_block.h"
#include <fstream>
#include <sstream>

void CItemBlock::Process()
{
	std::string strMapIndex;
	std::string strItemVnums;

	std::ifstream File("blocked_items.txt");

	if (!File.is_open())
		return;

	if (!m_map_BlockedItems.empty())
		m_map_BlockedItems.clear();

	while (!File.eof())
	{
		File >> strMapIndex >> strItemVnums;

		std::string strItemVnum;

		std::istringstream Vnums(strItemVnums);

		while (std::getline(Vnums, strItemVnum, ','))
		{
			AddItem(strtoul(strMapIndex.c_str(), NULL, 10), strtoul(strItemVnum.c_str(), NULL, 10));
		}
	}

	File.close();
}

void CItemBlock::AddItem(const long lMapIndex, const DWORD dwVnum)
{
	if (lMapIndex < 0 || dwVnum < 0)
		return;

	m_map_BlockedItems.insert(std::make_pair(lMapIndex, dwVnum));
}

void CItemBlock::RemoveItem(const long lMapIndex, const DWORD dwVnum)
{
	if (lMapIndex < 0 || dwVnum < 0)
		return;

	BLOCKED_ITEMS::const_iterator it = m_map_BlockedItems.begin();

	if (it != m_map_BlockedItems.end())
	{
		if (it->first == lMapIndex && it->second == dwVnum)
			it = m_map_BlockedItems.erase(it);
		else
			++it;
	}

}

bool CItemBlock::CanUseItem(const long lMapIndex, const DWORD dwVnum) const
{
	BLOCKED_ITEMS::const_iterator it = m_map_BlockedItems.begin();

	if (it != m_map_BlockedItems.end())
	{
		if (it->first == lMapIndex && it->second == dwVnum)
			return false;
	}

	return true;
}
#pragma once

class CItemBlock : public singleton<CItemBlock>
{
public:
	CItemBlock()	{ }
	~CItemBlock()	{ }

	void	Process();
	bool	CanUseItem(const long lMapIndex, const DWORD dwVnum) const;
	void	AddItem(const long lMapIndex, const DWORD dwVnum);
	void	RemoveItem(const long lMapIndex, const DWORD dwVnum);

private:
	typedef std::multimap<long, DWORD> BLOCKED_ITEMS;
	BLOCKED_ITEMS m_map_BlockedItems;
};

 

  • Love 1
Link to comment
Share on other sites

  • Premium
On 11/12/2016 at 9:47 AM, 127.0.0.1 said:

 

 

Here if fixed :


#include "stdafx.h"
#include "item_block.h"
#include <fstream>
#include <sstream>

void CItemBlock::Process()
{
	std::string strMapIndex;
	std::string strItemVnums;

	std::ifstream File("blocked_items.txt");

	if (!File.is_open())
		return;

	if (!m_map_BlockedItems.empty())
		m_map_BlockedItems.clear();

	while (!File.eof())
	{
		File >> strMapIndex >> strItemVnums;

		std::string strItemVnum;

		std::istringstream Vnums(strItemVnums);

		while (std::getline(Vnums, strItemVnum, ','))
		{
			AddItem(strtoul(strMapIndex.c_str(), NULL, 10), strtoul(strItemVnum.c_str(), NULL, 10));
		}
	}

	File.close();
}

void CItemBlock::AddItem(const long lMapIndex, const DWORD dwVnum)
{
	if (lMapIndex < 0 || dwVnum < 0)
		return;

	m_map_BlockedItems.insert(std::make_pair(lMapIndex, dwVnum));
}

void CItemBlock::RemoveItem(const long lMapIndex, const DWORD dwVnum)
{
	if (lMapIndex < 0 || dwVnum < 0)
		return;

	BLOCKED_ITEMS::const_iterator it = m_map_BlockedItems.begin();

	if (it != m_map_BlockedItems.end())
	{
		if (it->first == lMapIndex && it->second == dwVnum)
			it = m_map_BlockedItems.erase(it);
		else
			++it;
	}

}

bool CItemBlock::CanUseItem(const long lMapIndex, const DWORD dwVnum) const
{
	BLOCKED_ITEMS::const_iterator it = m_map_BlockedItems.begin();

	if (it != m_map_BlockedItems.end())
	{
		if (it->first == lMapIndex && it->second == dwVnum)
			return false;
	}

	return true;
}

#pragma once

class CItemBlock : public singleton<CItemBlock>
{
public:
	CItemBlock()	{ }
	~CItemBlock()	{ }

	void	Process();
	bool	CanUseItem(const long lMapIndex, const DWORD dwVnum) const;
	void	AddItem(const long lMapIndex, const DWORD dwVnum);
	void	RemoveItem(const long lMapIndex, const DWORD dwVnum);

private:
	typedef std::multimap<long, DWORD> BLOCKED_ITEMS;
	BLOCKED_ITEMS m_map_BlockedItems;
};

 

 

 

ab89ef592fd54a009ff79edc72e29bad.png

Edited by Metin2 Dev
Core X - External 2 Internal
if pc.get_sex() == true and npc.get_sex() == false then
	npc.purge()
end

 

Link to comment
Share on other sites

in block_item.cpp modify these 2 functions
 

Spoiler

void CItemBlock::RemoveItem(const long lMapIndex, const DWORD dwVnum)
{
    if (lMapIndex < 0 || dwVnum < 0)
        return;

    for (BLOCKED_ITEMS::const_iterator it = m_map_BlockedItems.begin(); it != m_map_BlockedItems.end();++it)
    {
        if (it->first == lMapIndex && it->second == dwVnum)
            m_map_BlockedItems.erase(it);
    }
}

bool CItemBlock::CanUseItem(const long lMapIndex, const DWORD dwVnum) const
{
    for (BLOCKED_ITEMS::const_iterator it = m_map_BlockedItems.begin(); it != m_map_BlockedItems.end();++it)
    {
        if (it->first == lMapIndex && it->second == dwVnum)
            return false;
    }

    return true;
}

 

  • Love 1
Link to comment
Share on other sites

  • Premium
On 11/12/2016 at 10:10 AM, metin2-factory said:

in block_item.cpp modify these 2 functions
 

  Hide contents

void CItemBlock::RemoveItem(const long lMapIndex, const DWORD dwVnum)
{
    if (lMapIndex < 0 || dwVnum < 0)
        return;

    for (BLOCKED_ITEMS::const_iterator it = m_map_BlockedItems.begin(); it != m_map_BlockedItems.end();++it)
    {
        if (it->first == lMapIndex && it->second == dwVnum)
            m_map_BlockedItems.erase(it);
    }
}

bool CItemBlock::CanUseItem(const long lMapIndex, const DWORD dwVnum) const
{
    for (BLOCKED_ITEMS::const_iterator it = m_map_BlockedItems.begin(); it != m_map_BlockedItems.end();++it)
    {
        if (it->first == lMapIndex && it->second == dwVnum)
            return false;
    }

    return true;
}

 

i belive this system wont work at all. Tks for ur help, but i belive its better give up. 

This system wont work at all.

 

2fd0bf660e904cab804eea56bf4d9ec3.png

Edited by Metin2 Dev
Core X - External 2 Internal
if pc.get_sex() == true and npc.get_sex() == false then
	npc.purge()
end

 

Link to comment
Share on other sites

Announcements



  • Similar Content

  • Similar Content

  • Similar Content

  • Tags

  • Activity

    1. 3

      Crystal Metinstone

    2. 3

      Feeding game source to LLM

    3. 113

      Ulthar SF V2 (TMP4 Base)

    4. 3

      Feeding game source to LLM

    5. 0

      Target Information System

    6. 3

      Feeding game source to LLM

    7. 2

      anti exp explanation pls

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