Jump to content

TMP4

Contributor
  • Posts

    1112
  • Joined

  • Last visited

  • Days Won

    20
  • Feedback

    100%

Posts posted by TMP4

  1. Track down where it goes wrong as i said:

    Quote

     

    If i were you, i would track down the count with

    
    Chat.AppendChat(str(itemCount)) #example

    if your problem is created in python. (uiinventory.py)

     

    If not, then i would write the count from binary to the syserr.txt to check there next. (pythonnetworkstreammodule.cpp)

    
    #define sys_err TraceError
    #define sys_log //(n, format, ...) Tracenf(format, __VA_ARGS__)
    sys_err("Count: %d", num); //num is count if i'm not wrong

    If not, then go the serverside and do the same. (input_main.cpp)

    
    sys_err("Count in serverside %d", pinfo->count);

     

    
     
  2. It's just a copy paste really :(

    Spoiler


    Quote

    If i were you, i would track down the count with

    
    
    Chat.AppendChat(str(itemCount)) #example

    if your problem is created in python. (uiinventory.py)

     

    If not, then i would write the count from binary to the syserr.txt to check there next. (pythonnetworkstreammodule.cpp)

    
    
    #define sys_err TraceError
    #define sys_log //(n, format, ...) Tracenf(format, __VA_ARGS__)
    sys_err("Count: %d", num); //num is count if i'm not wrong

    If not, then go the serverside and do the same. (input_main.cpp)

    
    
    sys_err("Count in serverside %d", pinfo->count);


     

     

    Btw he wrote me a PM asking to add him in Discord, i said "no sorry i'm not doing private help" and he wrote me again with "You can add me, i'm not fake"

    So i have doubt with him, don't worry :D

  3. It is only happening with special storage's items? Your syserr's item is one of them. But if it's not then i doubt it is causes by special storage.

     

    Also the duped id's item's pair is the same item or not?

    For example in your item table the item with id "50000306" is a "Kurt Postu+"?

    If it's the same, they're really just duplicating.

    (But they sell the duped items and it's disappear with a "flush" from the victim's inventory)

    • Love 1
  4. I would really help you since i have nothing to do in quarantine but you did not attached your code so it is impossible.

    Idk if special storage and normal storage uses the same python, but if so, your problem will be in either binary or game source.


    The default code from uiinventory.py to binary and finally in game (linearly to the process):

    Spoiler

     

    
    			elif app.IsPressed(app.DIK_LSHIFT):
    				itemCount = player.GetItemCount(itemSlotIndex)
    				
    				if itemCount > 1:
    					self.dlgPickMoney.SetTitleName(localeinfo.PICK_ITEM_TITLE)
    					self.dlgPickMoney.SetAcceptEvent(ui.__mem_func__(self.OnPickItem))
    					self.dlgPickMoney.Open(itemCount)
    					self.dlgPickMoney.itemGlobalSlotIndex = itemSlotIndex
    				#else:
    					#selectedItemVNum = player.GetItemIndex(itemSlotIndex)
    					#mouseModule.mouseController.AttachObject(self, player.SLOT_TYPE_INVENTORY, itemSlotIndex, selectedItemVNum)
    
    	def OnPickItem(self, count):
    		itemSlotIndex = self.dlgPickMoney.itemGlobalSlotIndex
    		selectedItemVNum = player.GetItemIndex(itemSlotIndex)
    		mouseModule.mouseController.AttachObject(self, player.SLOT_TYPE_INVENTORY, itemSlotIndex, selectedItemVNum, count)
    
    	def SelectEmptySlot(self, selectedSlotPos):
    		if constInfo.GET_ITEM_DROP_QUESTION_DIALOG_STATUS() == 1:
    			return
    
    		selectedSlotPos = self.__InventoryLocalSlotPosToGlobalSlotPos(selectedSlotPos)
    
    		if mouseModule.mouseController.isAttached():
    
    			attachedSlotType = mouseModule.mouseController.GetAttachedType()
    			attachedSlotPos = mouseModule.mouseController.GetAttachedSlotNumber()
    			attachedItemCount = mouseModule.mouseController.GetAttachedItemCount()
    			attachedItemIndex = mouseModule.mouseController.GetAttachedItemIndex()
    
    			if player.SLOT_TYPE_INVENTORY == attachedSlotType:
    				itemCount = player.GetItemCount(attachedSlotPos)
    				attachedCount = mouseModule.mouseController.GetAttachedItemCount()
    				self.__SendMoveItemPacket(attachedSlotPos, selectedSlotPos, attachedCount)
    
    				if item.IsRefineScroll(attachedItemIndex):
    					self.wndItem.SetUseMode(FALSE)
    
    			elif player.SLOT_TYPE_PRIVATE_SHOP == attachedSlotType:
    				mouseModule.mouseController.RunCallBack("INVENTORY")
    
    			elif player.SLOT_TYPE_SHOP == attachedSlotType:
    				net.SendShopBuyPacket(attachedSlotPos)
    
    			elif player.SLOT_TYPE_SAFEBOX == attachedSlotType:
    
    				if player.ITEM_MONEY == attachedItemIndex:
    					net.SendSafeboxWithdrawMoneyPacket(mouseModule.mouseController.GetAttachedItemCount())
    					snd.PlaySound("sound/ui/money.wav")
    
    				else:
    					net.SendSafeboxCheckoutPacket(attachedSlotPos, selectedSlotPos)
    
    			elif player.SLOT_TYPE_MALL == attachedSlotType:
    				net.SendMallCheckoutPacket(attachedSlotPos, selectedSlotPos)
    
    			mouseModule.mouseController.DeattachObject()
    
    	def __SendMoveItemPacket(self, srcSlotPos, dstSlotPos, srcItemCount):
    		# °łŔλóÁˇ ż­°í ŔÖ´Â µżľČ ľĆŔĚĹŰ »çżë ąćÁö
    		if uiPrivateShopBuilder.IsBuildingPrivateShop():
    			chat.AppendChat(chat.CHAT_TYPE_INFO, localeinfo.MOVE_ITEM_FAILURE_PRIVATE_SHOP)
    			return
    
    		net.SendItemMovePacket(srcSlotPos, dstSlotPos, srcItemCount)

    PythonNetWorkStreamModule.cpp:

    
    PyObject* netSendItemMovePacket(PyObject* poSelf, PyObject* poArgs)
    {
    	TItemPos Cell;
    	TItemPos ChangeCell;
    	int num;
    
    	switch (PyTuple_Size(poArgs))
    	{
    	case 3:
    		if (!PyTuple_GetInteger(poArgs, 0, &Cell.cell))
    			return Py_BuildException();
    		if (!PyTuple_GetInteger(poArgs, 1, &ChangeCell.cell))
    			return Py_BuildException();
    		if (!PyTuple_GetInteger(poArgs, 2, &num))
    			return Py_BuildException();
    		break;
    	case 5:
    		{
    			if (!PyTuple_GetByte(poArgs, 0, &Cell.window_type))
    				return Py_BuildException();
    			if (!PyTuple_GetInteger(poArgs, 1, &Cell.cell))
    				return Py_BuildException();
    			if (!PyTuple_GetByte(poArgs, 2, &ChangeCell.window_type))
    				return Py_BuildException();
    			if (!PyTuple_GetInteger(poArgs, 3, &ChangeCell.cell))
    				return Py_BuildException();
    			if (!PyTuple_GetInteger(poArgs, 4, &num))
    				return Py_BuildException();
    		}
    		break;
    	default:
    		return Py_BuildException();
    	}
    
    	CPythonNetworkStream& rkNetStream=CPythonNetworkStream::Instance();
    	rkNetStream.SendItemMovePacket(Cell, ChangeCell, (WORD) num);
    	return Py_BuildNone();
    }

     

    PythonNetworkStreamPhaseGameItem.cpp:

    
    bool CPythonNetworkStream::SendItemMovePacket(TItemPos pos, TItemPos change_pos, WORD num)
    {	
    	if (!__CanActMainInstance())
    		return true;
    	
    	if (__IsEquipItemInSlot(pos))
    	{
    		if (CPythonExchange::Instance().isTrading())
    		{
    			if (pos.IsEquipCell() || change_pos.IsEquipCell())
    			{
    				PyCallClassMemberFunc(m_apoPhaseWnd[PHASE_WINDOW_GAME], "BINARY_AppendNotifyMessage", Py_BuildValue("(s)", "CANNOT_EQUIP_EXCHANGE"));
    				return true;
    			}
    		}
    
    		if (CPythonShop::Instance().IsOpen())
    		{
    			if (pos.IsEquipCell() || change_pos.IsEquipCell())
    			{
    				PyCallClassMemberFunc(m_apoPhaseWnd[PHASE_WINDOW_GAME], "BINARY_AppendNotifyMessage", Py_BuildValue("(s)", "CANNOT_EQUIP_SHOP"));
    				return true;
    			}
    		}
    
    		if (__IsPlayerAttacking())
    			return true;
    	}
    
    	__PlayInventoryItemDropSound(pos);
    
    	TPacketCGItemMove	itemMovePacket;
    	itemMovePacket.header = HEADER_CG_ITEM_MOVE;
    	itemMovePacket.pos = pos;
    	itemMovePacket.change_pos = change_pos;
    	itemMovePacket.num = num;
    
    	if (!Send(sizeof(TPacketCGItemMove), &itemMovePacket))
    	{
    		Tracen("SendItemMovePacket Error");
    		return false;
    	}
    
    	return SendSequence();
    }

    game/input_main.cpp:

    
    void CInputMain::ItemMove(LPCHARACTER ch, const char * data)
    {
    	struct command_item_move * pinfo = (struct command_item_move *) data;
    
    	if (ch)
    		ch->MoveItem(pinfo->Cell, pinfo->CellTo, pinfo->count);
    }

     

     

    Do not replace yours with this, use it for compare.

     

    If i were you, i would track down the count with

    Chat.AppendChat(str(itemCount)) #example

    if your problem is created in python. (uiinventory.py)

     

    If not, then i would write the count from binary to the syserr.txt to check there next. (pythonnetworkstreammodule.cpp)

    #define sys_err TraceError
    #define sys_log //(n, format, ...) Tracenf(format, __VA_ARGS__)
    sys_err("Count: %d", num); //num is count if i'm not wrong

    If not, then go the serverside and do the same. (input_main.cpp)

    sys_err("Count in serverside %d", pinfo->count);

     

    With that tracking you can easily find out where it goes wrong.

    Let me know where the count is go wrong and provide your code.

  5. There was a hungarian server what used the 16x16 "4 Mondi" by Luscha.

    It run without any problem, but there wasen't too much player, i say it never went above 300.

     

    The possible negative sides:

    -People use 2 or 3 cores / channel to load balancing. It is not available with only one map.

    -The client should be load a 16*16 map instead of the 4*6 map1. Probably not a problem in 2020, we're not playing in old pentiums anymore :D

    -You probably want programming the realtime .msenv changes since it's only one map

     

    Even after that i say it can be "ok" to run one map.

  6. 4 hours ago, BeauDeCiuda said:

    virus

    This is the hidden content, please

     

    Sanchez's upload does not even contain an exe lol.

    Your got virus probably because of a pirated visual studio, or already infected machine.

     

    If you compile it in a legal vs, it will only produce 2 false positive by noname antivirus. It is because it connects to the internet and downloads files.

    Btw this patcher does not have any "extern" or "lib" so it is 100% open source, you can see every files, only .cs, resx, sln, vcproj,

    these are text files so you can see what's inside them.

    • Metin2 Dev 3
  7. But he is using the basic source, not Marty's, that why he can't install the won system.

    (It's crystal clean in his pictures)

    What are you expecting for him? To contact Ymir?

     

    Edit: Ofc what MrQuin said can be a reason to not help him anymore, but that's an other and a valid reason.

    • Love 1
  8. I still not understand you WeedHex.

    What's more, i think you're not understanding the situation.

     

    That won system is public, not mady by Marty afaik, just made for Marty's source style. (That's why it have g_bChinaIntoxicationCheck  instead of LC_IsNewCIBN)

    That guy is cleary not using Marty's source since he does not have g_bChinaIntoxicationCheck.

     

    So what's the problem actually @WeedHex?

    Please tell because i really not understanding you.

  9. 19 minutes ago, WeedHex said:

    You help people to fix things made by marty because you guys are dumb and don't understand a fuck.

    I'm speaking general, if are not your works/default ymir, you don't have to help. Pay.

    So it was a criticism for me because i helped him saying Marty replaced LC_IsNewCIBN  with g_bChinaIntoxicationCheck so he should use LC_IsNewCIBN?

    Most of the tutorials nowdays made for Marty source by 3rd people too, and helping people who use original source with these little things is not even bad i think.

     

    Otherwise i don't understand what did you wanted to say ?

    Your english is controversal for me, sorry.

  10. Yes. (With empire_whisper: 1 in CONFIG files, 1 is the enabling the convert in whisper, 0 is the understanding the language without anything)

     

    I did test it on some random server (where we need language ring or skill to understand), it did not work anywhere, it gave empty line in every server. 

    It should be a common problem with new files.

     

    I suppose it don't work even in Gayforge's servers but i don't want to download Steam just for it :D

  11. You can remove that g_bChinaIntoxicationCheck completly from your char.cpp.

    Chinese laws require such restriction to prevent addiction.

    Martysama replaced the locale_newcibn (the china server) check with that variable if you wonder why you dont have it.

     

    If you dont want to remove that china check then replace it with:

    if (LC_IsNewCIBN() && amount > 0)

  12. Ymir did not wrote such code, and since the "new pet system" what posted to TurkMMO uses the normal pet system's code as a base, it don't have such feature too.

     

    "i dont wanna use setqf in quest because this lagging the server so hard."

    You either not meaning setqf (but loop_timer) or you're totally wrong.

    Basicly you have to check 1 questflag at login. That is not do any lag at all. If you use a GF quest pack then you already checking ~50questflag at login so +1 is not making any difference.

     

    So if you don't mind using +1 questlag in addition to the other fifty then check sema's answer:

     

     

  13. I don't think anyone will give you a c++ code, it's not 1-2 line.

     

    Alternative solution:

    You can make some shops for the same npc and at quest you open a random one. You can make a timer for it, or eventflag, or even you can use the date time or what meets your needs.

     

    example:

     

    when npcid.click begin

    local x = math.random(1,3)

    if x == 1 then npc.open_shop(1) end

    if x == 2 then npc.open_shop(2) end

    if x == 2 then npc.open_shop(3) end

    end

     

    -------------------------------------------------------------------

     

    Or grab gaya system and change point_gem to point_gold.

    You'll face some problem because it only support 1 slot items for example and the released one at turkmmo is quite bad made.

  14. M2 Download Center

    This is the hidden content, please
    ( Internal )

    So i collected every single GM logo which was used on an official server.

    Spoiler

     

    General:

    163253ymirred.png

    Ymir:

    163253ymirred-ymir.png

    Brasil (Ongame):

    163253ymirred-br.png

    SG (Since ~2015 they are not licensed anymore afaik):

    163253ymirred-sg.png

    Canada (G4Box) (Closed):

    163253ymirred-ca.png

    Hongkong (Closed afaik):

    163253ymirred-hk.png

    Vietnam (Closed):

    163253ymirred-vn.png

    China (Yitian2 - yt2.catv.net) (They are not using this anymore, they use the general):

    163253ymirred-cn.png

     

     

    I think it's all, if i forgot something please tell :)

     

    Download in tga format + their mse: https://drive.google.com/file/d/1yvEqDpiVCK58gkXhG9-NRyup3rJ3E7gv/view?usp=sharing

    • Metin2 Dev 55
    • kekw 1
    • Eyes 2
    • Flame 1
    • Not Good 1
    • Sad 1
    • Cry 1
    • Smile Tear 1
    • Good 14
    • muscle 1
    • Love 2
    • Love 61
  15. kraizy.tgz 40k source

    So if the user does not have language ring (or wind shoe because that is a language ring too lol) and does not have M1 skills of the language,

    he should see a converted language to not understand the other empire's player.

     

    For me, it is only an empty line.

    I'm using locale_hungary (europe) so g_iUseLocale is TRUE.

    				if (g_iUseLocale)
    				{
    					static char s_cChinaTable[][3] = {"ˇň","ŁŁ","Ł¤","ˇů","ˇđ" };
    					int n = number(0, 4);
    					pbText[0] = s_cChinaTable[n][0];
    					pbText[1] = s_cChinaTable[n][1];
    				}

    Whole empire_text_convert.cpp: https://pastebin.com/H6iUGmnp (I think totally untouched from kraizy.tgz)

     

    So basicly i should see these characters: {"ˇň","ŁŁ","Ł¤","ˇů","ˇđ" }

    But i see this: Screenshot-1.png

     

    I usually keep old stuffs so i have an 2089M and 34K serverfile+client too.

    At 2089M converting works, at 34k it does not work like my 40k source. (empty line)

     

    Anyone have an idea?

  16. Those are images.

    Inventory page II not showing because it is under the III and IV inventory page's button image in your case.

     

    So you have to change the Page I and II image to the small one like III and IV, and edit I and II's x and y coordinates to place it in the right.

    (locale_xy.eix-epk inventorywindow.py)

     

    Some tutorial not mentioning such things cause it is straightforward they think.

  17. We do not even know what newpetsystem are u using.

    Probably you're using a turkish premade serverfile, am i right?

     

    Only people using that particular serverfile (or system of you don't use premade serverfile) can help you, what is very very low, especially here in m2dev. 

    People here not really use turkish premade serverfiles.

     

    Give more info. Also keep in mind people here do not speak turkish so we don't even understand the syschat in your video. Need code or translation.

  18. So just to make it clear, i'm looking for a fix, not marty's code!

    Marty fixed almost every error in source, so it would be ridiculous to be not allowed to ask a basic error just because Marty fixed in his source.

     

    -----------------------

     

    Solved, i got help in private. Ymir used wrong packet name in some places at db for myshop_pricelist.

    It is only fixable in one way so i'm not gonna share the fix, marty's fix is surely the same and i don't want to get in trouble...

    So if anyone want to fix it, check the packet names everywhere in myshop_pricelist and swap it to the correct one.

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