Jump to content

If close the refine window, cannot open it again


Go to solution Solved by Amun,

Recommended Posts

  • Premium

Hello!

Spoiler

I litteraly want to cry. Im about to give up my project, i cannot do anything about it.

I need your help, guys. When i want to upgrade an item, but i close the refine window, i cannot move items, cannot drop/destroy/sell those items. After relog, i can do anything. It happens only with refine window.
If i want to refine, and i refine the item, i can refine it again. but its only happening when i CLOSE the window.
What did i do before this problem apperas? I really dont know. Only 3 systems touching to the refine system.
1.: extra refine system (tested while removed, same problem)
2.: slot marking system (tested while removed, same problem)
3.: fast refine system (tested while removed, same problem)
Removed all the 3 systems at the same time and still same problem.
(Nothing else touching the refine system)
Here is a gif about the problem:
If you want to see it, add me on discord. I can show it on discord too.
 

Sadly, there is no syserr.

Edited by Metin2 Dev
Core X - External 2 Internal

Ulthar

Link to comment
Share on other sites

  • Contributor
  • Solution

Can you check if it sends the packets to the server after each action(delete an item, throw it, open and close the refine window, refine an item)? Also check the packets you get back after trying that.

You can't drop items while refining, so the client probably doesn't let the server know you've closed the window.

.png

Edit: here's a pic with the server's packets, just in case:

.png

root/uiRefine

	def Accept(self):
		net.SendRefinePacket(self.targetItemPos, self.type)
		self.Close()

	def CancelRefine(self):
		net.SendRefinePacket(255, 255)
		self.Close()

	def OnPressEscapeKey(self):
		self.CancelRefine()
		return True

Which in turn is sent by the client and handled in input_main.cpp

void CInputMain::Refine(LPCHARACTER ch, const char* c_pData)
{
	// [...]

	if (p->type == 255)
	{
		// DoRefine Cancel
		ch->ClearRefineMode();
		return;
	}

	// [...]
}

char_item.cpp

void CHARACTER::SetRefineMode(int iAdditionalCell)
{
	m_iRefineAdditionalCell = iAdditionalCell;
	m_bUnderRefine = true;
}

void CHARACTER::ClearRefineMode()
{
	m_bUnderRefine = false;
	SetRefineNPC(NULL);
}

 

Good Luck 🙂

Edited by Amun
extra details
Link to comment
Share on other sites

  • Premium
21 minutes ago, Amun said:

Can you check if it sends the packets to the server after each action(delete an item, throw it, open and close the refine window, refine an item)? Also check the packets you get back after trying that.

You can't drop items while refining, so the client probably doesn't let the server know you've closed the window.

Yea, but sadly, idont know how can i do debug on server in windows 😄 so this is sad... but yea, u are right. server think im still refining.

Ulthar

Link to comment
Share on other sites

  • Contributor
4 minutes ago, Ulthar said:

Yea, but sadly, idont know how can i do debug on server in windows 😄 so this is sad... but yea, u are right. server think im still refining.

You don't have to debug the server, just check the client's packets. Mine might be slightly different from yours, but you got the point. Who knows, maybe it's just a python problem and you forgot to send the "refine end" packet.

Anyhow, you have everything you need in there.

Link to comment
Share on other sites

  • Premium
2 hours ago, Amun said:

root/uiRefine

	def Accept(self):
		net.SendRefinePacket(self.targetItemPos, self.type)
		self.Close()

	def CancelRefine(self):
		net.SendRefinePacket(255, 255)
		self.Close()

	def OnPressEscapeKey(self):
		self.CancelRefine()
		return True

This is part where i had the problem. Im just stoopid af. Just too stoopid for everything. Plus im blind too.
The problem was this:

Before:

	def CancelRefine(self):
		net.SendRefinePacket(255, 255)
		if app.ENABLE_REFINE_RENEWAL:
			constInfo.AUTO_REFINE_TYPE = 0
			constInfo.AUTO_REFINE_DATA = {
				"ITEM" : [-1, -1],
				"NPC" : [0, -1, -1, 0]
			}
		self.Close()

After:
 

	def CancelRefine(self):
		#net.SendRefinePacket(255, 255)
		net.SendRefinePacket(255, 255, 0, 0, 0, 0)
		if app.ENABLE_REFINE_RENEWAL:
			constInfo.AUTO_REFINE_TYPE = 0
			constInfo.AUTO_REFINE_DATA = {
				"ITEM" : [-1, -1],
				"NPC" : [0, -1, -1, 0]
			}
		self.Close()

 

Edited by Ulthar
  • Good 1

Ulthar

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

Announcements



  • Similar Content

  • Activity

    1. 5

      Effect weapons

    2. 3

      Crystal Metinstone

    3. 3

      Feeding game source to LLM

    4. 113

      Ulthar SF V2 (TMP4 Base)

    5. 3

      Feeding game source to LLM

    6. 0

      Target Information System

    7. 3

      Feeding game source to LLM

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