Jump to content

[Q]Autopickup filter


Recommended Posts

  • Management

I use this pick up on my client: https://uploads.habira-gamers.org/index.php/s/boeQ4U5nNGj6LLo

It's a python script, it appears under the minimap when imported...

This only picks up itens with the owner's name or without any name, I don't know if is this exactly what you're looking for...

  • Metin2 Dev 1
  • Lmao 1
  • Love 1

raw

raw

Link to comment
Share on other sites

13 minutes ago, charparodar said:

I use this pick up on my client: https://uploads.habira-gamers.org/index.php/s/boeQ4U5nNGj6LLo

It's a python script, it appears under the minimap when imported...

This only picks up itens with the owner's name or without any name, I don't know if is this exactly what you're looking for...

it isn't but i think i can edit it to be what i want, thank you alot for help. What i wanted is a pickupbot that will pick a type of items. For example it will pick only Moonlight chests

Link to comment
Share on other sites

  • Premium
36 minutes ago, charparodar said:

I use this pick up on my client: https://uploads.habira-gamers.org/index.php/s/boeQ4U5nNGj6LLo

It's a python script, it appears under the minimap when imported...

This only picks up itens with the owner's name or without any name, I don't know if is this exactly what you're looking for...

player.PickCloseItem()

doesn't this function try to pick the closest item regardless of its owner? IIRC it doesn't try to pick the items with your name only.

 

"Nothing's free in this life.

Ignorant people have an obligation to make up for their ignorance by paying those who help them.

Either you got the brains or cash, if you lack both you're useless."

Syreldar

Link to comment
Share on other sites

  • Management
Just now, NabbHackeR said:

player.PickCloseItem()

doesn't this function try to pick the closest item regardless of its owner? IIRC it's not picking the items with your name only.

At least on my server it only picks the itens with the owner's name or without anyone's name..., Yang is included...

raw

raw

Link to comment
Share on other sites

3 minutes ago, charparodar said:

At least on my server it only picks the itens with the owner's name or without anyone's name..., Yang is included...

I understand what u're telling me.

But look, for example, there are two items dropped : Sword+2 and Skill Book. I want this autopickup to pick only the book. And i want to tell it what to pick up in the .py script, not ingame.

Link to comment
Share on other sites

  • Premium

def PickUpItem(self): player.PickCloseItem()

1230 game.py

def PickUpStart(self): player.PickCloseItem()

119 pickup.py

 

I remembered correctly, it will not only try to pickup the items with your name, but the others too, so say goodbye to ur chat if u step on an item you're not the owner of XD

 

"Nothing's free in this life.

Ignorant people have an obligation to make up for their ignorance by paying those who help them.

Either you got the brains or cash, if you lack both you're useless."

Syreldar

Link to comment
Share on other sites

  • Management
Just now, devilake said:

I understand what u're telling me.

But look, for example, there are two items dropped : Sword+2 and Skill Book. I want this autopickup to pick only the book. And i want to tell it what to pick up from the .py script, not ingame.

I'm sorry, but I don't know almost anything about python, that script wasn't made by me...

raw

raw

Link to comment
Share on other sites

  • Premium
1 minute ago, charparodar said:

I'm sorry, but I don't know almost anything about python, that script wasn't made by me...

It's okay man, don't worry!

 

"Nothing's free in this life.

Ignorant people have an obligation to make up for their ignorance by paying those who help them.

Either you got the brains or cash, if you lack both you're useless."

Syreldar

Link to comment
Share on other sites

2 minutes ago, NabbHackeR said:

def PickUpItem(self): player.PickCloseItem()

1230 game.py

def PickUpStart(self): player.PickCloseItem()

119 pickup.py

 

I remembered correctly, it will not only try to pickup the items with your name, but the others too, so say goodbye to ur chat if u step on an item you're not the owner of XD

Got it, but i don't need this, i already have this, check my response to charparodar

Link to comment
Share on other sites

  • Premium
Just now, devilake said:

Got it, but i don't need this, i already have this, check my response to charparodar

You misunderstood, i just said it does the same as the Z button, but automatically.

 

"Nothing's free in this life.

Ignorant people have an obligation to make up for their ignorance by paying those who help them.

Either you got the brains or cash, if you lack both you're useless."

Syreldar

Link to comment
Share on other sites

  • Premium
42 minutes ago, devilake said:

No, you misunderstood. I know what it does, i have an autopickup script, i don't need that. I need a script that picks up only books, not every garbage from the ground.

oh.

add an itemVnum arg to the function and make an array of items you want to pickup, then check it and if it matches one of them, proceed to pick it.

Or just use a value() or socket() change.

 

"Nothing's free in this life.

Ignorant people have an obligation to make up for their ignorance by paying those who help them.

Either you got the brains or cash, if you lack both you're useless."

Syreldar

Link to comment
Share on other sites

1 minute ago, NabbHackeR said:

oh.

add an itemVnum arg to the function and make an array of items you want to pickup, then check it and if it matches one of them, proceed to pick it.

Or just change use a value() or socket() change.

May you, please, help me with that? I'm not familiar with Metin's libs.

Link to comment
Share on other sites

1 hour ago, charparodar said:

This only picks up itens with the owner's name or without any name.

Haha bro, that is nice xD *this script and all script for pickup, called a simple function player.PickCloseItem() with delay automatically.

He want to make a special functions to send to binary to check vnum xD.

That means you need to make a new functions in binary.

Ahh here is a point how to make, i made this long time ago.

if app.ENABLE_SPECIAL_AUTOPICKUP_BY_VNUM
	def BINARY_AutoPickUp_Append(self, reason):
		import player as ch
		import chat as msg
			
		if reason == "open":
			global bCheckActive
			if bCheckActive == 0:
				bCheckActive = 1
				
				ch.PickItemByVnum() # New Function need to create on binary
				msg.AppendChat(msg.CHAT_TYPE_INFO, "Enabled BINARY_AutoPickUp_Append")
			else:
				msg.AppendChat(msg.CHAT_TYPE_INFO, "Disabled BINARY_AutoPickUp_Append")
				bCheckActive = 0

 

#ifdef ENABLE_SPECIAL_AUTOPICKUP_BY_VNUM
void CPythonPlayer::PickItemByVnum(DWORD dwItem)
{
/*********
* author:       VegaS
* description:  Function called from python for autopickup with check to pick item only if exist in dwTableAcces
* date:         Feb. 27 2016, 01:36 am
*/
	CInstanceBase * ch = NEW_GetMainActorPtr();
	if (!ch)
		return;
	
	TPixelPosition chPos;
	ch->NEW_GetPixelPosition(&chPos);

	DWORD dwTableAcces[] = {
		50011, 53001, 53002, 53003, 53004, 53005, 53006, 53007, 53008, 53009, 53010, 53011, 53012, 53013, 53014, 53015, 53016, 53017, 53018, 53019, 53020, 53021, 53022, 53023, 53024, 53025
	};
	
	for (DWORD idxVnum = 0; idxVnum < _countof(dwTableAcces); idxVnum++)
	{
		if (dwItem == dwTableAcces[idxVnum]) 
		{
			TraceError("CPythonPlayer::PickItemByVnum:: Vid = [%d] Name = [%s] Vnum = (%d)", ch->GetVirtualID(), ch->GetNameString(), dwItem);
			SendClickItemPacket(dwItem);
		}
		else
			TraceError("CPythonPlayer::PickItemByVnum:: Vnum %d is not in table for can pickup him.", dwItem);
	}
}
#endif

 

If u use small part of brain you can do this fucking easy ^^.

  • Love 3
Link to comment
Share on other sites

13 minutes ago, VegaS said:

Haha bro, that is nice xD *this script and all script for pickup, called a simple function player.PickCloseItem() with delay automatically.

He want to make a special functions to send to binary to check vnum xD.

That means you need to make a new functions in binary.

Ahh here is a point how to make, i made this long time ago.

 

If u use small part of brain you can do this fucking easy ^^.

Thank you, buy i have no access to binary, i need to do it with pure python.

Link to comment
Share on other sites

  • Premium
45 minutes ago, devilake said:

May you, please, help me with that? I'm not familiar with Metin's libs.

I told you how to do it with pure python, he did the same thing, he just did it in C++.

 

 

"Nothing's free in this life.

Ignorant people have an obligation to make up for their ignorance by paying those who help them.

Either you got the brains or cash, if you lack both you're useless."

Syreldar

Link to comment
Share on other sites

15 hours ago, NabbHackeR said:

I told you how to do it with pure python, he did the same thing, he just did it in C++.

 

I have a script that is taken from a multihack, i can show it to you, when i try to implement it to my client, it crashes, maybe because of the client antihack protection wich i don't know how to bypass

Link to comment
Share on other sites

  • 2 weeks later...
  • Management
On 17/10/2016 at 9:59 PM, VegaS said:

Haha bro, that is nice xD *this script and all script for pickup, called a simple function player.PickCloseItem() with delay automatically.

He want to make a special functions to send to binary to check vnum xD.

That means you need to make a new functions in binary.

Ahh here is a point how to make, i made this long time ago.


if app.ENABLE_SPECIAL_AUTOPICKUP_BY_VNUM
	def BINARY_AutoPickUp_Append(self, reason):
		import player as ch
		import chat as msg
			
		if reason == "open":
			global bCheckActive
			if bCheckActive == 0:
				bCheckActive = 1
				
				ch.PickItemByVnum() # New Function need to create on binary
				msg.AppendChat(msg.CHAT_TYPE_INFO, "Enabled BINARY_AutoPickUp_Append")
			else:
				msg.AppendChat(msg.CHAT_TYPE_INFO, "Disabled BINARY_AutoPickUp_Append")
				bCheckActive = 0

 


#ifdef ENABLE_SPECIAL_AUTOPICKUP_BY_VNUM
void CPythonPlayer::PickItemByVnum(DWORD dwItem)
{
/*********
* author:       VegaS
* description:  Function called from python for autopickup with check to pick item only if exist in dwTableAcces
* date:         Feb. 27 2016, 01:36 am
*/
	CInstanceBase * ch = NEW_GetMainActorPtr();
	if (!ch)
		return;
	
	TPixelPosition chPos;
	ch->NEW_GetPixelPosition(&chPos);

	DWORD dwTableAcces[] = {
		50011, 53001, 53002, 53003, 53004, 53005, 53006, 53007, 53008, 53009, 53010, 53011, 53012, 53013, 53014, 53015, 53016, 53017, 53018, 53019, 53020, 53021, 53022, 53023, 53024, 53025
	};
	
	for (DWORD idxVnum = 0; idxVnum < _countof(dwTableAcces); idxVnum++)
	{
		if (dwItem == dwTableAcces[idxVnum]) 
		{
			TraceError("CPythonPlayer::PickItemByVnum:: Vid = [%d] Name = [%s] Vnum = (%d)", ch->GetVirtualID(), ch->GetNameString(), dwItem);
			SendClickItemPacket(dwItem);
		}
		else
			TraceError("CPythonPlayer::PickItemByVnum:: Vnum %d is not in table for can pickup him.", dwItem);
	}
}
#endif

 

If u use small part of brain you can do this fucking easy ^^.

Hi VegaS

How can I edit that code to add yang? Since sometimes is to much yang and the floor is all shining, and the premium bonus doesn't catch all the money...

Thanks

raw

raw

Link to comment
Share on other sites

  • 1 year later...

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

Announcements



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