Merhaba,
Yere düşen itemleri toplarken gecikme yapabiliyor.
Örnek vermek gerekirse bir itemi aldınız diğerinin üstüne tıklıyorsunuz 1 kerede almıyor 2. veya 3.de alıyor.
Burada yaptığımız şey bu delay süresini kaldırıp bu gecikmeyi kapatmak.
PythonPlayer.cpp Açılır
Yere Düşen İtemleri Toplarken Gecikmeyi Kapatmak
Metin2 özel sunucularında geliştirme yaparken kullanıcı deneyimini artırmak için birçok küçük ayar yapılabilir. Bunlardan biri de oyuncuların yere düşen itemleri toplarken yaşadığı gecikmelerdir. Bu gecikme, özellikle hızlı tempolu savaşlarda ya da PvP sistemlerinde ciddi dezavantajlar yaratabilir. Bu yazıda, Metin2 özel sunucularında yere düşen itemleri toplarken oluşan gecikmeyi nasıl kapatabileceğinizi detaylıca ele alacağız.
Gecikmenin Kaynağı Nedir?
Metin2 oyun motoru, güvenlik ve anti-cheat önlemleri doğrultusunda bazı işlemler için belirli zaman aralıkları tanımlamıştır. Item toplama işlemi de bu kategoride yer alır. Varsayılan olarak, bir oyuncu yere düşen bir itemi aldıktan sonra kısa bir bekleme süresi uygulanır. Bu süre boyunca başka bir item alınamaz. Bu mekanizma, bot kullanımlarını engellemek amacıyla tasarlanmıştır.
Neden Kapatmalıyız?
Ancak özel sunucularda, özellikle PvP odaklı sistemlerde bu gecikme, oyuncuların akıcı oynamasını engeller. Özellikle bir savaş sonucunda yerlere saçılan itemleri hızlıca toplayabilmek, oyuncuların avantajlarını korumasını sağlar. Bu nedenle, gecikmeyi kaldırmak isteyen sunucu geliştiricileri için bu ayar oldukça önemlidir.
Nasıl Kapatılır?
Bu ayarı kapatmak için öncelikle game server source code üzerinde değişiklik yapmanız gerekir. Genellikle bu gecikme, char_item.cpp veya benzeri dosyalarda tanımlanmıştır. Aşağıdaki adımları takip ederek bu gecikmeyi kaldırabilirsiniz:
- Adım 1: game/src/char_item.cpp dosyasını açın.
- Adım 2: AutoGiveItem veya PickupItem fonksiyonunu bulun.
- Adım 3: İçerisinde m_pkChr->GetAffectFlag() & AFFECT_PICKUP_DELAY gibi bir kontrol varsa, bu satırı yorum satırına çevirin ya da kaldırın.
- Adım 4:[/BR] Değişiklikleri kaydedin ve projeyi yeniden derleyin (compile).
Alternatif Yöntem: Client Tarafında Ayar
Eğer server-side üzerinde değişiklik yapmak istemiyorsanız, client-side üzerinden de bu gecikmeyi etkileyen ayarlar olabilir. Ancak bu yöntem daha sınırlıdır ve genellikle sadece görsel etkileri değiştirir. Sunucu tarafındaki kontrol hâlâ aktif kalır.
Python ve GUI Sistemleriyle Entegrasyon
Eğer özel GUI sistemleri veya Python tabanlı arayüzler kullanıyorsanız, bu gecikmeyi uiscript üzerinden de kontrol etmek mümkündür. Ancak bu, genellikle sadece kullanıcı arayüzüne ait görsel geri bildirimleri etkiler; gerçek gecikme hâlâ sunucudan gelir.
Sonuç
Yere düşen itemleri toplarken yaşanan gecikmeyi kaldırmak, özellikle Metin2 PvP sunucularında önemli bir performans ve kullanıcı deneyimi artışı sağlar. Bu işlem için C++ source kodlarında değişiklik yapılması gerekse de, oldukça basit ve etkili bir yöntemdir. Martysama ve diğer Metin2 development kaynakları üzerinden bu konuda daha fazla teknik bilgiye ulaşabilirsiniz.
Disabling Delay When Picking Up Dropped Items
In Metin2 private server development, many small adjustments can enhance the user experience. One such adjustment is the delay experienced by players when picking up items dropped on the ground. This delay can create significant disadvantages during fast-paced battles or PvP scenarios. In this article, we will examine in detail how to disable the delay when picking up items dropped on the ground in Metin2 private servers.
What Causes the Delay?
The Metin2 game engine defines certain time intervals for specific actions in order to ensure security and prevent cheating. The item pickup action falls under this category. By default, after a player picks up an item dropped on the ground, a short waiting period is enforced. During this time, another item cannot be picked up. This mechanism was designed to prevent bot usage.
Why Should We Disable It?
However, in private servers, especially in PvP-focused environments, this delay can disrupt fluid gameplay. Being able to quickly collect items scattered across the battlefield after combat is crucial for players to maintain their advantages. Therefore, removing this delay is very important for server developers aiming for faster-paced gameplay.
How to Disable It?
To disable this delay, you need to modify the game server source code. Usually, this delay is defined within files like char_item.cpp. You can follow the steps below to remove this delay:
- Step 1: Open the file game/src/char_item.cpp.
- Step 2: Find the function AutoGiveItem or PickupItem.
- Step 3: If there is a check like m_pkChr->GetAffectFlag() & AFFECT_PICKUP_DELAY inside the function, comment out or remove that line.
- Step 4: Save the changes and recompile the project (compile).
Alternative Method: Client-Side Adjustment
If you prefer not to make changes to the server-side code, there may be settings on the client-side that affect this delay. However, this method is more limited and often only affects visual feedback. The server-side control remains active.
Integration with Python and GUI Systems
If you are using custom GUI systems or Python-based interfaces, it might also be possible to control this delay via uiscript. However, this usually only affects UI-related visual feedback; the actual delay still originates from the server.
Conclusion
Removing the delay when picking up items dropped on the ground provides significant performance and user experience improvements, especially in Metin2 PvP servers. Although this process requires modifications in the C++ source code, it is a simple and effective method. You can find more technical information on this topic through sources like Martysama and other Metin2 development resources.
Yere düşen itemleri toplarken gecikme yapabiliyor.
Örnek vermek gerekirse bir itemi aldınız diğerinin üstüne tıklıyorsunuz 1 kerede almıyor 2. veya 3.de alıyor.
Burada yaptığımız şey bu delay süresini kaldırıp bu gecikmeyi kapatmak.
PythonPlayer.cpp Açılır
Kod:
void CPythonPlayer::SendClickItemPacket(DWORD dwIID)
Kod:
//s_dwNextTCPTime=dwCurTime + 500;
Kod:
void CPythonPlayer::SendClickItemPacket(DWORD dwIID) { if (IsObserverMode()) return; static DWORD s_dwNextTCPTime = 0; DWORD dwCurTime=ELTimer_GetMSec(); if (dwCurTime >= s_dwNextTCPTime) { // s_dwNextTCPTime=dwCurTime + 500; 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); } }
Yere Düşen İtemleri Toplarken Gecikmeyi Kapatmak
Metin2 özel sunucularında geliştirme yaparken kullanıcı deneyimini artırmak için birçok küçük ayar yapılabilir. Bunlardan biri de oyuncuların yere düşen itemleri toplarken yaşadığı gecikmelerdir. Bu gecikme, özellikle hızlı tempolu savaşlarda ya da PvP sistemlerinde ciddi dezavantajlar yaratabilir. Bu yazıda, Metin2 özel sunucularında yere düşen itemleri toplarken oluşan gecikmeyi nasıl kapatabileceğinizi detaylıca ele alacağız.
Gecikmenin Kaynağı Nedir?
Metin2 oyun motoru, güvenlik ve anti-cheat önlemleri doğrultusunda bazı işlemler için belirli zaman aralıkları tanımlamıştır. Item toplama işlemi de bu kategoride yer alır. Varsayılan olarak, bir oyuncu yere düşen bir itemi aldıktan sonra kısa bir bekleme süresi uygulanır. Bu süre boyunca başka bir item alınamaz. Bu mekanizma, bot kullanımlarını engellemek amacıyla tasarlanmıştır.
Neden Kapatmalıyız?
Ancak özel sunucularda, özellikle PvP odaklı sistemlerde bu gecikme, oyuncuların akıcı oynamasını engeller. Özellikle bir savaş sonucunda yerlere saçılan itemleri hızlıca toplayabilmek, oyuncuların avantajlarını korumasını sağlar. Bu nedenle, gecikmeyi kaldırmak isteyen sunucu geliştiricileri için bu ayar oldukça önemlidir.
Nasıl Kapatılır?
Bu ayarı kapatmak için öncelikle game server source code üzerinde değişiklik yapmanız gerekir. Genellikle bu gecikme, char_item.cpp veya benzeri dosyalarda tanımlanmıştır. Aşağıdaki adımları takip ederek bu gecikmeyi kaldırabilirsiniz:
- Adım 1: game/src/char_item.cpp dosyasını açın.
- Adım 2: AutoGiveItem veya PickupItem fonksiyonunu bulun.
- Adım 3: İçerisinde m_pkChr->GetAffectFlag() & AFFECT_PICKUP_DELAY gibi bir kontrol varsa, bu satırı yorum satırına çevirin ya da kaldırın.
- Adım 4:[/BR] Değişiklikleri kaydedin ve projeyi yeniden derleyin (compile).
Alternatif Yöntem: Client Tarafında Ayar
Eğer server-side üzerinde değişiklik yapmak istemiyorsanız, client-side üzerinden de bu gecikmeyi etkileyen ayarlar olabilir. Ancak bu yöntem daha sınırlıdır ve genellikle sadece görsel etkileri değiştirir. Sunucu tarafındaki kontrol hâlâ aktif kalır.
Python ve GUI Sistemleriyle Entegrasyon
Eğer özel GUI sistemleri veya Python tabanlı arayüzler kullanıyorsanız, bu gecikmeyi uiscript üzerinden de kontrol etmek mümkündür. Ancak bu, genellikle sadece kullanıcı arayüzüne ait görsel geri bildirimleri etkiler; gerçek gecikme hâlâ sunucudan gelir.
Sonuç
Yere düşen itemleri toplarken yaşanan gecikmeyi kaldırmak, özellikle Metin2 PvP sunucularında önemli bir performans ve kullanıcı deneyimi artışı sağlar. Bu işlem için C++ source kodlarında değişiklik yapılması gerekse de, oldukça basit ve etkili bir yöntemdir. Martysama ve diğer Metin2 development kaynakları üzerinden bu konuda daha fazla teknik bilgiye ulaşabilirsiniz.
Disabling Delay When Picking Up Dropped Items
In Metin2 private server development, many small adjustments can enhance the user experience. One such adjustment is the delay experienced by players when picking up items dropped on the ground. This delay can create significant disadvantages during fast-paced battles or PvP scenarios. In this article, we will examine in detail how to disable the delay when picking up items dropped on the ground in Metin2 private servers.
What Causes the Delay?
The Metin2 game engine defines certain time intervals for specific actions in order to ensure security and prevent cheating. The item pickup action falls under this category. By default, after a player picks up an item dropped on the ground, a short waiting period is enforced. During this time, another item cannot be picked up. This mechanism was designed to prevent bot usage.
Why Should We Disable It?
However, in private servers, especially in PvP-focused environments, this delay can disrupt fluid gameplay. Being able to quickly collect items scattered across the battlefield after combat is crucial for players to maintain their advantages. Therefore, removing this delay is very important for server developers aiming for faster-paced gameplay.
How to Disable It?
To disable this delay, you need to modify the game server source code. Usually, this delay is defined within files like char_item.cpp. You can follow the steps below to remove this delay:
- Step 1: Open the file game/src/char_item.cpp.
- Step 2: Find the function AutoGiveItem or PickupItem.
- Step 3: If there is a check like m_pkChr->GetAffectFlag() & AFFECT_PICKUP_DELAY inside the function, comment out or remove that line.
- Step 4: Save the changes and recompile the project (compile).
Alternative Method: Client-Side Adjustment
If you prefer not to make changes to the server-side code, there may be settings on the client-side that affect this delay. However, this method is more limited and often only affects visual feedback. The server-side control remains active.
Integration with Python and GUI Systems
If you are using custom GUI systems or Python-based interfaces, it might also be possible to control this delay via uiscript. However, this usually only affects UI-related visual feedback; the actual delay still originates from the server.
Conclusion
Removing the delay when picking up items dropped on the ground provides significant performance and user experience improvements, especially in Metin2 PvP servers. Although this process requires modifications in the C++ source code, it is a simple and effective method. You can find more technical information on this topic through sources like Martysama and other Metin2 development resources.
