# --- AYARLAR BÖLÜMÜ ---
# Buradaki değerleri istediğin gibi değiştirebilirsin.
options:
prefix: &6[Bounty] &e
# YENİ: Oyuncuların oyuna başlarken alacağı bounty miktarı
baslangic-bounty: 100
# MythicMobs ile entegrasyon için mobun tam adı (renk kodlarıyla birlikte)
zindan-mob-adi: "&cZindan Golemi"
# Bu mobu kesince kazanılacak bounty miktarı
zindan-mob-kazanc: 500
# --- DEĞİŞKENLER VE PLACEHOLDER ---
# Oyuncuların bounty'sini saklamak için değişken
variables:
{bounty::%player's uuid%} = 0
# PlaceholderAPI için kendi placeholder'ımızı kaydediyoruz
on load:
if class "me.clip.placeholderapi.PlaceholderAPI" is loaded:
register placeholder "bounty_mevcut" with identifier "bounty":
set return value to "%{bounty::%player's uuid%}%" without colors
log "{@prefix} PlaceholderAPI için %bounty_mevcut% placeholder'ı başarıyla kaydedildi."
else:
log "{@prefix} &cPlaceholderAPI bulunamadı! Bounty değeri gösterilemeyecek."
# DEĞİŞTİ: Oyuncu ilk kez girdiğinde başlangıç bounty'sini ayarla
on first join:
set {bounty::%player's uuid%} to {@baslangic-bounty}
# --- ANA MEKANİKLER ---
# Oyuncu bir oyuncuyu öldürdüğünde...
on death of a player:
# Eğer katil de bir oyuncuysa devam et
if attacker is a player:
set {_victim_bounty} to {bounty::%victim's uuid%}
if {_victim_bounty} is not set or {_victim_bounty} < 0:
set {_victim_bounty} to 0
# DEĞİŞTİ: Katil artık kurbanın bountysinin yarısını kazanır.
# Küsuratlı sayı olmaması için sonucu aşağı yuvarlıyoruz (floor).
set {_bounty_kazanci} to floor({_victim_bounty} / 2)
# Katile, ölen kişinin bounty'si kadar para ver (Bu kısım aynı kaldı)
add {_victim_bounty} to attacker's balance
# Katilin bounty'sine hesaplanan ödülü ekle
add {_bounty_kazanci} to {bounty::%attacker's uuid%}
# DEĞİŞTİ: Ölen oyuncunun bounty'si başlangıç değerine sıfırlanır.
set {bounty::%victim's uuid%} to {@baslangic-bounty}
# Bilgilendirme mesajları güncellendi
send "{@prefix} &a%victim%&e adlı oyuncuyu öldürdün!" to attacker
send "{@prefix} &a%{_victim_bounty}% para&e ve &a%{_bounty_kazanci}% bounty&e kazandın!" to attacker
send "{@prefix} &c%attacker%&e tarafından öldürüldün ve bounty'n &c%{@baslangic-bounty}%&e değerine düşürüldü." to victim
# MythicMobs entegrasyonu: Bir canavar öldüğünde...
# Bu kısımda bir değişiklik yok, eskisi gibi çalışıyor.
on death of a monster:
if attacker is a player:
if name of victim is "{@zindan-mob-adi}":
add {@zindan-mob-kazanc} to {bounty::%attacker's uuid%}
send "{@prefix} &bZindan yaratığını&e yendin ve &a%{@zindan-mob-kazanc}%&e bounty kazandın!" to attacker
# --- KOMUTLAR ---
# Komutlarda bir değişiklik yok, eskisi gibi çalışıyor.
command /bounty [<text>] [<player>] [<integer>]:
trigger:
if arg-1 is not set or arg-1 is "bak" or arg-1 is "göster":
if arg-2 is not set:
send "{@prefix} Mevcut bounty'n: &a%{bounty::%player's uuid%}%"
else:
if player has permission "bounty.admin":
send "{@prefix} &6%arg-2%&e adlı oyuncunun bounty'si: &a%{bounty::%arg-2's uuid%}%"
else:
send "{@prefix} Başkasının bounty'sine bakma yetkin yok."
else if arg-1 is "yardım":
send "&6--- Bounty Sistemi Komutları ---"
send "&e/bounty bak [<oyuncu>] &7- Kendi veya başkasının bounty'sine bakarsın."
if player has permission "bounty.admin":
send "&c/bounty ayarla <oyuncu> <miktar> &7- Oyuncunun bounty'sini ayarlar."
send "&c/bounty ekle <oyuncu> <miktar> &7- Oyuncunun bounty'sine ekleme yapar."
send "&c/bounty sıfırla <oyuncu> &7- Oyuncunun bounty'sini sıfırlar."
else if arg-1 is "ayarla":
if player has permission "bounty.admin":
if arg-2 is set and arg-3 is set:
set {bounty::%arg-2's uuid%} to arg-3
send "{@prefix} &6%arg-2%&e adlı oyuncunun bounty'si &a%arg-3%&e olarak ayarlandı."
else:
send "{@prefix} &cKullanım: /bounty ayarla <oyuncu> <miktar>"
else:
send "{@prefix} &cBu komutu kullanma yetkin yok."
else if arg-1 is "ekle":
if player has permission "bounty.admin":
if arg-2 is set and arg-3 is set:
add arg-3 to {bounty::%arg-2's uuid%}
send "{@prefix} &6%arg-2%&e adlı oyuncunun bounty'sine &a%arg-3%&e eklendi."
else:
send "{@prefix} &cKullanım: /bounty ekle <oyuncu> <miktar>"
else:
send "{@prefix} &cBu komutu kullanma yetkin yok."
else if arg-1 is "sıfırla":
if player has permission "bounty.admin":
if arg-2 is set:
set {bounty::%arg-2's uuid%} to {@baslangic-bounty}
send "{@prefix} &6%arg-2%&e adlı oyuncunun bounty'si başlangıç değerine (&a%{@baslangic-bounty%}&e) sıfırlandı."
else:
send "{@prefix} &cKullanım: /bounty sıfırla <oyuncu>"
else:
send "{@prefix} &cBu komutu kullanma yetkin yok."