Süt Eventi Skripti | Yeni Event Türü |

Mesajlar
107
En iyi cevaplar
1
Beğeniler
31
Puanları
250
Ruh hali
Herkeze Merhaba,
1 ay önce yapmış olduğum bu süt eventi skriptini paylaşmak istiyorum. Bu eventteki amaç, event başladığında inekleri sağarak en çok litreye ulaşmaktır. (İnekler leveline göre süt vermektedir.) İnekleri sağmak için ineğe sağ tıklamanız yeterlidir. Eventi yapmadan önce belirlenen yere "sutevent" adlı bir wg atmak lazımdır (tavsiye edilen : expand vert). Dilerseniz tanıtım bölümüne geçelim.

KOMUTLAR

Kod:
/sütevent - Süt eventi komutları hakkında bilgi verir.
/sütevent yer-ayarla/setspawn - Süt eventi başladığında ineklerin doğacağı yeri belirler.
/sütevent başlat - Eventi başlatır.
/sütevent durdur - Eventi zorla durdurur.
/sütevent sil - Event bittiğinde kalan inekleri siler.

Gerekli olan pluginler
Skript
SkQuery
SkRayFall

Not: Skript 1.8 sürümünde denenmiştir.


KOD
Kod:
options:
    odul.id: iron_ingot
    odul.sayi: 16
    inek.ad: &dInek



variables:
    {sut_lt::*} = 0
    {sutevent} = false
    {yer_belirle} = false
    {countdown::*} = false
    {acildi.event} = false



on right click on cow:
    if {sutevent} is true:
        if "%region at player%" contains "sutevent":
            set {sagilim::%player%} to true
            if {sagilim::%player%} is true:
                cancel event
                set action bar of player to "&dSağılıyor..."
                wait 1 tick
                set action bar of player to "&aSağıldı!"
                delete event-entity
                set {sagilim::%player%} to false
                wait 2 seconds
            if display name of event-entity contains "&dInek &aLVL 1":
                set {sut_miktar::%player%} to random integer between 1 and 3
                add {sut_miktar::%player%} to {sut_lt::%player%}
                set action bar of player to "&d%{sut_lt::%player%}% &aLitre &7(&a+%{sut_miktar::%player%}%&7)"
                wait 2 seconds
                set action bar of player to ""
            if display name of event-entity contains "&dInek &aLVL 2":
                set {sut_miktar::%player%} to random integer between 3 and 5
                add {sut_miktar::%player%} to {sut_lt::%player%}
                set action bar of player to "&d%{sut_lt::%player%}% &aLitre &7(&a+%{sut_miktar::%player%}%&7)"
                wait 2 seconds
                set action bar of player to ""
            if display name of event-entity contains "&dInek &aLVL 3":
                set {sut_miktar::%player%} to random integer between 4 and 8
                add {sut_miktar::%player%} to {sut_lt::%player%}
                set action bar of player to "&d%{sut_lt::%player%}% &aLitre &7(&a+%{sut_miktar::%player%}%&7)"
                wait 2 seconds
                set action bar of player to ""
            if display name of event-entity contains "&Inek &aLVL 4":
                set {sut_miktar::%player%} to random integer between 6 and 9
                add {sut_miktar::%player%} to {sut_lt::%player%}
                set action bar of player to "&d%{sut_lt::%player%}% &aLitre &7(&a+%{sut_miktar::%player%}%&7)"
                wait 2 seconds
                set action bar of player to ""
            if display name of event-entity contains "&dInek &aLVL 5":
                set {sut_miktar::%player%} to random integer between 8 and 12
                add {sut_miktar::%player%} to {sut_lt::%player%}
                set action bar of player to "&d%{sut_lt::%player%}% &aLitre &7(&a+%{sut_miktar::%player%}%&7)"
                wait 2 seconds
                set action bar of player to ""
            if display name of event-entity contains "&dInek &aLVL 6":
                set {sut_miktar::%player%} to random integer between 12 and 20
                add {sut_miktar::%player%} to {sut_lt::%player%}
                set action bar of player to "&d%{sut_lt::%player%}% &aLitre &7(&a+%{sut_miktar::%player%}%&7)"
                wait 2 seconds
                set action bar of player to ""             
              
on any movement:
    if {sagilim::%player%} is true:
        cancel event
        wait 3 seconds
              

  


command /sütevent [<text>]:
    permission: sutevent.all
    trigger:
        if arg-1 is "başlat":
            if {acildi.event} is false:
                if {yer.ayarla} is true:
                    set {acildi.event} to true
                    broadcast "&d&lSÜT EVENTI &7> &aSüt eventi başlamıştır! &9/warp süteventi"
                    broadcast "&d&lSÜT EVENTI &c&lBILGILENDIRME &7> &aEvent süresi &c1 &adakika'dır"
                    loop 40 times:
                        chance of 50%:
                            wait 5 tick
                            spawn a cow at location of {location}
                            set display name of spawned cow to "&dInek &aLVL 1"
                        chance of 25%:
                            wait 5 tick
                            spawn a cow at location of {location}
                            set display name of spawned cow to "&dInek &aLVL 2"
                        chance of 15%:
                            wait 5 tick
                            spawn a cow at location of {location}
                            set display name of spawned cow to "&dInek &aLVL 3"
                        chance of 6%:
                            wait 5 tick
                            spawn a cow at location of {location}
                            set display name of spawned cow to "&dInek &aLVL 4"
                        chance of 3%:
                            wait 5 tick
                            spawn a cow at location of {location}
                            set display name of spawned cow to "&dInek &aLVL 5"
                        chance of 1%:
                            wait 5 tick
                            spawn a cow at location of {location}
                            set display name of spawned cow to "&dInek &aLVL 6"
                    set {sutevent} to true
                    wait 1 minutes
                    broadcast "&d&lSÜT EVENTI &7> &aEvent bitmiştir. &7İyi oyunlar!"
                    set {sutevent} to false
                    set {_maxValue} to 0
                    loop {sut_lt::*}:
                        set {_player} to loop-index parsed as offline player
                        if {sut_lt::%{_player}%} > {_maxValue}:
                            set {_maxValue} to loop-value
                            set {_maxPlayer} to {_player}
                    delete {sut_lt::*}
                    broadcast "&d&lSÜT EVENTI &7> &eEtkinliğin galibi : &a%{_maxPlayer}%"
                    give player {@odul.sayi} of {@odul.id} named "&dSüt Eventi &7> &fÖdül"
                    loop all players:
                        set {sut_lt::%loop-player%} to 0
                        wait 5 seconds
                        set {sut_lt::%loop-player%} to 0
                    set {acildi.event} to false
                else:
                    send "&c&lHATA &7: &aYer belirlenmemiş! &a/sütevent &dsetspawn/yer-ayarla &a!" to player
            else:
                send "&c&lHATA &7: &aEvent zaten başlamış, bittikten sonra eventi tekrar yapabilirsin :D."
        if arg-1 is "kapat" or "kapa":
            if {sutevent} is true:
                broadcast "&d&lSÜT EVENTI &7> &aEvent kapatıldı! &7İyi oyunlar!"
                set {sutevent} to false
                set {acildi.event} to false
            else:
                send "&cZaten kapalı"
        if arg-1 is "setspawn" or "yer-ayarla":
            set {location} to location of player
            send "&d&lSÜTEVENTI &7> &aSpawn noktası başarıyla belirlendi! &7(%{location}%)" to player
            set {yer.ayarla} to true
        if arg-1 is "inek-sil" or "sil":
            loop all cows:
                if loop-cow's name is "&dInek &aLVL 1" or "&dInek &aLVL 2" or "&dInek &aLVL 3" or "&dInek &aLVL 4" or "&dInek &aLVL 5" or "&dInek &aLVL 6":
                    delete loop-cow
                    send "&cSilindi!"
        if arg-1 is not set:
            send "&7&m|------------ &dSüt Eventi &7&m-------------|" to player
            send "&7> &c/sütevent başlat &7- &aEventi başlatır." to player
            send "&7> &d/sütevent kapat/kapa &7- &aEventi zorla kapatır" to player
            send "&7> &d/sütevent sil &7- &aKalan inekleri siler!" to player
            send "&7> &d/sütevent yer-ayarla/setspawn &7- &aİneklerin doğacağı yeri belirler." to player



GÖRSELLER
124440

124441

124442


124439

124444

124445


Konumuz bu kadar.
Skripti Geliştirmeyi düşünüyorum. Fikire açığım :D
 


Ekli dosyalar

  • 2019-07-02_10.07.38.png
    2019-07-02_10.07.38.png
    269 KB · Görüntüleme: 302
Son düzenleme:

ToprakM

KEK
Emektar Üye
Mesajlar
440
En iyi cevaplar
49
Beğeniler
661
Puanları
2,375
Ruh hali
İlginç bir konu :1:
Biz danadan süt mü sağıyoruz şimdi :ciddi:
 

Ragnarak

Bedrock Kaşifi
Mesajlar
1,722
En iyi cevaplar
0
Beğeniler
1,430
Puanları
3,390
Benzer bir türünü kodluyordum şimdi alıntı diyecekler ...
 

mhakanki

Kömür Madencisi
Mesajlar
138
En iyi cevaplar
0
Beğeniler
43
Puanları
230
fikir çok güzel ama ded,iğiniz gibi çalışmıyor çok sıkıntısı var
 

Üst