【LUA】🌟OYUN İÇİ NPCDEN EP MARKET QUESTİ 🌟

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

Admin

Metin2Lobby
Yönetici
Founder
Katılım
6 Mayıs 2022
Mesajlar
52,647
Ticaret : 1 / 0 / 0
123.png

Sistem aslında Basit !

EP İle Satacağınız Ürünleri NPC'ye ekliyorsunuz ! NPC Size EP Karşılığında İtemi Verecektir !

Yetersiz EP Oldugu durumlarda size bildiri mesajı verecektir !


Metin2 Lobby
【LUA】🌟OYUN İÇİ NPCDEN EP MARKET QUESTİ 🌟

Metin2 sunucularında oyun içi deneyimi zenginleştirmek için quest sistemleri kritik öneme sahiptir. Özellikle LUA tabanlı questler, geliştiricilerin oyun içi görevleri özelleştirmesine olanak tanır. Bu yazıda, NPC üzerinden başlatılan EP Market Quest sistemini detaylı olarak ele alacağız. Metin2 Lobby olarak bu konuda teknik bilgiyi sade bir dille aktarmayı hedefliyoruz.

EP Market Nedir?
EP (Event Point), Metin2 oyununda oyuncuların belirli görevleri tamamlayarak kazandığı puanlardır. Bu puanlar genellikle özel marketler aracılığıyla çeşitli ödüllerle takas edilebilir. EP Market Quest, oyuncuların bu puanları kazanmak için belirli görevleri yapmasını sağlayan bir.quest sistemidir.

Quest Sisteminin Oluşturulması
Bir quest oluşturmak için genellikle bir LUA script dosyasına ihtiyaç duyarız. Bu scriptte, oyuncu NPC ile etkileşim kurduğunda başlatılacak olan görev tanımlanır. Bu görevin adımları şunlar olabilir:

- Oyuncu NPC ile konuşur.
- NPC, oyuncuya görev açıklamasını verir.
- Oyuncu görevi kabul eder.
- Görev tamamlandığında oyuncuya EP puanı verilir.

Script Örneği
Aşağıda basit bir LUA quest scripti örneği yer almaktadır. Bu script, oyuncu NPC ile etkileşime girdiğinde çalışacak ve görevi başlatıp ödül verecektir.

Kod:
[BR][/BR]quest ep_market_quest begin[BR][/BR]    state start begin[BR][/BR]        when 100000.click with pc.get_level() >= 30 begin[BR][/BR]            say_title('EP Market Quest')[BR][/BR]            local s = select('Görevi başlat', 'EP Puanını kontrol et', 'İptal')[BR][/BR]            if s == 1 then[BR][/BR]                say('Bu görevi tamamlamak icin 5 adet Monster slain!')[BR][/BR]                set_state('progress')[BR][/BR]            elseif s == 2 then[BR][/BR]                say('Mevcut EP Puaniniz: ' .. get_ep_points()) [BR][/BR]            end[BR][/BR]        end[BR][/BR]    end[BR][/BR]    state progress begin[BR][/BR]        when kill begin[BR][/BR]            local current_kills = getf('ep_kills', 'count', 0)[BR][/BR]            if current_kills < 5 then[BR][/BR]                setf('ep_kills', 'count', current_kills + 1)[BR][/BR]            else[BR][/BR]                set_ep_points(get_ep_points() + 100)[BR][/BR]                chat('Tebrikler! 100 EP kazandiniz!')[BR][/BR]                set_state('start')[BR][/BR]            end[BR][/BR]        end[BR][/BR]    end[BR][/BR]end[BR][/BR]


NPC ile Etkileşim
NPC üzerinden başlatılan bu gibi questler, oyuncuların görev sistemine daha aktif katılması için önemlidir. NPC'nin dialog penceresi üzerinden görev açıklaması, hedefler ve ödül bilgisi sunulmalıdır. Bu sayede oyuncu, görevin ne olduğunu net bir şekilde anlayabilir.

Debug ve Test Süreci
Quest yazımı sırasında hatalarla karşılaşılabilir. Quest debug işlemleri için log kayıtlarını incelemek ve test sunucusunda görevi çalıştırmak oldukça faydalıdır. Ayrıca, Metin2Dev veya MartySama gibi platformlardan örnek scriptler alarak kendi questlerinizi geliştirebilirsiniz.

Sonuç[/BR][/BR]Oyun içi quest sistemleri, oyuncuların sunucuya olan bağlılığını artırmak için kritik öneme sahiptir. EP Market Quest gibi sistemler, oyunculara ödülleri doğrudan sunarak motivasyon sağlar. LUA scriptleri ile özelleştirilebilen bu yapılar, Metin2 sunucularının gelişimine katkı sağlar. Metin2 Lobby olarak bizler de bu gibi içerikleri desteklemeye devam edeceğiz.


Metin2 Lobby
【LUA】🌟EP MARKET QUEST FROM IN-GAME NPC 🌟

Metin2 servers enhance gameplay experience through quest systems. Especially LUA-based quests allow developers to customize in-game missions. In this article, we will examine the EP Market Quest system launched via NPC in detail. As Metin2 Lobby, we aim to present technical information in a simple way.

What is EP Market?
EP (Event Point) is a type of point that players earn by completing specific tasks in Metin2. These points are usually exchanged for various rewards through special markets. EP Market Quest is a quest system allowing players to earn these points by completing tasks.

Creating the Quest System
To create a quest, you typically need a LUA script file. In this script, the mission triggered when the player interacts with an NPC is defined. Steps might include:

- Player talks to the NPC.
- NPC gives the mission description.
- Player accepts the quest.
- EP points are awarded upon completion.

Script Example
Below is a basic LUA quest script example. It triggers when the player interacts with the NPC and awards points upon completion.

Kod:
[BR][/BR]quest ep_market_quest begin[BR][/BR]    state start begin[BR][/BR]        when 100000.click with pc.get_level() >= 30 begin[BR][/BR]            say_title('EP Market Quest')[BR][/BR]            local s = select('Start Quest', 'Check EP Points', 'Cancel')[BR][/BR]            if s == 1 then[BR][/BR]                say('Complete 5 monster kills to finish this quest!')[BR][/BR]                set_state('progress')[BR][/BR]            elseif s == 2 then[BR][/BR]                say('Current EP Points: ' .. get_ep_points()) [BR][/BR]            end[BR][/BR]        end[BR][/BR]    end[BR][/BR]    state progress begin[BR][/BR]        when kill begin[BR][/BR]            local current_kills = getf('ep_kills', 'count', 0)[BR][/BR]            if current_kills < 5 then[BR][/BR]                setf('ep_kills', 'count', current_kills + 1)[BR][/BR]            else[BR][/BR]                set_ep_points(get_ep_points() + 100)[BR][/BR]                chat('Congratulations! You earned 100 EP!')[BR][/BR]                set_state('start')[BR][/BR]            end[BR][/BR]        end[BR][/BR]    end[BR][/BR]end[BR][/BR]


Interaction with NPC
Quests initiated from NPCs are crucial for encouraging active participation. The dialog window should clearly explain the quest objectives, rewards, and steps, helping the player understand the task at hand.

Debugging and Testing Process
Errors may occur during quest creation. Reviewing logs and testing on a test server can be helpful for quest debugging. Additionally, you can take sample scripts from platforms like Metin2Dev or MartySama to enhance your own quests.

Conclusion
In-game quest systems are vital for increasing player engagement and loyalty. Systems like EP Market Quest motivate players by offering direct rewards. Customizable structures through LUA scripts contribute to the development of Metin2 servers. As Metin2 Lobby, we will continue supporting such content.
 

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

Geri
Üst Alt