Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 10/18/19 in all areas

  1. M2 Download Center Download Here ( Internal ) Download Here ( GitHub ) Prepared src packages: *Granny 2.11.8 *libjpeg-9a *Python-2.7 *Crypto++ 8.4.0 *DevIL-1.6.5 *lzo-2.10 Archive password: black
    2 points
  2. Hello Today I want to share with all of you a little thing. All times when you are trying to open your safebox, it's requesting the password, isn't it? But for what? I modified to limit these requests to one input per login. Of course if you warp or change character, you need to retype your password again. But with extra modifications you can do it to store the password until you close the client, but I don't recommend this. So, first go to the uiSafeBox.py file and paste this line into the __init__ method of the PasswordDialog class, with taking care of the tabulators: self.lastPassword = "" This variable will store your last entered password. Then replace the Accept method of the same class with this: (take a look for the syntax, modulename, and true/false!) def OnAccept(self): self.lastPassword = str(self.passwordValue.GetText()) m2net.SendChatPacket(self.sendMessage + self.lastPassword) self.CloseDialog() return True When you accept the password input dialog, the entered password will be saved, if it's correct if it isn't as well. Don't worry about it, it will be reset if you entered wrong password. The next step is that to paste these new functions into the same class. def InitSafeboxPassword(self): self.lastPassword = "" def GetSafeboxPwd(self): return self.lastPassword As you can see, here is a function which will reset the entered password . With this, the file is done. Open interfaceModule.py and serach this line: ## Safebox then paste this function below: def InitSafeboxPassword(self): self.dlgPassword.InitSafeboxPassword() Then replace the AskSafeboxPassword and AskMallPassword functions with these: def AskSafeboxPassword(self): if self.wndSafebox.IsShow(): return if self.dlgPassword.IsShow(): self.dlgPassword.CloseDialog() return self.dlgPassword.SetSendMessage("/safebox_password ") if self.dlgPassword.GetSafeboxPwd() != "": self.dlgPassword.OnAccept() return self.dlgPassword.SetTitle(localeInfo.PASSWORD_TITLE) self.dlgPassword.ShowDialog() def AskMallPassword(self): if self.wndMall.IsShow(): return if self.dlgPassword.IsShow(): self.dlgPassword.CloseDialog() return self.dlgPassword.SetSendMessage("/mall_password ") if self.dlgPassword.GetSafeboxPwd() != "": self.dlgPassword.OnAccept() return self.dlgPassword.SetTitle(localeInfo.MALL_PASSWORD_TITLE) self.dlgPassword.ShowDialog() With these functions, if the last entered password is correct, the storages will open automatically with the last entered password. The file is done. Next, open your game.py and search this function: OnSafeBoxError and extend it with this line: self.interface.InitSafeboxPassword() So, as you can see this is the answer from the server to entered wrong password and this function will reset the last entered password as well . That's all, I hope you like it, and have fun. Edit.: Fix for change password. game/src/input_db.cpp void CInputDB::SafeboxChangePasswordAnswer(LPDESC d, const char* c_pData) { //[...] d->GetCharacter()->ChatPacket(CHAT_TYPE_COMMAND, "safebox_change_passwd %d", p->flag); // to the bottom of the function } client/UserInterface/PythonNetworkStreamCommand.cpp void CPythonNetworkStream::ServerCommand(char * c_szCommand) { // [...] const char * szCmd = TokenVector[0].c_str(); if (!strcmpi(szCmd, "quit")) { // [...] } else if (!strcmpi(szCmd, "BettingMoney")) { // [...] } //Add between the "else if" cases: else if (!strcmpi(szCmd, "safebox_change_passwd")) { if (2 != TokenVector.size()) { TraceError("CPythonNetworkStream::ServerCommand(c_szCommand=%s) - Strange Parameter Count : %d", c_szCommand, TokenVector.size()); return; } const int iFlag = atoi(TokenVector[1].c_str()); PyCallClassMemberFunc(m_apoPhaseWnd[PHASE_WINDOW_GAME], "RecvSafeboxPasswordChangeAnswer", Py_BuildValue("(i)", iFlag)); } else if (!strcmpi(szCmd, "gift")) { // [...] } // [...] } client/root/game.py # below of CommandCloseSafebox function add: def RecvSafeboxPasswordChangeAnswer(self, flag): self.interface.RecvSafeboxPasswordChangeAnswer(flag) client/root/interfaceModule.py # Below of CommandCloseSafebox function add: def RecvSafeboxPasswordChangeAnswer(self, flag): if flag: self.dlgPassword.SetSafeboxPwd(str(self.wndSafebox.dlgChangePassword.GetNewPasswordText())) client/root/uiSafeBox.py # change the OnAccept function of the PasswordDialog class with this: def OnAccept(self): if self.lastPassword == "" and "" != str(self.passwordValue.GetText()): self.lastPassword = str(self.passwordValue.GetText()) net.SendChatPacket(self.sendMessage + self.lastPassword) self.CloseDialog() return True # add this new function to the PasswordDialog class: def SetSafeboxPwd(self, pwd): self.lastPassword=pwd # add this line into the ChangePasswordDialog.__init__ function: self.__newPassword = "" # add this line into the ChangePasswordDialog.Open function: self.__newPassword = "" # add this function to the ChangePasswordDialog class: def GetNewPasswordText(self): return self.__newPassword # add the following line into the ChangePasswordDialog.OnAccept function (between the password check and the SendChatPacket): # return True self.__newPassword = newPasswordText #m2net.SendChatPacket("/safebox_change_password %s %s" % (oldPasswordText, newPasswordText)) Edit: fix of flooding: moving the saving method of the password from the OnAccept function to a separated one and calling it when the Safebox opens, this will be enough I guess. client/root/uiSafeBox.py # add the following function to the PasswordDialog class: def SavePassword(self): if self.lastPassword == "" and "" != str(self.passwordValue.GetText()): self.lastPassword = str(self.passwordValue.GetText()) # make the changes on the function in the PasswordDialog class def OnAccept(self): net.SendChatPacket(self.sendMessage + (self.lastPassword if self.lastPassword != "" else self.passwordValue.GetText())) self.CloseDialog() return True client/root/interfaceModule.py # add the following line into the beginning of the OpenSafeboxWindow and the OpenMallWindow function self.dlgPassword.SavePassword()
    1 point
  3. M2 Download Center Download Here ( Internal ) Hey guys, Today I'm releasing the tutorial for Boss Effect Over Head. Picture of system: Download link: Pastebin tutorial (only): Special thanks to: @Syreldar @M.Sorin for some functions which I used in the tutorial. I believe someone will use that Have a nice day/night! Sincerely, ReFresh
    1 point
  4. M2 Download Center Download Here ( Internal ) Hi guys. First of all, I also know this system is public already, but I was boring, so I had to reverse something, so here it is: Quiver System.7z If you have extra systems which might ignore the quivers, you must to extend them by yourself. Just couple of them from the official: acce, costume bonus transfer, change look, skillbook combination, sealbind and so on. Anything is wrong in the guide or missing something let me know, hit a comment below.
    1 point
  5. M2 Download Center Download Here ( Internal ) Hello, there is more than 900 new icons from Age of Wulin. - Format - PNG - Size - 90x90 Some icons [Hidden Content] Have fun
    1 point
  6. Hi, I receive the gold from the mob directly in my "inventory", but sometimes mob and boss drop extra gold to the ground, i would like to know how to remove all the extra gold they can drop. Thank you this is just an example
    1 point
  7. It is working fine for me, check your files.
    1 point
  8. Char_item.cpp Find for: item->AddToGround (GetMapIndex(), GetXYZ()); Before add: if (GetGMLevel() > GM_PLAYER) { ChatPacket(CHAT_TYPE_INFO, "Trying to fuck from ground."); return; }
    1 point
  9. @VegaS™ sometimes i cannot understand why u spend so much time to write the comments that nobody reads ?
    1 point
  10. I found in source what we needed. In char_item.cpp remove: if (!item && bCell == WEAR_WEAPON) { if (IsAffectFlag(AFF_GWIGUM)) RemoveAffect(SKILL_GWIGEOM); if (IsAffectFlag(AFF_GEOMGYEONG)) RemoveAffect(SKILL_GEOMKYUNG); } Important fix. Add in bool CHARACTER::CanUnequipNow if (item->GetType() == ITEM_WEAPON) { if (IsAffectFlag(AFF_GWIGUM)) RemoveAffect(SKILL_GWIGEOM); if (IsAffectFlag(AFF_GEOMGYEONG)) RemoveAffect(SKILL_GEOMKYUNG); }
    1 point
  11. Dear metin2.dev community, such a text, as it will follow here now, is absolutely not my strength. So please excuse some shortcomings. It has been more than three years since I joined the team as an administrator. In these three years a lot has happened. Be it the changes that we have made to the forum since then, or the developments that Gameforge has made regarding the private servers, or your participation in the Metin2 underground (especially this community). I'd like to take this opportunity to thank all of you who, whether on metin2.dev or any other forum, have helped to advance the underground. You are great people, keep it that way! I'd also like to thank everyone I've dealt with in the past and who've worked hard to create something good out of all this nonsense, no matter if it were own projects or the participation in a common cause like for example metin2.dev But now is the time for me to move on. After a lot of years passed by, got to know a lot of people and gaining experience in different fields i quit metin2. There are still some things planned for the future on metin2.dev, which hopefully will be released in the future too. So be curious about everything that's coming. A first corresponding step has already been taken with the Discord. For everything else, @DevChuckNorris and @Raylee will serve you with their best, as always. Maybe we run into each other from time to time. Until then, with sincere thanks, pollux
    0 points
×
×
  • 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.