- Katılım
- 18 Ağustos 2017
- Mesajlar
- 294
- Elmaslar
- 86
- Puanlar
- 9.220
merhaba arkadaşlar, forumda otomatik satış skripti buldum. kendimce düzenleyip birşeyler yaptım fakat bilgim çok fazla olmadığı için permission ve permission message ekleyemedim. şu skript'e nasıl permission ve permission message ekleyebilirim?
ayrıca gui'de 49. bölüme nasıl geri dön butonu ekleyebilirim? tıkladığında "menü" komutunu çalıştıracak?
ayrıca gui'de 49. bölüme nasıl geri dön butonu ekleyebilirim? tıkladığında "menü" komutunu çalıştıracak?
Kod:
options:
p: &3Factions &8&l►
# cevherler
otolapisfiyat: 100
otolapisadet: 64
otodemirfiyat: 100
otodemiradet: 64
otoaltınfiyat: 100
otoaltınadet: 64
otoelmasfiyat: 100
otoelmasadet: 64
otozümrütfiyat: 100
otozümrütadet: 64
# bloklar
otolapisblokfiyat: 100
otolapisblokadet: 64
otodemirblokfiyat: 100
otodemirblokadet: 64
otoaltınblokfiyat: 100
otoaltınblokadet: 64
otoelmasblokfiyat: 100
otoelmasblokadet: 64
otozümrütblokfiyat: 100
otozümrütblokadet: 64
quit:
set {otosat::%player%::lapis}, {otosat::%player%::demir}, {otosat::%player%::altın}, {otosat::%player%::elmas}, {otosat::%player%::lapisblok}, {otosat::%player%::demirblok}, {otosat::%player%::altınblok}, {otosat::%player%::elmasblok}, {otosat::%player%::zümrütblok} or {otosat::%player%::zümrüt} to "KAPALI"
join:
while player is online:
wait a second
if {otosat::%player%::lapis} is "AÇIK":
if player has {@otolapisadet} lapis:
remove {@otolapisadet} lapis from player's inventory
send "{@p} &f{@otolapisadet} &7adet Lapis Lazuli &f{@otolapisfiyat} TL&7'ye &7satılmıştır."
add {@otolapisfiyat} to player's money
if {otosat::%player%::demir} is "AÇIK":
if player has {@otodemiradet} iron ingot:
remove {@otodemiradet} iron ingot from player's inventory
send "{@p} &f{@otodemiradet} &7adet Demir &f{@otodemirfiyat} TL&7'ye &7satılmıştır."
add {@otodemirfiyat} to player's money
if {otosat::%player%::altın} is "AÇIK":
if player has {@otoaltınadet} gold ingot:
remove {@otoaltınadet} gold ingot from player's inventory
send "{@p} &f{@otoaltınadet} &7adet &6Altın &f{@otoaltınfiyat} TL&7'ye &7satılmıştır."
add {@otoaltınfiyat} to player's money
if {otosat::%player%::elmas} is "AÇIK":
if player has {@otoelmasadet} diamond:
remove {@otoelmasadet} diamond from player's inventory
send "{@p} &f{@otoelmasadet} &7adet &bElmas &f{@otoelmasfiyat} TL&7'ye &7satılmıştır."
add {@otoelmasfiyat} to player's money
if {otosat::%player%::zümrüt} is "AÇIK":
if player has {@otozümrütadet} emerald:
remove {@otozümrütadet} emerald from player's inventory
send "{@p} &f{@otozümrütadet} &7adet &aZümrüt &f{@otozümrütfiyat} TL&7'ye &7satılmıştır."
add {@otozümrütfiyat} to player's money
if {otosat::%player%::lapisblok} is "AÇIK":
if player has {@otolapisblokadet} 22:
remove {@otolapisblokadet} 22 from player's inventory
send "{@p} &f{@otolapisblokadet} &7adet &9Lapis bloğu &f{@otolapisblokfiyat} TL&7'ye &7satılmıştır."
add {@otolapisblokfiyat} to player's money
if {otosat::%player%::demirblok} is "AÇIK":
if player has {@otodemirblokadet} 42:
remove {@otodemirblokadet} 42 from player's inventory
send "{@p} &f{@otodemirblokadet} &7adet &7Demir bloğu &f{@otodemirblokfiyat} TL&7'ye &7satılmıştır."
add {@otodemirblokfiyat} to player's money
if {otosat::%player%::altınblok} is "AÇIK":
if player has {@otoaltınblokadet} 41:
remove {@otoaltınblokadet} 41 from player's inventory
send "{@p} &f{@otoaltınblokadet} &7adet &eAltın bloğu &f{@otoaltınblokfiyat} TL&7'ye &7satılmıştır."
add {@otolapisblokfiyat} to player's money
if {otosat::%player%::elmasblok} is "AÇIK":
if player has {@otoelmasblokadet} 57:
remove {@otoelmasblokadet} 57 from player's inventory
send "{@p} &f{@otoelmasblokadet} &7adet &bElmas bloğu &f{@otoelmasblokfiyat} TL&7'ye &7satılmıştır."
add {@otoelmasblokfiyat} to player's money
if {otosat::%player%::zümrütblok} is "AÇIK":
if player has {@otozümrütblokadet} 133:
remove {@otozümrütblokadet} 133 from player's inventory
send "{@p} &f{@otozümrütblokadet} &7adet &aZümrüt bloğu &f{@otozümrütblokfiyat} TL&7'ye &7satılmıştır."
add {@otozümrütblokfiyat} to player's money
command /otosat2:
trigger:
otosatmenu(player)
function otosatmenu(p: player):
open virtual chest with size 6 named "&8Otomatik Satış Menüsü" to {_p}
make gui slot 10 of {_p} with lapis named "&9Lapis" to nothing
if {otosat::%{_p}%::lapis} is "KAPALI":
make gui slot 19 of {_p} with gray dye named "&9Lapis" with lore "&7Durum: &cKAPALI||&7Açmak için tıklayın." to run function otosatayar({_p}, "aç", "lapis")
else:
make gui slot 19 of {_p} with light green dye named "&9Lapis" with lore "&7Durum: &aAÇIK||&7Kapatmak için tıklayın." to run function otosatayar({_p}, "kapat", "lapis")
make gui slot 13 of {_p} with iron ingot named "&fDemir" to nothing
if {otosat::%{_p}%::demir} is "KAPALI":
make gui slot 22 of {_p} with gray dye named "&fDemir" with lore "&7Durum: &cKAPALI||&7Açmak için tıklayın." to run function otosatayar({_p}, "aç", "demir")
else:
make gui slot 22 of {_p} with light green dye named "&fDemir" with lore "&7Durum: &aAÇIK||&7Kapatmak için tıklayın." to run function otosatayar({_p}, "kapat", "demir")
make gui slot 14 of {_p} with gold ingot named "&6Altın" to nothing
if {otosat::%{_p}%::altın} is "KAPALI":
make gui slot 23 of {_p} with gray dye named "&6Altın" with lore "&7Durum: &cKAPALI||&7Açmak için tıklayın." to run function otosatayar({_p}, "aç", "altın")
else:
make gui slot 23 of {_p} with light green dye named "&6Altın" with lore "&7Durum: &aAÇIK||&7Kapatmak için tıklayın." to run function otosatayar({_p}, "kapat", "altın")
make gui slot 15 of {_p} with diamond named "&bElmas" to nothing
if {otosat::%{_p}%::elmas} is "KAPALI":
make gui slot 24 of {_p} with gray dye named "&bElmas" with lore "&7Durum: &cKAPALI||&7Açmak için tıklayın." to run function otosatayar({_p}, "aç", "elmas")
else:
make gui slot 24 of {_p} with light green dye named "&bElmas" with lore "&7Durum: &aAÇIK||&7Kapatmak için tıklayın." to run function otosatayar({_p}, "kapat", "elmas")
make gui slot 16 of {_p} with emerald named "&aZümrüt" to nothing
if {otosat::%{_p}%::zümrüt} is "KAPALI":
make gui slot 25 of {_p} with gray dye named "&aZümrüt" with lore "&7Durum: &cKAPALI||&7Açmak için tıklayın." to run function otosatayar({_p}, "aç", "zümrüt")
else:
make gui slot 25 of {_p} with light green dye named "&aZümrüt" with lore "&7Durum: &aAÇIK||&7Kapatmak için tıklayın." to run function otosatayar({_p}, "kapat", "zümrüt")
make gui slot 28 of {_p} with 22 named "&9Lapis Bloğu" to nothing
if {otosat::%{_p}%::lapisblok} is "KAPALI":
make gui slot 37 of {_p} with gray dye named "&9Lapis Bloğu" with lore "&7Durum: &cKAPALI||&7Açmak için tıklayın." to run function otosatayar({_p}, "aç", "lapisblok")
else:
make gui slot 37 of {_p} with light green dye named "&9Lapis Bloğu" with lore "&7Durum: &aAÇIK||&7Kapatmak için tıklayın." to run function otosatayar({_p}, "kapat", "lapisblok")
make gui slot 31 of {_p} with 42 named "&7Demir Bloğu" to nothing
if {otosat::%{_p}%::demirblok} is "KAPALI":
make gui slot 40 of {_p} with gray dye named "&7Demir Bloğu" with lore "&7Durum: &cKAPALI||&7Açmak için tıklayın." to run function otosatayar({_p}, "aç", "demirblok")
else:
make gui slot 40 of {_p} with light green dye named "&7Demir Bloğu" with lore "&7Durum: &aAÇIK||&7Kapatmak için tıklayın." to run function otosatayar({_p}, "kapat", "demirblok")
make gui slot 32 of {_p} with 41 named "&eAltın Bloğu" to nothing
if {otosat::%{_p}%::altınblok} is "KAPALI":
make gui slot 41 of {_p} with gray dye named "&eAltın Bloğu" with lore "&7Durum: &cKAPALI||&7Açmak için tıklayın." to run function otosatayar({_p}, "aç", "altınblok")
else:
make gui slot 41 of {_p} with light green dye named "&eAltın Bloğu" with lore "&7Durum: &aAÇIK||&7Kapatmak için tıklayın." to run function otosatayar({_p}, "kapat", "altınblok")
make gui slot 33 of {_p} with 57 named "&bElmas Bloğu" to nothing
if {otosat::%{_p}%::elmasblok} is "KAPALI":
make gui slot 42 of {_p} with gray dye named "&bElmas Bloğu" with lore "&7Durum: &cKAPALI||&7Açmak için tıklayın." to run function otosatayar({_p}, "aç", "elmasblok")
else:
make gui slot 42 of {_p} with light green dye named "&bElmas Bloğu" with lore "&7Durum: &aAÇIK||&7Kapatmak için tıklayın." to run function otosatayar({_p}, "kapat", "elmasblok")
make gui slot 34 of {_p} with 133 named "&aZümrüt Bloğu" to nothing
if {otosat::%{_p}%::zümrütblok} is "KAPALI":
make gui slot 43 of {_p} with gray dye named "&aZümrüt Bloğu" with lore "&7Durum: &cKAPALI||&7Açmak için tıklayın." to run function otosatayar({_p}, "aç", "zümrütblok")
else:
make gui slot 43 of {_p} with light green dye named "&aZümrüt Bloğu" with lore "&7Durum: &aAÇIK||&7Kapatmak için tıklayın." to run function otosatayar({_p}, "kapat", "zümrütblok")
function otosatayar(p: player, text: text, isim: text):
if {_text} is "AÇ":
set {otosat::%{_p}%::%{_isim}%} to "AÇIK"
otosatmenu({_p})
else if {_text} is "KAPAT":
set {otosat::%{_p}%::%{_isim}%} to "KAPALI"
otosatmenu({_p})