Herkese merhaba, olayın özeti şu şekildedir;
Oyuncunun nesne market deposuna bir şey gönderirken pozisyon belirlemenize gerek kalmaz, oyuncu nesne marketi açtığınında nesneler dizili olarak gelir. Dizebildiği kadarını dizer. Eğer depoda 2-3 sayfa nesne var ise ilk sayfayı boşaltıp tekrar deposunu açarsa nesneler tekrar sıralanır. Kısa ve yararlı bir eklentidir.
Oyuncunun nesne market deposuna bir şey gönderirken pozisyon belirlemenize gerek kalmaz, oyuncu nesne marketi açtığınında nesneler dizili olarak gelir. Dizebildiği kadarını dizer. Eğer depoda 2-3 sayfa nesne var ise ilk sayfayı boşaltıp tekrar deposunu açarsa nesneler tekrar sıralanır. Kısa ve yararlı bir eklentidir.
game/char.cpp açılır
includelar arasına eklenir.
Kod:
#include "../../libgame/include/grid.h"
Aratılır:
Kod:
void CHARACTER::LoadMall(int iItemCount, TPlayerItem * pItems)
#ifdef DÜTDÜT içindeki kodları kendi fonksiyonunuza eklemeniz yeterli.
Kod:
void CHARACTER::LoadMall(int iItemCount, TPlayerItem * pItems){ bool bLoaded = false; if (m_pkMall) { bLoaded = true; } if (!m_pkMall) { m_pkMall = M2_NEW CSafebox(this, 3 * SAFEBOX_PAGE_SIZE, 0, 0); } else { m_pkMall->ChangeSize(3 * SAFEBOX_PAGE_SIZE); } m_pkMall->SetWindowMode(MALL); TPacketCGSafeboxSize p; p.bHeader = HEADER_GC_MALL_OPEN; p.bSize = 3 * SAFEBOX_PAGE_SIZE; GetDesc()->Packet(&p, sizeof(TPacketCGSafeboxSize)); if (!bLoaded){ #ifdef DÜTDÜT if (IsGM()) { ChatPacket(1, "<GM|MALL> gelenItemSayisi: %d", iItemCount); } CGrid iGrid = CGrid(5,9); #endif for (int i = 0; i < iItemCount; ++i, ++pItems){ if (!m_pkMall->IsValidPosition(pItems->pos)) { continue; } LPITEM item = ITEM_MANAGER::instance().CreateItem(pItems->vnum, pItems->count, pItems->id); if (!item){ sys_err("cannot create item vnum %d id %u (name: %s)", pItems->vnum, pItems->id, GetName()); continue;} item->SetSkipSave(true); item->SetSockets(pItems->alSockets); item->SetAttributes(pItems->aAttr); #ifdef DÜTDÜT // ChatPacket(1,"itemName:%s",item->GetName()); int iPos=(-1); iPos = iGrid.FindBlank(1, item->GetSize()); if (iPos >= 0) { iGrid.Put(iPos, 1, item->GetSize()); if (!m_pkMall->Add(iPos, item)) { M2_DESTROY_ITEM(item); } else { item->SetSkipSave(false); } }else{ M2_DESTROY_ITEM(item); //break; } #else if (!m_pkMall->Add(pItems->pos, item)){M2_DESTROY_ITEM(item);} else{item->SetSkipSave(false);} #endif } } }
Not: GIF'in durdurulma sebebi depo açma arasında 5sn bekleme süresi olmasıdır.
Nesne Market Deposu Düzenlemesi
Metin2 özel sunucularında geliştirme yaparken, oyuncuların eşya yönetimini kolaylaştırmak ve oyun deneyimini zenginleştirmek adına Nesne Market Deposu gibi yapılar büyük önem taşır. Bu depo sistemi, oyuncuların belirli nesneleri güvenli bir şekilde saklamasına ve ihtiyaç duyduklarında hızlıca erişmesine olanak tanır. Ancak bu sistemin doğru şekilde düzenlenmesi, sunucu performansını ve kullanıcı memnuniyetini doğrudan etkiler. Bu yazıda, Metin2Lobby üzerinden sunulan bilgiler doğrultusunda nesne market deposunun nasıl düzenleneceği, hangi C++ sistemlerinin kullanılacağı ve bu yapıya Python entegrasyonunun nasıl sağlanması gerektiği üzerinde duracağız.
Nesne Market Deposu Nedir?
Nesne Market Deposu, Metin2 özel sunucularında bulunan bir sistemdir. Oyuncular, bu depoya belirli eşyalarını yerleştirip, diğer oyuncularla ticaret yapabilir veya kendi kullanımına özel bir alan olarak kullanabilirler. Bu sistem, DB (veritabanı) üzerinde çalışır ve game server tarafından yönetilir. Depo sistemi genellikle auth ve game sunucuları arasında paylaşılan verilerle senkronize edilir.
Depo Sisteminin Yapısı
Depo sistemi, temel olarak iki ana bileşenden oluşur: client src ve server src. Client tarafında oyuncuya sunulan arayüz, uiscript ve py root dosyalarıyla tanımlanır. Bu arayüzler, Python GUI teknolojileriyle geliştirilir. Sunucu tarafında ise C++ system kullanılarak depo işlemleri kontrol edilir ve veritabanına yazılır. Bu işlemler sırasında source edit işlemleri yapılarak mevcut sistemler genişletilebilir veya özelleştirilebilir.
C++ ile Depo Düzenlemesi
Nesne Market Deposu'nu düzenlemek için öncelikle server src üzerinde gerekli C++ değişiklikleri yapılmalıdır. Bu işlemde, depo açma, kapama, eşya ekleme ve silme gibi temel fonksiyonlar yeniden tanımlanabilir. Metin2 server src üzerinden yapılan bu düzenlemeler, compile işleminden sonra aktif hale gelir. Geliştiriciler, core dosyalarını kullanarak bu işlemleri optimize edebilir. Game core ve db core gibi yapılar da burada önemli rol oynar.
Python Entegrasyonu ve GUI Arayüzü
Oyuncuların depo sistemine erişimi genellikle Python GUI arayüzü üzerinden sağlanır. Bu arayüz, uiscript dosyaları kullanılarak geliştirilir. Oyuncular, py root klasöründe bulunan betikler sayesinde depodaki eşyaları görebilir, filtreleyebilir ve işlem yapabilir. Bu arayüzler, hem kullanıcı dostu olmalı hem de sunucu tarafındaki C++ mantığıyla uyumlu çalışmalıdır. Martysama gibi kaynaklar, bu tür arayüz geliştirmelerinde örnek alınabilir.
Veritabanı ve Güvenlik
Depo sistemlerinde en önemli konulardan biri veri güvenliğidir. Eşyaların çalınmaması, sahte işlemlerin engellenmesi gibi güvenlik önlemleri DB seviyesinde alınmalıdır. Sunucu tarafında auth ve game sunucuları arasındaki iletişim güvenli olmalı ve tüm işlemler loglanmalıdır. Bu sistemlerin doğru yapılandırılması için Metin2 development bilgisi şarttır. Ayrıca, pack sistemleri ile birlikte çalışan depolar, daha stabil ve güvenli bir yapı sunar.
Sonuç
Nesne Market Deposu, Metin2 özel sunucularında kullanıcıların deneyimini artıran önemli bir özelliktir. Doğru yapılandırılmış bir depo sistemi, C++ ve Python tabanlı geliştirme süreçleriyle birlikte çalışarak hem kullanıcı dostu hem de güvenli bir yapı sunar. Metin2Lobby üzerinden sunulan kaynaklar ve örnek sistemler, bu tür geliştirmeler için harika bir başlangıç noktası oluşturur.
Editing the Item Market Warehouse
When developing private servers for Metin2, structures such as the Item Market Warehouse are essential for enhancing player experience and simplifying item management. This warehouse system allows players to securely store certain items and access them quickly when needed. Correctly configuring this system directly impacts server performance and user satisfaction. In this article, we will focus on how to properly configure the item market warehouse, which C++ systems to use, and how Python integration can be implemented—based on information provided via Metin2Lobby.
What is the Item Market Warehouse?
The Item Market Warehouse is a system found in Metin2 private servers. Players can place specific items into this warehouse to trade with other players or use it as a personal storage area. This system operates on a DB (database) and is managed by the game server. The warehouse system is typically synchronized using shared data between auth and game servers.
Structure of the Warehouse System
The warehouse system consists of two main components: client src and server src. The interface presented to the player on the client side is defined using uiscript and py root files. These interfaces are developed using Python GUI technologies. On the server side, C++ system handles warehouse operations and writes to the database. During these processes, source edit operations can be performed to extend or customize existing systems.
Editing the Warehouse with C++
To configure the Item Market Warehouse, necessary C++ modifications must first be made in the server src. In this process, basic functions like opening/closing the warehouse, adding or removing items can be redefined. Modifications made through Metin2 server src become active after a compile operation. Developers can optimize these processes by utilizing core files. Structures like game core and db core play an important role here.
Python Integration and GUI Interface
Player access to the warehouse system is generally provided through a Python GUI interface. This interface is developed using uiscript files. Thanks to scripts located in the py root folder, players can view, filter, and manage items stored in the warehouse. Such interfaces should not only be user-friendly but also compatible with the C++ logic running on the server side. Sources like Martysama can serve as examples during such interface developments.
Database and Security
One of the most critical aspects of warehouse systems is data security. Preventing theft of items and blocking fraudulent transactions must be addressed at the DB level. Communication between auth and game servers must be secure, and all actions should be logged. Proper configuration of these systems requires knowledge in Metin2 development. Additionally, warehouses working alongside pack systems provide more stable and secure structures.
Conclusion
The Item Market Warehouse is a vital feature that enhances player experience in Metin2 private servers. A properly configured warehouse system, combining C++ and Python-based development processes, provides both a user-friendly and secure structure. Resources and sample systems available via Metin2Lobby offer an excellent starting point for such developments.
Nesne Market Deposu Düzenlemesi
Metin2 özel sunucularında geliştirme yaparken, oyuncuların eşya yönetimini kolaylaştırmak ve oyun deneyimini zenginleştirmek adına Nesne Market Deposu gibi yapılar büyük önem taşır. Bu depo sistemi, oyuncuların belirli nesneleri güvenli bir şekilde saklamasına ve ihtiyaç duyduklarında hızlıca erişmesine olanak tanır. Ancak bu sistemin doğru şekilde düzenlenmesi, sunucu performansını ve kullanıcı memnuniyetini doğrudan etkiler. Bu yazıda, Metin2Lobby üzerinden sunulan bilgiler doğrultusunda nesne market deposunun nasıl düzenleneceği, hangi C++ sistemlerinin kullanılacağı ve bu yapıya Python entegrasyonunun nasıl sağlanması gerektiği üzerinde duracağız.
Nesne Market Deposu Nedir?
Nesne Market Deposu, Metin2 özel sunucularında bulunan bir sistemdir. Oyuncular, bu depoya belirli eşyalarını yerleştirip, diğer oyuncularla ticaret yapabilir veya kendi kullanımına özel bir alan olarak kullanabilirler. Bu sistem, DB (veritabanı) üzerinde çalışır ve game server tarafından yönetilir. Depo sistemi genellikle auth ve game sunucuları arasında paylaşılan verilerle senkronize edilir.
Depo Sisteminin Yapısı
Depo sistemi, temel olarak iki ana bileşenden oluşur: client src ve server src. Client tarafında oyuncuya sunulan arayüz, uiscript ve py root dosyalarıyla tanımlanır. Bu arayüzler, Python GUI teknolojileriyle geliştirilir. Sunucu tarafında ise C++ system kullanılarak depo işlemleri kontrol edilir ve veritabanına yazılır. Bu işlemler sırasında source edit işlemleri yapılarak mevcut sistemler genişletilebilir veya özelleştirilebilir.
C++ ile Depo Düzenlemesi
Nesne Market Deposu'nu düzenlemek için öncelikle server src üzerinde gerekli C++ değişiklikleri yapılmalıdır. Bu işlemde, depo açma, kapama, eşya ekleme ve silme gibi temel fonksiyonlar yeniden tanımlanabilir. Metin2 server src üzerinden yapılan bu düzenlemeler, compile işleminden sonra aktif hale gelir. Geliştiriciler, core dosyalarını kullanarak bu işlemleri optimize edebilir. Game core ve db core gibi yapılar da burada önemli rol oynar.
Python Entegrasyonu ve GUI Arayüzü
Oyuncuların depo sistemine erişimi genellikle Python GUI arayüzü üzerinden sağlanır. Bu arayüz, uiscript dosyaları kullanılarak geliştirilir. Oyuncular, py root klasöründe bulunan betikler sayesinde depodaki eşyaları görebilir, filtreleyebilir ve işlem yapabilir. Bu arayüzler, hem kullanıcı dostu olmalı hem de sunucu tarafındaki C++ mantığıyla uyumlu çalışmalıdır. Martysama gibi kaynaklar, bu tür arayüz geliştirmelerinde örnek alınabilir.
Veritabanı ve Güvenlik
Depo sistemlerinde en önemli konulardan biri veri güvenliğidir. Eşyaların çalınmaması, sahte işlemlerin engellenmesi gibi güvenlik önlemleri DB seviyesinde alınmalıdır. Sunucu tarafında auth ve game sunucuları arasındaki iletişim güvenli olmalı ve tüm işlemler loglanmalıdır. Bu sistemlerin doğru yapılandırılması için Metin2 development bilgisi şarttır. Ayrıca, pack sistemleri ile birlikte çalışan depolar, daha stabil ve güvenli bir yapı sunar.
Sonuç
Nesne Market Deposu, Metin2 özel sunucularında kullanıcıların deneyimini artıran önemli bir özelliktir. Doğru yapılandırılmış bir depo sistemi, C++ ve Python tabanlı geliştirme süreçleriyle birlikte çalışarak hem kullanıcı dostu hem de güvenli bir yapı sunar. Metin2Lobby üzerinden sunulan kaynaklar ve örnek sistemler, bu tür geliştirmeler için harika bir başlangıç noktası oluşturur.
Editing the Item Market Warehouse
When developing private servers for Metin2, structures such as the Item Market Warehouse are essential for enhancing player experience and simplifying item management. This warehouse system allows players to securely store certain items and access them quickly when needed. Correctly configuring this system directly impacts server performance and user satisfaction. In this article, we will focus on how to properly configure the item market warehouse, which C++ systems to use, and how Python integration can be implemented—based on information provided via Metin2Lobby.
What is the Item Market Warehouse?
The Item Market Warehouse is a system found in Metin2 private servers. Players can place specific items into this warehouse to trade with other players or use it as a personal storage area. This system operates on a DB (database) and is managed by the game server. The warehouse system is typically synchronized using shared data between auth and game servers.
Structure of the Warehouse System
The warehouse system consists of two main components: client src and server src. The interface presented to the player on the client side is defined using uiscript and py root files. These interfaces are developed using Python GUI technologies. On the server side, C++ system handles warehouse operations and writes to the database. During these processes, source edit operations can be performed to extend or customize existing systems.
Editing the Warehouse with C++
To configure the Item Market Warehouse, necessary C++ modifications must first be made in the server src. In this process, basic functions like opening/closing the warehouse, adding or removing items can be redefined. Modifications made through Metin2 server src become active after a compile operation. Developers can optimize these processes by utilizing core files. Structures like game core and db core play an important role here.
Python Integration and GUI Interface
Player access to the warehouse system is generally provided through a Python GUI interface. This interface is developed using uiscript files. Thanks to scripts located in the py root folder, players can view, filter, and manage items stored in the warehouse. Such interfaces should not only be user-friendly but also compatible with the C++ logic running on the server side. Sources like Martysama can serve as examples during such interface developments.
Database and Security
One of the most critical aspects of warehouse systems is data security. Preventing theft of items and blocking fraudulent transactions must be addressed at the DB level. Communication between auth and game servers must be secure, and all actions should be logged. Proper configuration of these systems requires knowledge in Metin2 development. Additionally, warehouses working alongside pack systems provide more stable and secure structures.
Conclusion
The Item Market Warehouse is a vital feature that enhances player experience in Metin2 private servers. A properly configured warehouse system, combining C++ and Python-based development processes, provides both a user-friendly and secure structure. Resources and sample systems available via Metin2Lobby offer an excellent starting point for such developments.
