Yardım Skript'te Belli bir chest birleşmesini engelleme YARDIM!

KaralardanTR

Play.Rebornas.Com | Founder
En iyi cevaplar
1
Kod:
on place of chest or trapped chest:
    if name of player's held item is "&cSatış Sandığı":
        if {sandikhakki::%player%} is false:   
            set {satissandik::%player%} to location of event-block
            send "{@p} &aBaşarıyla &cSatış Sandığı &ayerleştirdin! %{satissandiketrafi::%player%}%" to player
            set {sandikhakki::%player%} to true       
        else:
            cancel event
            send "{@p} &cBaşarısız zaten &cSatış Sandığı &cyerleştirmişsin!" to player

Böyle bir şey yaptım ve bunun başka normal bir chest ile birleşmesini engellemek istiyorum, Örnek olarak 2 blok yarı çapına chest koyma engellenebilir ama ben bi türlü yapamadım onu yapabilen lütfen acil yapıp atarsa sevinirim.
 

Risepixel

Taş Madencisi
En iyi cevaplar
6
Kod:
loop all blocks in radius 3 around location of block 1 above event-location:
    if loop-block is chest:
 

Risepixel

Taş Madencisi
En iyi cevaplar
6
verdiğiniz kodu denedim fakat çalışıyor eyvallah ama neresine koyucağımı anlamadım if öncesine mi else sonrasına mı vs.
Kod:
on place of chest or trapped chest:
    set {_ChestSayaci} to 0
    loop all blocks in radius 3 around location of block 1 above event-location:
        if loop-block is chest:
            add 1 to {_ChestSayaci}
        if {_ChestSayaci} is equal to 0:
            if name of player's held item is "&cSatış Sandığı":
[/CODE]

Burdan sonra kendi kodunu ekle
 

KaralardanTR

Play.Rebornas.Com | Founder
En iyi cevaplar
1
Kod:
on place of chest or trapped chest:
    set {_ChestSayaci} to 0
    loop all blocks in radius 3 around location of block 1 above event-location:
        if loop-block is chest:
            add 1 to {_ChestSayaci}
        if {_ChestSayaci} is equal to 0:
            if name of player's held item is "&cSatış Sandığı":
[/CODE]

Burdan sonra kendi kodunu ekle
Öğlen pc geçince deniyeceğim.
 

KaralardanTR

Play.Rebornas.Com | Founder
En iyi cevaplar
1
Kod:
on place of chest or trapped chest:
    set {_ChestSayaci} to 0
    loop all blocks in radius 3 around location of block 1 above event-location:
        if loop-block is chest:
            add 1 to {_ChestSayaci}
        if {_ChestSayaci} is equal to 0:
            if name of player's held item is "&cSatış Sandığı":
[/CODE]

Burdan sonra kendi kodunu ekle
hiçbir yere cancel event çekmemişsin yani onun etrafına yine chest koyunca koyuluyor.
 
Üst