System tombola

  • Konbuyu başlatan Konbuyu başlatan Admin
  • Başlangıç tarihi Başlangıç tarihi
  • Cevaplar Cevaplar 0
  • Görüntüleme Görüntüleme 31

Admin

Metin2Lobby
Yönetici
Founder
Katılım
6 Mayıs 2022
Mesajlar
52,647
Ticaret : 1 / 0 / 0
1. Add uitombola.py in root
2. Add click4metin in locale
3. In locale_game.txt add:
TITLE_TOMBOLA→Tombola
In constinfo.py add:
wndTombola = None
TOMBOLA = 0
In game.py add:
import uiTombola
Search:
self.interface.ShowDefaultWindows()
Add:
constInfo.wndTombola = uiTombola.TombolaWindow()
Search:
guild.Destroy()
Add:
constInfo.wndTombola.Close()
After:
→def OnPressEscapeKey(self):
→→if app.TARGET == app.GetCursor():
→→→app.SetCursor(app.NORMAL)
Add:
→→if constInfo.wndTombola.IsShow():
→→→constInfo.wndTombola.Close()
Search:
"PlayMusic" : self.__PlayMusic,
Add:
#Tombola System
"OnPrepare" : self.__PrepareTombola,
"OnRun" : self.__RunTombola,
"openTombola" : self.__OpenTombola,
"closeTombola" : self.__CloseTombola,
"tombola" : self.SetTombola,
"get_input_value" : self.GetInputValue,
"get_input_start" : self.GetInputOn,
"get_input_end" : self.GetInputOff,
#End Tombala System
After:
def BINARY_ServerCommand_Run(self, line):
Add:
→def __OpenTombola(self):
→→→constInfo.wndTombola.Open()

→def __PrepareTombola(self, data):
→→constInfo.wndTombola.OnPrepare(str(data))

→def __RunTombola(self, number):
→→constInfo.wndTombola.OnRun(str(number))

→def SetTombola(self, qid):
→→constInfo.TOMBOLA = int(qid)

→def __CloseTombola(self):
→→constInfo.wndTombola.Close()

[glow=red]Error resolution[/glow]
syerr: Unknown Server Command get_input_start | get_input_start
In game.py Search:
def OpenQuestWindow(self, skin, idx):
Add:
→→if constInfo.INPUT_IGNORE == 1:
→→→return
Syserr1.jpg

Search:
def __ServerCommand_Build(self):
Add:
→→→"getinputbegin"→→→→: self.__Inputget1,
→→→"getinputend"→→→→: self.__Inputget2,
Add to the end:
→def __Inputget1(self):
→→constInfo.INPUT_IGNORE = 1
→ def __Inputget2(self):
→→constInfo.INPUT_IGNORE = 0

Open constinfo.py
Add:
INPUT_IGNORE = 0

Open uiquest.py
Search:
def __init__(self,skin,idx):
Add:
→→import constInfo
→→if constInfo.INPUT_IGNORE == 1:
→→→return
Syserr3.jpg


Quest:
Kod:
quest tombola begin     state start begin         function tablica(vnum, pozitie, pozitie2)             local itemy = {                             {                                 {25041, 1},                                 {27991, 1},                                 {31022, 1},                                 {31024, 1},                                 {31026, 1},                                 {71015, 1},                                 {27987, 30},                                 {85000, 1},                                 {72703, 1},                                 {72704, 1},                                 {30204, 1},                                 {50512, 1},                                 {81001, 1},                                 {30179, 3},                                 {71123, 1},                                 {71129, 1},                                 {25041, 1},                             },                             {                                 {25041, 1},                                 {27991, 1},                                 {31022, 1},                                 {31024, 1},                                 {31026, 1},                                 {71015, 1},                                 {27987, 30},                                 {85000, 1},                                 {72703, 1},                                 {72704, 1},                                 {30204, 1},                                 {50512, 1},                                 {81001, 1},                                 {30179, 3},                                 {71123, 1},                                 {71129, 1},                                 {25041, 1},                             },                         }                 return itemy[vnum][pozitie][pozitie2]             end                                  when login begin             cmdchat("tombola "..q.getcurrentquestindex())         end                when 33008.chat."Tombola" begin             say_title("Tombola")             say("")             say("Every spin is a winning, so you wont lose in any case.")             say("You need:")             say_item("Golden Ticket", 31012, "")             wait()             local vegas = number(1,2)             local str = " "             for i = 1,16 do                 if i == 16 then                     str = str..tombola.tablica(vegas, i, 1).."|"..tombola.tablica(vegas, i, 2)                 else                     str = str..tombola.tablica(vegas, i, 1).."|"..tombola.tablica(vegas, i, 2).."|"                 end             end             cmdchat("OnPrepare"..str)             cmdchat("openTombola")             setskin(NOWINDOW)         end            when info or button begin             local vegas = number(1,2)             local str = " "             for i = 1,16 do                 if i == 16 then                     str = str..tombola.tablica(vegas, i, 1).."|"..tombola.tablica(vegas, i, 2)                 else                     str = str..tombola.tablica(vegas, i, 1).."|"..tombola.tablica(vegas, i, 2).."|"                 end             end             cmdchat("OnPrepare"..str)             if pc.count_item(31012) < 10 then                 syschat("You don't have enough golden tickets!")                 return             end                        cmdchat("get_input_start")             local intrare = input(cmdchat("get_input_value"))             cmdchat("get_input_end")             if intrare == "tombola|begin" then                 pc.setqf("slot", number(1, 16))                 cmdchat("OnRun "..number(2,3)*16+pc.getqf("slot").."|5")             elseif intrare == "tombola|end" then                 pc.give_item2(tombola.tablica(vegas, pc.getqf("slot")+1, 1), tombola.tablica(vegas, pc.getqf("slot")+1, 2))                 pc.remove_item(31012, 10)             end         end     end end

Metin2 Lobby'de Sistem Tombola: Oyun Deneyimini Zenginleştiren Bir Ödül Mekanizması

Tombola Sistemi Nedir?
Metin2 özel sunucularında oyun içi deneyimi daha keyifli ve sürdürülebilir kılmak adına geliştirilen sistem tombola, oyuncuların belirli görevleri tamamlaması veya belirli zaman dilimlerinde oyunda kalması gibi aktiviteler karşılığında ödül kazanmalarını sağlayan bir mekanizmadır.

Sistem Tombolanın Amacı
Bu sistem, oyuncuların sunucuya olan bağlılığını artırmak ve oyun içi aktiviteleri teşvik etmek amacıyla tasarlanmıştır. Özellikle uzun süreli oyuncu tutulması ve aktif katılımın sağlanması açısından oldukça etkilidir.

Tombola Sisteminin Uygulanışı
Tombola sistemi genellikle C++ tabanlı sunucu tarafında geliştirilir. Python scriptlerle entegre edilebilir ve oyuncuların belirli eylemleri sonrasında rastgele ödüller kazanmasını sağlayabilir. Bu ödüller; eşyalar, para, deneyim puanları ya da özel statüler olabilir.

Metin2 Özel Sunucularında Tombola Entegrasyonu
Metin2 lobby kullanıcıları olarak, tombola sisteminin nasıl çalıştığını ve nasıl entegre edileceğini bilmek önemlidir. Bu sistem genellikle py_root ve uiscript ile arayüz tarafında gösterilirken, backend tarafında db_core ve game_core tarafından desteklenir. Auth ve game sunucuları arasında senkronizasyon sağlanarak güvenli ve kararlı bir yapı oluşturulur.

C++ Kaynak Kod ve Tombola
Tombola sistemi için C++ kaynak kod üzerinde değişiklikler yapılabilir. Örneğin, belirli bir zaman aralığında oyuncu girişlerine göre sistem tetiklenebilir. Bu sayede sunucuda aktif olan oyunculara otomatik olarak ödül verilebilir. Bu tür sistemlerin güvenliği ve performansı C++ ile optimize edilir.

Python ve GUI ile Tombola Arayüzü
Python tabanlı GUI sistemleri ile tombola menüsü oyunculara görsel olarak sunulabilir. PyGUI kullanılarak tombola ekranı oluşturulabilir. Böylece oyuncular, ödül alma durumlarını takip edebilir ve sisteme etkileşimli olarak ulaşabilirler.

DB ve Game Sunucusuyla Entegrasyon
Tombola sisteminin doğru çalışabilmesi için DB (veritabanı) ile entegrasyon kritik öneme sahiptir. Oyuncu verileri, ödül geçmişi ve tombola aktivasyon zamanlamaları DB üzerinde saklanır. Bu sayede sunucu yeniden başlatıldığında bile veriler korunur.

Tombola Sisteminin Geliştirilmesi
Metin2 geliştiricileri, tombola sistemini farklı sunuculara göre özelleştirebilir. Örneğin, PvP sunucularında belirli harita zaferlerinden sonra tombola tetiklenebilir. Bu tür özelleştirmeler, C++ sistem bilgisi ve Python script bilgisiyle kolayca yapılabilir.

Sonuç
Sistem tombola, Metin2 özel sunucularında oyuncu motivasyonunu artırmak ve sunucu sadakatini güçlendirmek için ideal bir araçtır. Doğru uygulandığında hem oyun içi ekonomiyi destekler hem de oyunculara ekstra bir hedeften ibaret olur. Metin2 lobby olarak, bu tür sistemleri geliştirmek ve paylaşmak bizim ana odak noktamızdır.


System Tombola on Metin2 Lobby: A Reward Mechanism Enriching the Gaming Experience

What is the Tombola System?
Designed to make the gaming experience more enjoyable and sustainable in Metin2 private servers, the system tombola is a mechanism that allows players to win rewards after completing certain quests or staying online for specific periods of time.

Purpose of the Tombola System
This system is designed to increase player loyalty to the server and encourage in-game activities. It is particularly effective in retaining long-term players and ensuring active participation.

Implementation of the Tombola System
The tombola system is typically developed on the C++ based server side. It can be integrated with Python scripts, allowing players to win random rewards after performing specific actions. These rewards may include items, money, experience points, or special statuses.

Tombola Integration in Metin2 Private Servers
As Metin2 lobby users, understanding how the tombola system works and how it is integrated is crucial. This system is usually displayed through py_root and uiscript on the UI side, while being supported by db_core and game_core on the backend. A stable and secure structure is established by synchronizing between auth and game servers.

C++ Source Code and Tombola
Modifications can be made to the C++ source code for the tombola system. For example, the system can be triggered based on player logins within specific time intervals. This way, active players on the server can automatically receive rewards. The security and performance of such systems are optimized with C++.

Tombola Interface with Python and GUI
With Python-based GUI systems, the tombola menu can be visually presented to players. A tombola screen can be created using PyGUI. This allows players to track their reward status and interactively access the system.

Integration with DB and Game Server
Correct functioning of the tombola system critically depends on its integration with the database (DB). Player data, reward history, and tombola activation schedules are stored on the DB. This ensures data integrity even after server restarts.

Development of the Tombola System
Metin2 developers can customize the tombola system according to different servers. For instance, in PvP servers, tombola can be triggered after achieving victories in certain maps. Such customizations can easily be implemented with knowledge of C++ systems and Python scripting.

Conclusion
The system tombola is an ideal tool for increasing player motivation and strengthening server loyalty in Metin2 private servers. When applied correctly, it supports the in-game economy and provides players with an additional goal. At Metin2 lobby, developing and sharing such systems is our main focus.
 

Şuan Bu Konuyu Görüntüleyen Kullanıcılar (Toplam : 0, Üye : 0, Misafir : 0)

Benzer konular

Geri
Üst Alt