Sistemin mantığı şudur hp , max sp , ortalama zarar , beceri hasarı , hp üretimi , sp üretimi ve saldırı değeri efsunları hariç diğer kalan efsunlar 20 den fazla olduğunda edit süsü verilerek itemin giyilmemesini sağlamak. başta saydığım efsunlar içinde ayrıca kendi max değeri kadar engellenmiştir.
char_item.cpp açılır.
aratılır ve kod bloğunun altına bu kodlar eklenir.
game src ile işimiz bukadar. son olarak locale_string.txt açılır ve içine bunlar eklenir.
C++ ile Metin2 Editli Item Giyme Engeli Sistemi
Metin2 özel sunucularında güvenliği artırmak ve hile kullanımını engellemek amacıyla geliştirilen sistemlerden biri de 'Editli Item Giyme Engeli'dir. Bu sistem, oyuncuların düzenlenmiş yani 'editlenmiş' eşyaları giymesini engeller. Bu makalede, C++ tabanlı bir Metin2 sunucusunda bu sistemin nasıl kurulacağını detaylı olarak inceleyeceğiz.
Sistem Nedir ve Ne İşe Yarar?
Bu sistem, oyuncuların elindeki eşyanın checksum değerlerini kontrol ederek, orijinal sunucu dosyalarıyla uyumlu olup olmadığını denetler. Eğer bir eşya değiştirilmişse, yani checksum değeri uyuşmuyorsa, sistem bu eşyanın giyilmesini engeller. Bu sayede sunucuya zarar verebilecek editli eşyaların kullanımı önlenebilir.
Kurulum Aşamaları
1. Öncelikle game sunucu kaynak kodunu açmalısınız. Bu işlem genellikle Visual Studio veya benzeri bir IDE üzerinden yapılır.
2. Eşya sınıflarının tanımlandığı dosyalarda (örneğin char_item.cpp) giyim kontrolü yapılan fonksiyonu bulmanız gerekir. Bu genellikle EquipItem gibi bir fonksiyondur.
3. Bu fonksiyonun içine_checksum_ kontrol mekanizması eklenmelidir. Örneğin:
int CheckItemIntegrity(DWORD itemID, DWORD checksumValue);
Fonksiyon, eşyanın ID'si ile checksum değerini karşılaştırır. Uyum sağlanmazsa, return false; döndürerek giyimi engeller.
Checksum Değerleri Hakkında
Checksum, bir dosyanın veya verinin bütünlüğünü doğrulamak için kullanılan bir sayısal değerdir. Her eşya için benzersiz bir checksum değeri hesaplanabilir. Bu değer, sunucu tarafında sabit olarak tutulur ve eşya kullanılmadan önce kontrol edilir. Eğer eşya üzerinde değişiklik yapılmışsa checksum değeri farklı olur ve sistem bunu tespit eder.
Olası Sorunlar ve Çözümler
• Checksum hatası: Orijinal eşyalar bile bazen checksum hatası verebilir. Bu durumda checksum değerlerinin doğru girildiğinden emin olunmalıdır.
• Performans: Her giyim işleminde checksum kontrolü yapılması performansı düşürebilir. Bu nedenle checksum algoritmaları optimize edilmelidir.
• Kodlama hataları: Fonksiyon içindeki mantık hatası, tüm eşya sistemini etkileyebilir. Kodların derlenip test edilmesi önemlidir.
Sonuç
C++ kullanarak geliştirilen bu sistem, Metin2 özel sunucularında güvenliği artırmak için etkili bir yöntemdir. Ancak dikkatli kodlama ve test süreçleri ile desteklenmelidir. Metin2Lobby olarak, bu tür sistemlerin geliştirilmesine ve paylaşılmasına destek vermeye devam ediyoruz.
C++ Based Edited Item Wear Prevention System for Metin2
One of the security systems developed to enhance safety and prevent cheating in Metin2 private servers is the 'Edited Item Wear Prevention'. This system prevents players from wearing items that have been modified or 'edited'. In this article, we will examine in detail how to implement this system on a C++-based Metin2 server.
What Is The System and What Does It Do?
This system checks the checksum values of items held by players to verify their compatibility with the original server files. If an item has been altered, meaning its checksum value does not match, the system prevents the item from being equipped. This way, harmful edited items can be prevented from being used on the server.
Installation Steps
1. First, you need to open your game server source code. This process is typically done via an IDE like Visual Studio.
2. Locate the function responsible for equipment checks within the item class files (e.g., char_item.cpp). This is often a function named EquipItem.
3. Inside this function, add a _checksum_ control mechanism. For example:
int CheckItemIntegrity(DWORD itemID, DWORD checksumValue);
The function compares the item’s ID with its checksum value. If they do not match, it returns false, blocking the equip action.
About Checksum Values
Checksum is a numerical value used to verify the integrity of a file or data. A unique checksum value can be calculated for each item. This value is stored statically on the server side and checked before an item is used. If any modification is made to the item, the checksum value will differ, and the system detects this.
Potential Issues and Solutions
• Checksum error: Even original items may sometimes trigger a checksum error. Ensure that checksum values are correctly entered.
• Performance: Performing checksum checks during every wear action might reduce performance. Therefore, checksum algorithms should be optimized.
• Coding errors: Logical errors within the function could affect the entire item system. Compiling and testing the code is essential.
Conclusion
This system, developed using C++, is an effective method for enhancing security in Metin2 private servers. However, it must be supported by careful coding and testing processes. At Metin2Lobby, we continue to support the development and sharing of such systems.
char_item.cpp açılır.
Kod:
if (FN_check_item_sex(this, item) == false)
aratılır ve kod bloğunun altına bu kodlar eklenir.
Kod:
for (int i = 0; i < 5; ++i) { const TPlayerItemAttribute& edit = item->GetAttribute(i); if (edit.sValue > 20 && edit.bType != APPLY_MAX_HP && edit.bType != APPLY_MAX_SP && edit.bType != APPLY_SKILL_DAMAGE_BONUS && edit.bType != APPLY_NORMAL_HIT_DAMAGE_BONUS && edit.bType != APPLY_HP_REGEN && edit.bType != APPLY_SP_REGEN && edit.bType != APPLY_ATT_GRADE_BONUS) { ChatPacket(CHAT_TYPE_INFO, LC_TEXT("EDIT_ENGEL")); return false; } if (edit.sValue > 3000 && edit.bType == APPLY_MAX_HP) { ChatPacket(CHAT_TYPE_INFO, LC_TEXT("EDIT_ENGEL")); return false; } if (edit.sValue > 25 && edit.bType == APPLY_SKILL_DAMAGE_BONUS) { ChatPacket(CHAT_TYPE_INFO, LC_TEXT("EDIT_ENGEL")); return false; } if (edit.sValue > 60 && edit.bType == APPLY_NORMAL_HIT_DAMAGE_BONUS) { ChatPacket(CHAT_TYPE_INFO, LC_TEXT("EDIT_ENGEL")); return false; } if (edit.sValue > 30 && edit.bType == APPLY_HP_REGEN) { ChatPacket(CHAT_TYPE_INFO, LC_TEXT("EDIT_ENGEL")); return false; } if (edit.sValue > 30 && edit.bType == APPLY_SP_REGEN) { ChatPacket(CHAT_TYPE_INFO, LC_TEXT("EDIT_ENGEL")); return false; } if (edit.sValue > 50 && edit.bType == APPLY_ATT_GRADE_BONUS) { ChatPacket(CHAT_TYPE_INFO, LC_TEXT("EDIT_ENGEL")); return false; } if (edit.sValue > 80 && edit.bType == APPLY_MAX_SP) { ChatPacket(CHAT_TYPE_INFO, LC_TEXT("EDIT_ENGEL")); return false; } }
game src ile işimiz bukadar. son olarak locale_string.txt açılır ve içine bunlar eklenir.
Kod:
"EDIT_ENGEL"; "Edit orana sahip bir itemi giyemezsin !";
##KANIT##
C++ ile Metin2 Editli Item Giyme Engeli Sistemi
Metin2 özel sunucularında güvenliği artırmak ve hile kullanımını engellemek amacıyla geliştirilen sistemlerden biri de 'Editli Item Giyme Engeli'dir. Bu sistem, oyuncuların düzenlenmiş yani 'editlenmiş' eşyaları giymesini engeller. Bu makalede, C++ tabanlı bir Metin2 sunucusunda bu sistemin nasıl kurulacağını detaylı olarak inceleyeceğiz.
Sistem Nedir ve Ne İşe Yarar?
Bu sistem, oyuncuların elindeki eşyanın checksum değerlerini kontrol ederek, orijinal sunucu dosyalarıyla uyumlu olup olmadığını denetler. Eğer bir eşya değiştirilmişse, yani checksum değeri uyuşmuyorsa, sistem bu eşyanın giyilmesini engeller. Bu sayede sunucuya zarar verebilecek editli eşyaların kullanımı önlenebilir.
Kurulum Aşamaları
1. Öncelikle game sunucu kaynak kodunu açmalısınız. Bu işlem genellikle Visual Studio veya benzeri bir IDE üzerinden yapılır.
2. Eşya sınıflarının tanımlandığı dosyalarda (örneğin char_item.cpp) giyim kontrolü yapılan fonksiyonu bulmanız gerekir. Bu genellikle EquipItem gibi bir fonksiyondur.
3. Bu fonksiyonun içine_checksum_ kontrol mekanizması eklenmelidir. Örneğin:
int CheckItemIntegrity(DWORD itemID, DWORD checksumValue);
Fonksiyon, eşyanın ID'si ile checksum değerini karşılaştırır. Uyum sağlanmazsa, return false; döndürerek giyimi engeller.
Checksum Değerleri Hakkında
Checksum, bir dosyanın veya verinin bütünlüğünü doğrulamak için kullanılan bir sayısal değerdir. Her eşya için benzersiz bir checksum değeri hesaplanabilir. Bu değer, sunucu tarafında sabit olarak tutulur ve eşya kullanılmadan önce kontrol edilir. Eğer eşya üzerinde değişiklik yapılmışsa checksum değeri farklı olur ve sistem bunu tespit eder.
Olası Sorunlar ve Çözümler
• Checksum hatası: Orijinal eşyalar bile bazen checksum hatası verebilir. Bu durumda checksum değerlerinin doğru girildiğinden emin olunmalıdır.
• Performans: Her giyim işleminde checksum kontrolü yapılması performansı düşürebilir. Bu nedenle checksum algoritmaları optimize edilmelidir.
• Kodlama hataları: Fonksiyon içindeki mantık hatası, tüm eşya sistemini etkileyebilir. Kodların derlenip test edilmesi önemlidir.
Sonuç
C++ kullanarak geliştirilen bu sistem, Metin2 özel sunucularında güvenliği artırmak için etkili bir yöntemdir. Ancak dikkatli kodlama ve test süreçleri ile desteklenmelidir. Metin2Lobby olarak, bu tür sistemlerin geliştirilmesine ve paylaşılmasına destek vermeye devam ediyoruz.
C++ Based Edited Item Wear Prevention System for Metin2
One of the security systems developed to enhance safety and prevent cheating in Metin2 private servers is the 'Edited Item Wear Prevention'. This system prevents players from wearing items that have been modified or 'edited'. In this article, we will examine in detail how to implement this system on a C++-based Metin2 server.
What Is The System and What Does It Do?
This system checks the checksum values of items held by players to verify their compatibility with the original server files. If an item has been altered, meaning its checksum value does not match, the system prevents the item from being equipped. This way, harmful edited items can be prevented from being used on the server.
Installation Steps
1. First, you need to open your game server source code. This process is typically done via an IDE like Visual Studio.
2. Locate the function responsible for equipment checks within the item class files (e.g., char_item.cpp). This is often a function named EquipItem.
3. Inside this function, add a _checksum_ control mechanism. For example:
int CheckItemIntegrity(DWORD itemID, DWORD checksumValue);
The function compares the item’s ID with its checksum value. If they do not match, it returns false, blocking the equip action.
About Checksum Values
Checksum is a numerical value used to verify the integrity of a file or data. A unique checksum value can be calculated for each item. This value is stored statically on the server side and checked before an item is used. If any modification is made to the item, the checksum value will differ, and the system detects this.
Potential Issues and Solutions
• Checksum error: Even original items may sometimes trigger a checksum error. Ensure that checksum values are correctly entered.
• Performance: Performing checksum checks during every wear action might reduce performance. Therefore, checksum algorithms should be optimized.
• Coding errors: Logical errors within the function could affect the entire item system. Compiling and testing the code is essential.
Conclusion
This system, developed using C++, is an effective method for enhancing security in Metin2 private servers. However, it must be supported by careful coding and testing processes. At Metin2Lobby, we continue to support the development and sharing of such systems.
