Jump to content

Search the Community

Showing results for tags 'python'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Metin2 Dev
    • Announcements
  • Community
    • Member Representations
    • Off Topic
  • Miscellaneous
    • Metin2
    • Showcase
    • File Requests
    • Community Support - Questions & Answers
    • Paid Support / Searching / Recruiting
  • Metin2 Development
  • Metin2 Development
    • Basic Tutorials / Beginners
    • Guides & HowTo
    • Binaries
    • Programming & Development
    • Web Development & Scripts / Systems
    • Tools & Programs
    • Maps
    • Quests
    • 3D Models
    • 2D Graphics
    • Operating Systems
    • Miscellaneous
  • Private Servers
    • Private Servers
  • Uncategorized
    • Drafts
    • Trash
    • Archive
    • Temporary
    • Metin2 Download

Product Groups

  • Small Advertisement
  • Large Advertisement
  • Advertising

Categories

  • Third Party - Providers Directory

Categories

  • Overview
  • Pages
    • Overview
    • File Formats
    • Network
    • Extensions

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Pillory


Marketplace


Game Server


Country


Nationality


Github


Gitlab


Discord


Skype


Website

  1. M2 Download Center Download Here ( Internal ) Download Here ( GitHub )
  2. Hi, I don't know if you've noticed, but every time you open a shop or want to add a stone to an item, the window inexplicably opens somewhere on the right at the top near the inventory. It bothered me for quite a while, so I looked into the code, and the fix is very easy. I'm sharing it with you, and I would appreciate it if you let me know if any other window does the same, as I've only noticed these two so far. Open uiattachmetin.py and search in def Open(self, metinItemPos, targetItemPos): self.UpdateDialog() Add under: self.SetCenterPosition() ############################ Open uishop.py and search in def Open(self, vid): self.Refresh() Add under: self.SetCenterPosition() Thats all :D
  3. Hello. I was looking inside the official python files and I found a little fix for this: Let me explain a bit the problem. If you leave open the inventory/dragon soul inventory/expanded taskbar or the affected objects and then you are using quest for teleportation, the windows what you left open will be closed because of the quest and when the quest executed those windows what you left open before would be opened again, but the warp is killing this procedure and that happens what you can see in the video, the windows are there but you cannot see them. Btw you can close them with escape key. The fix is coming from webzen: Simple, just execute a .Hide() function before the Destroy function has been called on that object what is stuck on the main window after teleport and that's it. For example: interfaceModule.py -> Interface class -> Close function: if self.wndInventory: self.wndInventory.Hide()#fix self.wndInventory.Destroy() if self.wndDragonSoul: self.wndDragonSoul.Hide()#fix self.wndDragonSoul.Destroy()
  4. Reversed from 22.2.7.0 Official Binary Client part is from 2018 Official Root [Hidden Content] [Hidden Content]
  5. Hello, I've added strong against metins/bosses, and now, I am trying to add em to item_attr. The goal is to make what is a bonus that I can add manually to an item, to be "addable" by add/change bonus items, if that makes sense? Now I do not know what that implies, any ideas/suggestions would be much apreciated! PS. I did try to add a new row in the table with APPLY_ATTBONUS_METIN, no luck tho. Thanks Tutorial by Owsap Server Source We can do the MySQL part now since we have finished with the server part. MySQL Now let's move on to the Client Source. Client Source Let's not forget our special tool, DumpProto. DumpProto Last but not least your client needs to read the new bonus type. Client Root And finally, your bonus needs a name. Client Locale ⚠ Following the order of the points and apply types are very important, make sure every modification is in order since an incorent order may read another bonus.
  6. Download Other Mirros Download Here (GitHub) Download Here (Mega) Hey M2Dev, I want to share something small but visually appreciated by players that are paying attention to details. What I'm sharing with you today will solve the issue of item tooltips with large strings, these strings overflow the width of the tooltip causing the text to hang out of the edge, especially when metin stones are attached to your weapon or armor. BEFORE PREVIEW AFTER PREVIEW .
  7. A fool came and gave you no peace and you blocked this fool. Let's see what will happen. additional: while coding the system i fixed a few errors related to mesenge_manager and made adjustments and p2p works. -> You can block or delete a player from the list by typing the player's name from the Messenger panel. There is also a block button inside the target buttons. M2 Download Center Download Here ( Internal ) Download Here ( GitHub )
  8. M2 Download Center Download Here ( Internal ) This is a revised version of an old thread. Following this How-To, you will have a better customizable solution for the aspect of your quests. You will be able to choice amongst: quest icon, text color, blink effect (like whisper buttons) How To You just need to replace 2 little things: I) In interfaceModule.py, replace BINARY_RecvQuest with: [Hidden Content] II) In questlib.lua, replace send_letter_ex with: [Hidden Content] Explanation: -the 2° argument of send_letter_ex will support multiple parameters: -green|blue|purple|golden|fucsia|aqua and so on (you can add them in BINARY_RecvQuest by adding new colors 0xFF+#HEX; Color Picker Online) -blink (the quest will flash like the whisper messages) -ex (a dummy tag to separate it from "info" and "item") -the 3° argument is the name of the icon to choose, which the current availables are: -scroll_open.tga -scroll_open_green.tga -scroll_open_blue.tga -scroll_open_purple.tga -scroll_open_golden.tga Examples: send_letter_ex(localeInfo.LanguageOptionTitle, "green,blink,ex", "scroll_open_green.tga") send_letter_ex(localeInfo.LanguageOptionTitle, "blue,blink,ex", "scroll_open_blue.tga") send_letter_ex(localeInfo.LanguageOptionTitle, "purple,blink,ex", "scroll_open_purple.tga") send_letter_ex(localeInfo.LanguageOptionTitle, "golden,blink,ex", "scroll_open_golden.tga") send_letter_ex(localeInfo.LanguageOptionTitle, "golden,blink,ex", "scroll_open.tga") Note: As you can imagine, the only limitation is that the color in N won't appear. (it will require additional code and work, so just forget it) Download: Check the attachment (colored-quest-scrolls-v2-res.7z) and add metin2_patch_new_questicon in your client.
  9. M2 Download Center Download Here ( Advance Refine Systems ) Download Here ( Cheque System ) Download Here ( Soul Bind System ) Hello everyone ! I've been away from metin2 for about 6 months and i've get back from less then a month and made thoes systems , i've start selling them but i didn't sell it to anyone and i got bored from metin2 again so i'm going to release it and go off from metin2 for ever . about the Advance Refine System here some info: so download and have fun [Hidden Content]
  10. M2 Download Center Download Here ( Internal ) Download Here ( GitHub )
  11. M2 Download Center Download Here ( Internal ) - Searching Glass, Allows the arrow mark appearing on the private shop where the item you select in the search results and guides for players to call the selling items easier access. You must be the same on the map with the seller. Default time limit; 1 Week - Trading Glass, Without going to the private shop on the same map that allows you can buy directly. Default time limit; 1 Week - Trading Glass+, Without going to the private shop you can buy directly works on any map. Default time limit; 2 Week - Common features, You can be viewed right from cheap to expensive price of items in the private shops, you can see the features of items When you move your mouse over the item you are looking for. Level, item name and bonuses you can search on the basis of price. HowTo tutorial exists in archive, Warning: It doesn't works with published shoulder sash system. You need upgrade attr type, value amounts. Download: [Hidden Content] It doesn't looks like %100 official but it's works, My last shared and my last working in metin2.
  12. Download Alternative download links → Mega Hello Metin2 Dev. I'm here to present a Portable Shop System. How does it work? Players get a panel when click F7 with several options. This system exists to make players able to buy items while farming. In case of any problem, contact me or write here. With best regards, Doose.
  13. M2 Download Center Download Here ( Internal )
  14. M2 Download Center Download Here ( Internal ) Hi, I don't think I have to tell much about this. It'll look like the official one, some code is c&p from the official root files. Most of the own written code is NOT like the offical one. I added a new python module ("renderTarget"), so you don't need methods which officials use, like this: "playerm2g2.MyShopDecoShow( True )" You are able to display more than one render target at the same time. If you want to know more, take a look at the code. If there are any bugs, just message me. Download: [Hidden Content] Password: Cxl.Services
  15. [Hidden Content] [Hidden Content] After using it in almost all of the modern UIs they made, they finally decided to turn it into a class.
  16. [Hidden Content] [Hidden Content] Reversed from 22.2.7.0 Client part is from 2018 official root List of functions: Be careful about IsDIsable, it's actually IsEnable. They use like this:
  17. M2 Download Center Download Here ( Internal ) You need to install this first: [Hidden Content] You can use it in guild wars, tournaments etc.
  18. Hello. As you know, the LibJPEG library in Metin2 is only useful for taking screenshots. Other than that, it doesn't have any duties. Those who have Directx9 and want to take better quality screenshots with this method can follow this guide carefully. Those who use Directx8 can update the code I will give according to Directx8 and try it, I did not have the chance to try it. Make sure you are determined before following the steps here. Because as a result of these operations, you will no longer have the libjpeg library, and the screenshot files will reach larger sizes than the jpg file, depending on the quality. (between 3-8MB) The explanation will be a bit complicated, but if you follow each process in order, you will not have any problems. If you still have a problem, you can report it below. First, let's get rid of libjpeg: -> Enter the Client src/extern/lib folder and delete the .lib files whose file name starts with libjpeg... -> Enter the Client src/EterLib folder and delete the JpegFile.cpp & JpegFile.h files. Open the EterLib project in Visual Studio in the same way, select these two files and remove them. -> Open the client src/EterPythonLib/PythonGraphic.cpp file and remove the following include line and functions: #include "../eterLib/JpegFile.h" --------------------------------- void GenScreenShotTag(const char* src, DWORD crc32, char* leaf, size_t leafLen){ const char* p = src; const char* n = p; while (n = strchr(p, '\\')) p = n + 1; _snprintf(leaf, leafLen, "YMIR_METIN2:%s:0x%.8x", p, crc32); } bool CPythonGraphic::SaveJPEG(const char* pszFileName, LPBYTE pbyBuffer, UINT uWidth, UINT uHeight) { return jpeg_save(pbyBuffer, uWidth, uHeight, 100, pszFileName) != 0; } -> Where you delete these, you will see this function: bool CPythonGraphic::SaveScreenShot(const char* c_pszFileName) { -> Replace this function completely like this: bool CPythonGraphic::SaveScreenShot() { LPDIRECT3DSURFACE9 lpSurface = nullptr; D3DSURFACE_DESC stSurfaceDesc = {}; uint32_t uWidth = stSurfaceDesc.Width; uint32_t uHeight = stSurfaceDesc.Height; ms_lpd3dDevice->CreateOffscreenPlainSurface(uWidth, uHeight, D3DFMT_A8R8G8B8, D3DPOOL_SYSTEMMEM, &lpSurface, NULL); if (SUCCEEDED(ms_lpd3dDevice->GetBackBuffer(0, 0, D3DBACKBUFFER_TYPE_MONO, &lpSurface))) { if (!CreateDirectory("screenshot", NULL) && ERROR_ALREADY_EXISTS != GetLastError()) //yoksa oluştur return false; SYSTEMTIME st; GetSystemTime(&st); char szFileName[MAX_PATH]; sprintf_s(szFileName, "screenshot/screenshot_%04d%02d%02d_%02d%02d%02d.bmp", // eşsiz st.wYear, st.wMonth, st.wDay, st.wHour, st.wMinute, st.wSecond); D3DXSaveSurfaceToFile(szFileName, D3DXIFF_BMP, lpSurface, NULL, NULL); } else TraceError("CPythonGraphic::SaveScreenShot() - ScreenShot Basarisiz!"); // yok et if (lpSurface) { lpSurface->Release(); lpSurface = nullptr; } return true; } -> Then remove the following from the PythonGraphic.h file: bool SaveJPEG(const char* pszFileName, LPBYTE pbyBuffer, UINT uWidth, UINT uHeight); -> In the same file there will be: bool SaveScreenShot(const char* szFileName); -> Update this to: bool SaveScreenShot(); -> Open PythonGraphicModule.cpp and delete this PyObject* grpSaveScreenShot(PyObject* poSelf, PyObject* poArgs) { struct tm* tmNow; time_t ct; ct = time(0); tmNow = localtime(&ct); char szPath[MAX_PATH + 256]; SHGetSpecialFolderPath(NULL, szPath, CSIDL_PERSONAL, TRUE); //GetTempPath(); strcat(szPath, "\\METIN2\\"); if (-1 == _access(szPath, 0)) if (!CreateDirectory(szPath, NULL)) { TraceError("Failed to create directory [%s]\n", szPath); return Py_BuildValue("(is)", FALSE, ""); } sprintf(szPath + strlen(szPath), "%02d%02d_%02d%02d%02d.jpg", tmNow->tm_mon + 1, tmNow->tm_mday, tmNow->tm_hour, tmNow->tm_min, tmNow->tm_sec); BOOL bResult = CPythonGraphic::Instance().SaveScreenShot(szPath); return Py_BuildValue("(is)", bResult, szPath); } -> and delete this: { "SaveScreenShot", grpSaveScreenShot, METH_VARARGS }, -> Find the following function in the same file PyObject* grpSaveScreenShotToPath(PyObject* poSelf, PyObject* poArgs) { -> Replace this function completely with the code I gave below. PyObject* grpSaveScreenShotToPath(PyObject* poSelf, PyObject* poArgs) { CPythonGraphic::Instance().SaveScreenShot(); return Py_BuildNone(); } -> We are done with the client src. Now open root/game.py and find this function: def SaveScreen(self): print "save screen" # SCREENSHOT_CWDSAVE if SCREENSHOT_CWDSAVE: if not os.path.exists(os.getcwd()+os.sep+"screenshot"): os.mkdir(os.getcwd()+os.sep+"screenshot") (succeeded, name) = grp.SaveScreenShotToPath(os.getcwd()+os.sep+"screenshot"+os.sep) elif SCREENSHOT_DIR: (succeeded, name) = grp.SaveScreenShot(SCREENSHOT_DIR) else: (succeeded, name) = grp.SaveScreenShot() # END_OF_SCREENSHOT_CWDSAVE if succeeded: pass """ chat.AppendChat(chat.CHAT_TYPE_INFO, name + localeInfo.SCREENSHOT_SAVE1) chat.AppendChat(chat.CHAT_TYPE_INFO, localeInfo.SCREENSHOT_SAVE2) """ else: chat.AppendChat(chat.CHAT_TYPE_INFO, localeInfo.SCREENSHOT_SAVE_FAILURE) -> ..and update it like this: def SaveScreen(self): grp.SaveScreenShotToPath() You can also search and delete the variables in the original Python code above from root. I'm sorry for my bad english.
  19. Download Merry Christmas to everyone, I saw that here is not the best option, so I want to offer you the official system, it is not a complicated system, but maybe someone needs it.
  20. [Hidden Content] [Hidden Content] [Hidden Content] I used ITEM_USE instead of ITEM_GACHA. It was shared on the forum, you can look there and change it. You must add this: Let me know if there is a problem.
  21. M2 Download Center Download Here ( Internal ) Download Here ( GitHub )
  22. [Hidden Content] [Hidden Content] Preview[OFF-ON]: Enable:
  23. M2 Download Center Download Here ( Internal ) Description: [Hidden Content] // 1. PythonPlayerInput.cpp // 1.0. Search: void CPythonPlayer::PickCloseItem() { ... } // 1.0. Add after: void CPythonPlayer::PickCloseItemVector() { CInstanceBase * pkInstMain = NEW_GetMainActorPtr(); if (!pkInstMain) return; TPixelPosition kPPosMain; pkInstMain->NEW_GetPixelPosition(&kPPosMain); std::vector<DWORD> itemVidList; CPythonItem& rkItem=CPythonItem::Instance(); if (!rkItem.GetCloseItemVector(pkInstMain->GetNameString(), kPPosMain, itemVidList)) return; if(itemVidList.empty()) return; for(int i = 0; i < itemVidList.size(); i++) SendClickItemPacket(itemVidList[i]); } // 2. PythonItem.cpp // 2.0. Search: bool CPythonItem::GetCloseItem (const std::string& myName, const TPixelPosition& c_rPixelPosition, DWORD* pdwItemID, DWORD dwDistance) { .... } // 2.0. Add after: bool CPythonItem::GetCloseItemVector(const std::string& myName, const TPixelPosition& c_rPixelPosition, std::vector<DWORD>& itemVidList) { DWORD dwCloseItemDistance = 1000 * 1000; TGroundItemInstanceMap::iterator i; for (i = m_GroundItemInstanceMap.begin(); i != m_GroundItemInstanceMap.end(); ++i) { TGroundItemInstance * pInstance = i->second; DWORD dwxDistance = DWORD(c_rPixelPosition.x - pInstance->v3EndPosition.x); DWORD dwyDistance = DWORD(c_rPixelPosition.y - (-pInstance->v3EndPosition.y)); DWORD dwDistance = DWORD(dwxDistance * dwxDistance + dwyDistance * dwyDistance); if (dwDistance < dwCloseItemDistance && (pInstance->stOwnership == "" || pInstance->stOwnership == myName)) { itemVidList.push_back(i->first); } } return true; } // 3. PythonItem.h // 3.0. Search: bool GetCloseMoney(const TPixelPosition & c_rPixelPosition, DWORD* dwItemID, DWORD dwDistance=300); // 3.0. Adauga sub: bool GetCloseItemVector(const std::string& myName, const TPixelPosition& c_rPixelPosition, std::vector<DWORD>& itemVidList); // 4. PythonPlayer.cpp // 4.0. Search and replace: void CPythonPlayer::SendClickItemPacket(DWORD dwIID) { if (IsObserverMode()) return; const char * c_szOwnerName; if (!CPythonItem::Instance().GetOwnership(dwIID, &c_szOwnerName)) return; if (strlen(c_szOwnerName) > 0) if (0 != strcmp(c_szOwnerName, GetName())) { CItemData * pItemData; if (!CItemManager::Instance().GetItemDataPointer(CPythonItem::Instance().GetVirtualNumberOfGroundItem(dwIID), &pItemData)) { Tracenf("CPythonPlayer::SendClickItemPacket(dwIID=%d) : Non-exist item.", dwIID); return; } if (!IsPartyMemberByName(c_szOwnerName) || pItemData->IsAntiFlag(CItemData::ITEM_ANTIFLAG_DROP | CItemData::ITEM_ANTIFLAG_GIVE)) { PyCallClassMemberFunc(m_ppyGameWindow, "OnCannotPickItem", Py_BuildValue("()")); return; } } CPythonNetworkStream& rkNetStream=CPythonNetworkStream::Instance(); rkNetStream.SendItemPickUpPacket(dwIID); } // 5. PythonPlayerModule.cpp // 5.0. Search: PyObject * playerPickCloseItem(PyObject* poSelf, PyObject* poArgs) { CPythonPlayer::Instance().PickCloseItem(); return Py_BuildNone(); } // 5.0. Add after: PyObject * playerPickCloseItemVector(PyObject* poSelf, PyObject* poArgs) { CPythonPlayer::Instance().PickCloseItemVector(); return Py_BuildNone(); } // 5.1. Search: { "PickCloseItem", playerPickCloseItem, METH_VARARGS }, // 5.1.Add after:: { "PickCloseItemVector", playerPickCloseItemVector, METH_VARARGS }, // 6. PythonPlayer,h // 6.0. Search: void PickCloseItem(); // 6.0. Add after: void PickCloseItemVector(); // 7. game.py // 7. Search: player.PickCloseItem() // 7. Replace with: player.PickCloseItemVector() // You can make option for fast pickup or not.
  24. M2 Download Center Download Here ( Internal ) [Hidden Content]- Images & Video: Some Informations From Black: If you have a problem, you can send me a private message. You know me, I reply to all private messages
×
×
  • 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.