Kod:
{ "name" :"quick_slot_1"
Kod:
{ "name" : "slot_1", "type" : "image", "x" : 3, "y" : 3, "image" : "d:/ymir work/ui/game/taskbar/1.sub", "children" : ( { "name" : "slot_1_cd", "type" : "text", "x" : 0, "y" : 0, "horizontal_align" : "center", "vertical_align" : "center", "text" : "10", "fontname" : "Tahoma Bold:16", "r" : 1, "g" : 1, "b" : 0, "a" : 0, }, ), }, { "name" : "slot_2", "type" : "image", "x" : 35, "y" : 3, "image" : "d:/ymir work/ui/game/taskbar/2.sub", "children" : ( { "name" : "slot_2_cd", "type" : "text", "x" : 0, "y" : 0, "horizontal_align" : "center", "vertical_align" : "center", "text" : "10", "fontname" : "Tahoma Bold:16", "r" : 1, "g" : 1, "b" : 0, "a" : 0, }, ), }, { "name" : "slot_3", "type" : "image", "x" : 67, "y" : 3, "image" : "d:/ymir work/ui/game/taskbar/3.sub", "children" : ( { "name" : "slot_3_cd", "type" : "text", "x" : 0, "y" : 0, "horizontal_align" : "center", "vertical_align" : "center", "text" : "10", "fontname" : "Tahoma Bold:16", "r" : 1, "g" : 1, "b" : 0, "a" : 0, }, ), },{ "name" : "slot_4", "type" : "image", "x" : 99, "y" : 3, "image" : "d:/ymir work/ui/game/taskbar/4.sub", "children" : ( { "name" : "slot_4_cd", "type" : "text", "x" : 0, "y" : 0, "horizontal_align" : "center", "vertical_align" : "center", "text" : "10", "fontname" : "Tahoma Bold:16", "r" : 1, "g" : 1, "b" : 0, "a" : 0, }, ), },
Kod:
"name" : "quick_slot_1", ... "children" :
Kod:
{ "name" : "slot_f1", "type" : "image", "x" : 3, "y" : 3, "image" : "d:/ymir work/ui/game/taskbar/f1.sub", "children" : ( { "name" : "slot_f1_cd", "type" : "text", "x" : 0, "y" : 0, "horizontal_align" : "center", "vertical_align" : "center", "text" : "10", "fontname" : "Tahoma Bold:16", "r" : 1, "g" : 1, "b" : 0, "a" : 0, }, ), }, { "name" : "slot_f2", "type" : "image", "x" : 35, "y" : 3, "image" : "d:/ymir work/ui/game/taskbar/f2.sub", "children" : ( { "name" : "slot_f2_cd", "type" : "text", "x" : 0, "y" : 0, "horizontal_align" : "center", "vertical_align" : "center", "text" : "10", "fontname" : "Tahoma Bold:16", "r" : 1, "g" : 1, "b" : 0, "a" : 0, }, ), }, { "name" : "slot_f3", "type" : "image", "x" : 67, "y" : 3, "image" : "d:/ymir work/ui/game/taskbar/f3.sub", "children" : ( { "name" : "slot_f3_cd", "type" : "text", "x" : 0, "y" : 0, "horizontal_align" : "center", "vertical_align" : "center", "text" : "10", "fontname" : "Tahoma Bold:16", "r" : 1, "g" : 1, "b" : 0, "a" : 0, }, ), },{ "name" : "slot_f4", "type" : "image", "x" : 99, "y" : 3, "image" : "d:/ymir work/ui/game/taskbar/f4.sub", "children" : ( { "name" : "slot_f4_cd", "type" : "text", "x" : 0, "y" : 0, "horizontal_align" : "center", "vertical_align" : "center", "text" : "10", "fontname" : "Tahoma Bold:16", "r" : 1, "g" : 1, "b" : 0, "a" : 0, }, ), },
Kod:
self.quickslot = [*]
Kod:
self.quickslot = [*] self.quickslot.append(self.GetChild("quick_slot_1")) self.quickslot.append(self.GetChild("quick_slot_2")
Kod:
self.cooldownText = [] self.cooldownText.append(self.GetChild("slot_1_cd")) self.cooldownText.append(self.GetChild("slot_2_cd")) self.cooldownText.append(self.GetChild("slot_3_cd")) self.cooldownText.append(self.GetChild("slot_4_cd")) self.cooldownText.append(self.GetChild("slot_f1_cd")) self.cooldownText.append(self.GetChild("slot_f2_cd")) self.cooldownText.append(self.GetChild("slot_f3_cd")) self.cooldownText.append(self.GetChild("slot_f4_cd")) for i in xrange(8): self.cooldownText[i-1].Hide()
Kod:
if player.IsSkillCoolTime(Position):
Kod:
(coolTime, elapsedTime) = player.GetSkillCoolTime(Position) slot.SetSlotCoolTime(slotNumber, coolTime, elapsedTime) cooldownDelay = 0 cooldown = coolTime-elapsedTime+cooldownDelay self.cooldownText[slotNumber].Show() self.cooldownText[slotNumber].SetText("%d" % cooldown) self.cooldownText[slotNumber].SetOutline() if cooldown < 10: self.cooldownText[slotNumber].SetPosition(7,0) elif cooldown > 9 and cooldown < 100: self.cooldownText[slotNumber].SetPosition(2,0) elif cooldown > 99: self.cooldownText[slotNumber].SetPosition(-1,0)
Kod:
elif not player.IsSkillCoolTime(Position): self.cooldownText[slotNumber].Hide()
Kod:
def OnUpdate(self):
Altına ekle;
Kod:
startNumber = 0 for slot in self.quickslot: for i in xrange(4): slotNumber = i+startNumber self.cooldownText[slotNumber].Hide() (Type, Position) = player.GetLocalQuickSlot(slotNumber) if player.IsSkillCoolTime(Position): (coolTime, elapsedTime) = player.GetSkillCoolTime(Position) slot.SetSlotCoolTime(slotNumber, coolTime, elapsedTime) cooldownDelay = 0 cooldown = int(coolTime-elapsedTime+cooldownDelay) if app.IsPressed(app.DIK_LALT): self.cooldownText[slotNumber].Hide() else: self.cooldownText[slotNumber].SetOutline() self.cooldownText[slotNumber].SetText("%d" % cooldown) cooldown = str(cooldown) self.cooldownText[slotNumber].SetPosition((7, 2, -1)[len(cooldown)-1], 0) self.cooldownText[slotNumber].Show() startNumber += 4
Silkroad Online Tarzı Skill Sayaç Sistemi
Metin2 özel sunucularında geliştirme yaparken, oyuncuların beceri kullanımını takip eden dinamik sistemler oluşturmak büyük önem taşır. Özellikle PvP odaklı sunucularda, yeteneklerin zamanlaması ve tekrar kullanılabilirlik süresi (cooldown) gibi detaylar oyun deneyimini ciddi anlamda etkileyebilir. Bu bağlamda Silkroad Online'dan esinlenilen bir Skill Sayaç Sistemi, hem stratejik derinlik sağlar hem de oyuncu etkileşimini artırır.
Skill Sayaç Sistemi Nedir?
Skill sayaç sistemi, oyuncunun kullandığı yeteneklerin belirli bir süre boyunca takip edilmesini ve bu yeteneklerin tekrar kullanılabilirliğini kontrol eden bir yapıdır. Silkroad Online'da bu sistem, oyuncuların yeteneklerini stratejik olarak planlamasını gerektirir. Örneğin, güçlü bir saldırı yeteneğini kullandıktan sonra belirli bir süre boyunca bu yeteneği kullanamazsınız; bu da rakibinizin bu süreyi değerlendirmesi veya sizin defansif bir pozisyona çekilmeniz anlamına gelir.
Sistem Nasıl Çalışır?
Sistem, her yetenek için bir sayaç başlatır. Yetenek kullanıldığında sayaç devreye girer ve yeteneğin tekrar kullanılabilmesi için gerekli olan süreyi saymaya başlar. Bu sayaç, kullanıcı arayüzünde (UI) görsel bir şekilde gösterilir. Oyuncu, yeteneğin cooldown süresinin bitmesini beklemek zorundadır. Bu sayaçlar genellikle Python GUI ya da UIScript ile geliştirilen arayüzlerde yer alır ve gerçek zamanlı olarak güncellenir.
C++ Kaynak Kod ile Uygulama
Metin2 özel sunucularında bu sistemi uygulamak için game server programming bilgisi gereklidir. Yetenek kullanımını izlemek ve sayaçları başlatmak için server src üzerinde değişiklik yapılması gerekir. Yetenek kullanımı sırasında bir event tetiklenir ve ilgili skillin cooldown süresi veritabanında (DB) ya da bellekte saklanır. Py Root üzerinden bu veriler client tarafına aktarılır ve kullanıcıya aktif sayaçlar hakkında bilgi verilir.
Oyun Dengeleme ve PvP Etkisi
Skill sayaç sistemi, oyuncuların yeteneklerini dikkatli kullanmasını zorunlu kılar. Bu da PvP savaşlarında daha stratejik ve dikkatli bir oynanış ortamı yaratır. Oyuncular, güçlü yeteneklerini savunma veya kaçış anlarında değil, en etkili şekilde kullanabilmek için planlamalıdır. Bu sistem sayesinde oyuncuların beceri seviyesi, sadece karakter gücü değil, aynı zamanda yetenek zamanlaması ile de belirlenir.
Sistem Entegrasyonu ve UI Tasarımı
Yetenek sayaçlarının doğru şekilde kullanıcıya gösterilmesi için py GUI ile hazırlanmış arayüzler gereklidir. Her yetenek simgesinin altında bir sayaç çubuğu yer alır. Kullanıcı bu çubuk sayesinde yeteneğin ne zaman tekrar kullanılabilir olacağını anlayabilir. Martysama gibi geliştiricilerin sunduğu modül ve sistemler bu süreci kolaylaştırır. Ayrıca source edit işlemleri ile bu sayaçlar isteğe göre özelleştirilebilir.
Sonuç
Silkroad Online tarzı bir skill sayaç sistemi, Metin2 özel sunucularında oyun deneyimini ciddi anlamda artırmaktadır. Hem teknik anlamda hem de oyun mekaniği açısından gelişmiş bir yapıdır. Game Core ve DB Core üzerinde yapılan düzenlemelerle bu sistem stabil bir şekilde entegre edilebilir. Geliştiriciler için bu tarz sistemler, sunucularını rekabetçi kılmada önemli adımlardır.
Silkroad Online Style Skill Counter System
When developing Metin2 private servers, creating dynamic systems that track player skill usage becomes crucial. Especially on PvP-focused servers, details like the timing of abilities and their cooldown periods significantly impact gameplay. In this context, a Skill Counter System inspired by Silkroad Online adds strategic depth and increases player engagement.
What Is a Skill Counter System?
The skill counter system tracks each ability used by a player and controls its reusability. In Silkroad Online, this system forces players to strategically plan their skills. For example, after using a powerful attack skill, you cannot reuse it for a specific duration—this could mean your opponent has a chance to act or you must retreat defensively.
How Does the System Work?
The system starts a timer for each skill upon use. Once activated, the timer counts down until the skill becomes usable again. These timers are visually displayed in the user interface (UI), usually developed with Python GUI or UIScript, updating in real-time.
Implementation with C++ Source Code
To implement this system on Metin2 private servers, knowledge of game server programming is required. Modifications must be made to the server src to monitor skill usage and start timers. When a skill is used, an event triggers and the cooldown duration is stored in the database (DB) or memory. This data is transferred to the client side via Py Root, providing active counter information to the player.
Game Balance and PvP Impact
The skill counter system forces players to use their abilities carefully. This creates a more strategic and thoughtful PvP environment. Players must plan when to use powerful skills—not just during defense or escape, but at the most effective moments. With this system, a player's skill level depends not only on character power but also on ability timing.
System Integration and UI Design
To properly display skill counters to the user, interfaces built with py GUI are needed. Each skill icon has a countdown bar underneath, allowing players to see when the skill will become available again. Modules and systems provided by developers like Martysama make this process easier. Additionally, source edit operations allow these counters to be customized according to need.
Conclusion
A Silkroad-style skill counter system greatly enhances the gameplay experience on Metin2 private servers. It represents an advanced structure both technically and mechanically. Through modifications to Game Core and DB Core, this system can be integrated stably. For developers, such systems are essential steps toward making servers more competitive.
