Jump to content

Search the Community

Showing results for tags 'c++'.

  • 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 ( Github Backup ) - Download Here ( GitHub ) Download Here ( VM 9.2 ) or Download Here ( VM 12 ) Use this source: [Hidden Content] or [Hidden Content]
  2. This hwid ban works in a quite simple way and I'm pretty sure that this isn't the best way to get HWID from a computer, but nonetheless it works It was released a long time ago by someone on this forum, but that solution was awful. So I reimplemented it only in c++ without the need of an external exe and to add python code. Client File: packet.h Find typedef struct command_login3 { BYTE header; char name[ID_MAX_NUM + 1]; char pwd[PASS_MAX_NUM + 1]; DWORD adwClientKey[4]; } TPacketCGLogin3; Replace with typedef struct command_login3 { BYTE header; char name[ID_MAX_NUM + 1]; char pwd[PASS_MAX_NUM + 1]; DWORD adwClientKey[4]; char hwid[255]; // <----- } TPacketCGLogin3; File: AccountConnector.cpp Find TPacketCGLogin3 LoginPacket; LoginPacket.header = HEADER_CG_LOGIN3; strncpy(LoginPacket.name, m_strID.c_str(), ID_MAX_NUM); strncpy(LoginPacket.pwd, m_strPassword.c_str(), PASS_MAX_NUM); LoginPacket.name[ID_MAX_NUM] = '\0'; LoginPacket.pwd[PASS_MAX_NUM] = '\0'; Add under HW_PROFILE_INFO hwProfileInfo; GetCurrentHwProfile(&hwProfileInfo); Tracef("hwid %s\n", hwProfileInfo.szHwProfileGuid); strncpy(LoginPacket.hwid, hwProfileInfo.szHwProfileGuid, 254); Server File: packet.h Find typedef struct command_login3 { BYTE header; char login[LOGIN_MAX_LEN + 1]; char passwd[PASSWD_MAX_LEN + 1]; DWORD adwClientKey[4]; } TPacketCGLogin3; Replace with typedef struct command_login3 { BYTE header; char login[LOGIN_MAX_LEN + 1]; char passwd[PASSWD_MAX_LEN + 1]; DWORD adwClientKey[4]; char hwid[255]; } TPacketCGLogin3; File: input_auth.cpp Find char login[LOGIN_MAX_LEN + 1]; trim_and_lower(pinfo->login, login, sizeof(login)); char passwd[PASSWD_MAX_LEN + 1]; strlcpy(passwd, pinfo->passwd, sizeof(passwd)); add under char hwid[255]; strlcpy(hwid, pinfo->hwid, sizeof(hwid)); Find char szPasswd[PASSWD_MAX_LEN * 2 + 1]; DBManager::instance().EscapeString(szPasswd, sizeof(szPasswd), passwd, strlen(passwd)); char szLogin[LOGIN_MAX_LEN * 2 + 1]; DBManager::instance().EscapeString(szLogin, sizeof(szLogin), login, strlen(login)); Add under char szHWID[255]; DBManager::instance().EscapeString(szHWID, sizeof(szHWID), hwid, strlen(hwid)); // ENABLE_HWID_BAN // update client hwid // DBManager::instance().DirectQuery("UPDATE account.account SET hwid = '%s' WHERE login = '%s'", szHWID, szLogin); std::auto_ptr<SQLMsg> pUpdateMsg("UPDATE account.account SET hwid = '%s' WHERE login = '%s'", szHWID, szLogin); // check if client hwid is banned std::auto_ptr<SQLMsg> pMsg(DBManager::instance().DirectQuery("SELECT * FROM account.hwid_ban WHERE hwid = '%s'", szHWID)); if (pMsg->Get()->uiNumRows > 0) { LoginFailure(d, "BLOCK"); printf("Account %s HWID ban - tried to login\n", szLogin); sys_log(0, "Account %s HWID ban - tried to login\n", szLogin); return; } // end HWID BAN Database Add a new column called "hwid" (varchar 255) to table account. Create a new table in the database "account" and call it hwid_ban. Inside this table put a column called "hwid".
  3. 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
  4. [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.
  5. [Hidden Content] [Hidden Content] The area(O, X) where those who answer correctly will shine
  6. [Hidden Content] [Hidden Content] Item icons will appear in the hyperlink tooltip OLD: NOW:
  7. M2 Download Center Download Here ( Internal ) Download Here ( GitHub ) Cheque system full ~ like official The tutorial was remade and uploaded to github Monetary unit: Won - Not compatible with long long gold - Max won 999 (like official) - Added support for OfflineShop(great) Best regards.
  8. Open db/ClientManagerBoot.cpp bool CClientManager::InitializeLandTable() { using namespace building; under this add CDBManager::instance().DirectQuery( "update land " "INNER JOIN guild ON land.guild_id = guild.id " "INNER JOIN player ON guild.`master` = player.id " "set guild_id=0 " "where guild_id > 0 and " "DATE_SUB(NOW(),INTERVAL 21 DAY) > last_play; " ); CDBManager::instance().DirectQuery( "DELETE object " "FROM object " "INNER JOIN land ON land.id = object.land_id " "WHERE land.guild_id=0; " ); Extracted from Inception source.
  9. M2 Download Center Download Here ( Internal ) Download Here ( GitHub )
  10. M2 Download Center Download Here ( Internal ) InstanceBase.h find NAMECOLOR_WAYPOINT, add NAMECOLOR_METIN, PythonCharacterManagerModule.cpp find PyModule_AddIntConstant(poModule, "NAMECOLOR_MOB", CInstanceBase::NAMECOLOR_NORMAL_MOB); add PyModule_AddIntConstant(poModule, "NAMECOLOR_METIN", CInstanceBase::NAMECOLOR_METIN); InstanceBaseEffect.cpp find else if (IsPoly()) { return NAMECOLOR_MOB; } add else if (IsStone()) { return NAMECOLOR_METIN; } PythonMiniMap.cpp find m_NPCPositionVector.clear(); add m_MetinPositionVector.clear(); find else if (pkInstEach->IsNPC()) { aMarkPosition.m_fX = ( m_fWidth - (float)m_WhiteMark.GetWidth() ) / 2.0f + fDistanceFromCenterX + m_fScreenX; aMarkPosition.m_fY = ( m_fHeight - (float)m_WhiteMark.GetHeight() ) / 2.0f + fDistanceFromCenterY + m_fScreenY; m_NPCPositionVector.push_back(aMarkPosition); } add else if (pkInstEach->IsStone()) { aMarkPosition.m_fX = ( m_fWidth - (float)m_WhiteMark.GetWidth() ) / 2.0f + fDistanceFromCenterX + m_fScreenX; aMarkPosition.m_fY = ( m_fHeight - (float)m_WhiteMark.GetHeight() ) / 2.0f + fDistanceFromCenterY + m_fScreenY; m_MetinPositionVector.push_back(aMarkPosition); } find // NPC STATEMANAGER.SetRenderState(D3DRS_TEXTUREFACTOR, CInstanceBase::GetIndexedNameColor(CInstanceBase::NAMECOLOR_NPC)); aIterator = m_NPCPositionVector.begin(); while (aIterator != m_NPCPositionVector.end()) { TMarkPosition & rPosition = *aIterator; m_WhiteMark.SetPosition(rPosition.m_fX, rPosition.m_fY); m_WhiteMark.Render(); ++aIterator; } add // Metin STATEMANAGER.SetRenderState(D3DRS_TEXTUREFACTOR, CInstanceBase::GetIndexedNameColor(CInstanceBase::NAMECOLOR_METIN)); aIterator = m_MetinPositionVector.begin(); while (aIterator != m_MetinPositionVector.end()) { TMarkPosition & rPosition = *aIterator; m_WhiteMark.SetPosition(rPosition.m_fX, rPosition.m_fY); m_WhiteMark.Render(); ++aIterator; } PythonMiniMap.h find TInstanceMarkPositionVector m_NPCPositionVector; add TInstanceMarkPositionVector m_MetinPositionVector; root/colorinfo.py find CHR_NAME_RGB_WARP = (136, 218, 241) add CHR_NAME_RGB_METIN = (240, 255, 255) You can select another color from here root/introloading.py find chrmgr.NAMECOLOR_WAYPOINT : colorInfo.CHR_NAME_RGB_WAYPOINT, add chrmgr.NAMECOLOR_METIN : colorInfo.CHR_NAME_RGB_METIN,
  11. [Hidden Content] [Hidden Content] Mouse wheel moves relative to the top window, not the window the mouse is pointing to. Reversed from 22.2.7.0 Official Binary.
  12. Preview: [Hidden Content] The system is easy to implent. *For the affect icon to be seen in the affectshower you can add : Then extend it with the steps @ uiAffectShower.py. * If you have extended sockets before, You can make modifications to get rid of the value0 necessity. * You can skip (Optional) steps. Download: MEGA or M2DL
  13. M2 Download Center Download Here ( Internal ) Download Here ( GitHub ) Here is the old german version: [Hidden Content] I revised it. Maybe someone would like to use it. Sorry for py and gui
  14. Let's say you have a NPC in your city1 (a smaller npc or a tall one) and the kingdom flag is not fits.. so you must want to hide'it. Open from client source: InstanceBaseEffect.cpp Search for: void CInstanceBase::__AttachEmpireEffect(DWORD eEmpire) Add under "if (IsResource()) return;" DWORD vnum_my_npc = 20406; if (GetRace() == vnum_my_npc) return; Just replace the "20406" for your npc vnum and compile. Enjoy
  15. Download Center Internal Mega.nz GitHub Hi devs, I wanted to add this feature to my mainlines, being that this system is now considered standard in all servers. I downloaded the public version that emulated how the Pet System worked, but I decided to make my own (and am sharing it so you can test it for me as well) In game pic: Pros: Fewer lines of code (50 or so, versus 1200+ in the public system) By not using apply_type and value to assign the monster to ride, we will not lose a usable bonus Being horse-based, trivially it is code that has been tested for years. If you are on the mount and warp, you will still be on the mount at login (being that we use EnterHorse) You can take advantage of the horse name system with a few modifications You only get mount bonuses if you are riding it and not while it is summoned Cons: I couldn't find any Thanks to @ HFWhite for testing. You should at least have the mount costume system.
  16. ! I've only used it on my test server ! Download Set item id under "high_item" event flag to highlight the item name with different color (/e high_item IDOFITEM) Usage: /drop_simul IDOFMOB AMOUNT Result:
  17. Let's assume common_drop_item.txt is almost never used by anyone, but for those who are thinking about using it, here's some (potential) bugs I found inside. Those may or may be not bugs, it depends on what use you want to make for common_drop_item. I think the most useful use would be to set drops easily depending on mob and users' levels, without making it mob-by-mob(mob_drop_item.txt), for those who wish to rewrite all the drops from scratch. It would be a good replace of settings drops via LUA(which may cause performance issues, and also you have to deal also with empire and user's drop rates) too. The bugs I found are: 1) Min and max_level are only based on the user's level. No matter which mob level it is(e.g. min_level=30, max_level=100: if you kill a wolf(level 3) you will get the item anyway). 2) Consequence of (1), if player level is above or below 15 levels(standard level limit for dropping items) than mob's, the item will be dropped anyway. 3) The "count" was declared but never applied, only one item used to be dropped. And so on, thus I decided to rewrite the entire function and make it useful. Renewal Features: 1) If mob level is below or above than for example 15 levels than the common_drop_item, the item won't be dropped. 2) If mob level is above or below than certain levels from user, the item won't be dropped. 3) Just like standard drops, there will be applied handicaps on drop rate %, based on user and mob levels(There is a mid-level between start and end, the farthest difference between this and user or mob level is, the less drop rate % will be) 4) Drops can be also based on mob ranks(like common drop item's concern), and the ranks can be indicated. 5) You can choose in which map the item can be dropped(0=any). 6) Multiple items can be set in the same settings. Other features can be found in the function. Understanding structure: The structure is similar to mob_drop_item's one, but with new(and different) variables, which are: "map": the map index, default 0 "lv_start" and "lv_end": min and max (user)level, default 1-999 "min_rank": and "max_rank": min and max (mob)Rank, starting from 0, which is the 1st rank, default 0-3 "rank_gain": if there are more ranks, each rank will have more % chance to drop the item, based on the previous rank's percent, default 20 "level_diff": the minimum level difference between user and mobs' levels, and also the minimum level difference between mob and lv_start or lv_end, default 15 For item declaration, the syntax is the same as mob_drop_item, with 3 chars: ID VNUM COUNT PERCENT Note: This system has not been tested in real servers, and it may have some bugs or can be optimized, so please analyze it if you are planning to user it in real servers. If you find any bug or you have any advice, please share it here. Replace inside ITEM_MANAGER::CreateDropItem function in item_manager.cpp Replace entire function inside item_manager_read_tables.cpp Replace this class inside item_manager_private_types.h and item_manager.cpp Example Usage(Sword+9 at 0.5%): Note: If you wish to apply fairness between q.ty of items->percents, you can use one of these logics: 1) multiply iPercent by i (inside item_manager.cpp) 2) just multiply manually item percents by count of items inside common_drop_item.txt(e.g. first item(1) percent = 1, item_count=30 -> first_item(1) percent = first_item(1) percent*item_count)
  18. M2 Download Center Download Here ( Internal ) Download Here ( GitHub ) Renewal Version:
  19. Hi, probably many of you, I say that is the advantage of this change. Well of course changing little help against attent of lag especially in some dungeons that are hundreds of phones, greatly help to run it in a more fast. So to change the seconds of extinction of a monster after it you will kill them, the normal range of approx. 10 second, enter in: We open: looking function: and to change the seconds of extinction course change, number 10, where red is bold, with how many seconds you want, preferably as 1 second, the very best. I apologize for the language. Good luck to implement. Regards, VegaS - The leader of the organization Titan2
  20. Download Metin2 Download or Github or Mega Hi guys, some people asked me for help with this trivial problem, so today I decided to release it. Now you can stack the stones and upgrade them. (obviously you did to changes the flag fields from item_proto server)
  21. Download Center Download Hello, I made this system 6 years ago, and it's time to share it, i guess.
  22. M2 Download Center Download Here ( Internal ) Download Here ( GitHub )
  23. Seach in char_skill.cpp for: if (number(1, 21 - MIN(20, GetSkillLevel(pkSk->dwVnum))) == 1) SetSkillLevel(pkSk->dwVnum, 20); Change it to this: //if (number(1, 21 - MIN(20, GetSkillLevel(pkSk->dwVnum))) == 1) SetSkillLevel(pkSk->dwVnum, 20);
  24. Thanks to @ Gurgarath @ HaiosMotan [Hidden Content] [Hidden Content] Requirements: Video: Release:
×
×
  • 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.