mirricraft-skript/mirricraft.sk

224 lines
12 KiB
Plaintext
Raw Normal View History

2020-10-20 01:34:59 +00:00
#--------------------------------------------------
#
# MIRRICRAFT
# by Christer Warén / Warén Group
#
#--------------------------------------------------
2020-10-20 02:08:34 +00:00
2023-04-26 14:44:54 +00:00
on join:
2023-04-29 13:40:54 +00:00
make player execute command "/mirricraft item"
2023-04-26 14:44:54 +00:00
stop
on respawn:
2023-04-29 13:40:54 +00:00
make player execute command "/mirricraft item"
2023-04-26 14:44:54 +00:00
stop
2023-04-29 13:40:54 +00:00
on click:
if event-item is ender chest named "&fMirriCraft":
make player execute command "/mirricraft gui"
cancel the event
wait 2 tick
2023-04-29 23:08:50 +00:00
if event-item is compass named "&2Mene":
2023-04-29 13:40:54 +00:00
make player execute command "/mirricraft gui visit"
cancel the event
wait 2 tick
if event-item is diamond named "&bVIP":
make player execute command "/mirricraft gui vip"
cancel the event
wait 2 tick
if event-item is diamond axe named "&5Ylläpito":
make player execute command "/mirricraft gui admin"
cancel the event
wait 2 tick
if event-item is player's skull named "&6%player's name%":
2023-04-29 13:40:54 +00:00
make player execute command "/mirricraft gui player"
cancel the event
wait 2 tick
on pickup:
if event-item is ender chest named "&fMirriCraft":
delete event-entity
2023-04-29 23:08:50 +00:00
if event-item is compass named "&2Mene":
2023-04-29 13:40:54 +00:00
delete event-entity
if event-item is diamond named "&bVIP":
delete event-entity
2023-04-29 23:08:50 +00:00
if event-item is diamond named "&5Ylläpito":
delete event-entity
if event-item is player's skull named "&6%player's name%":
2023-04-29 13:40:54 +00:00
delete event-entity
on death:
if victim's world is "lobby":
clear drops
if victim's world is "utopia":
clear drops
on weather change to rain or thunder:
if "%event-world%" is "lobby":
cancel event
2023-04-26 14:44:54 +00:00
command /mirricraft [<string>] [<string>] [<string>] [<string>]:
description: MirriCraft
aliases: /mirri, /mc
executable by: players
trigger:
if arg-1 is not set:
make player execute command "/mirricraft item"
make player execute command "/mirricraft gui"
stop
if arg-1 is set:
if arg-1 is "visit":
if player has the permission "mirricraft.visit":
if arg-2 is not set:
message "&7[&2MIRRICRAFT&7]&r Sinun tulee syöttää matkakohde, johon haluat matkustaa!"
stop
if arg-2 is set:
if arg-2 is "lobby":
wait 2 tick
connect player to "lobby"
stop
else if arg-2 is "truelo":
wait 2 tick
connect player to "truelo"
stop
else if arg-2 is "utopia":
wait 2 tick
connect player to "utopia"
stop
else if arg-2 is "skyblock":
wait 2 tick
connect player to "skyblock"
stop
else if arg-2 is "minigames":
wait 2 tick
connect player to "minigames"
stop
else:
message "&7[&2MIRRICRAFT&7]&r Valitsemasi matkakohde ei löytynyt!"
stop
2023-04-29 13:40:54 +00:00
else:
message "&7[&2MIRRICRAFT&7]&r Sinulla ei ole riittäviä oikeuksia!"
2023-04-26 14:44:54 +00:00
if arg-1 is "vip":
2023-04-29 13:40:54 +00:00
if player has the permission "mirricraft.vip":
if arg-2 is "cosmetics":
wait 2 tick
make player execute command "/uc menu main"
stop
if arg-2 is "music":
wait 2 tick
make player execute command "/music"
stop
else:
message "&7[&2MIRRICRAFT&7]&r Osta itsellesi VIP-jäsenyys tukemalla MirriCraftin toimintaa!"
2023-04-26 14:44:54 +00:00
if arg-1 is "player":
2023-04-26 14:52:42 +00:00
stop
2023-04-26 14:44:54 +00:00
if arg-1 is "item":
if player's world is "lobby":
remove all items from player
2023-04-29 13:40:54 +00:00
if player have permission "mirricraft.admin":
2023-04-29 23:08:50 +00:00
set slot 0 of player's inventory to 1 of compass named "&2Mene"
2023-04-29 13:40:54 +00:00
set slot 4 of player's inventory to 1 of diamond named "&bVIP"
set slot 6 of player's inventory to 1 of diamond axe named "&5Ylläpito"
set slot 8 of player's inventory to 1 of player's skull named "&6%player's name%"
2023-04-29 13:40:54 +00:00
stop
else:
2023-04-29 23:08:50 +00:00
set slot 0 of player's inventory to 1 of compass named "&2Mene"
2023-04-29 13:40:54 +00:00
set slot 4 of player's inventory to 1 of diamond named "&bVIP"
set slot 8 of player's inventory to 1 of player's skull named "&6%player's name%"
2023-04-29 13:40:54 +00:00
stop
2023-04-26 14:44:54 +00:00
else:
set slot 8 of player's inventory to 1 of ender chest named "&fMirriCraft"
stop
if arg-1 is "reload":
if player has permission "mirricraft.admin":
message "&7[&2MirriCraft&7]&r Reloading..."
make player execute command "/skript reload mirricraft"
stop
if arg-1 is "gui":
if arg-2 is not set:
wait 2 tick
open chest inventory with 3 row named "MirriCraft" to player
wait 2 tick
loop integers between 0 and 26:
format slot loop-integer of player with gray stained glass pane named "&7" to be unstealable
2023-04-29 13:40:54 +00:00
if player have permission "mirricraft.admin":
2023-04-30 18:12:54 +00:00
format slot 10 of player with compass named "&2Mene" with lore "-" to close then run [execute player command "/mirricraft gui visit"]
2023-04-29 23:08:50 +00:00
format slot 12 of player with diamond named "&bVIP" with lore "-" to close then run [execute player command "/mirricraft gui vip"]
2023-04-30 18:12:54 +00:00
format slot 14 of player with diamond axe named "&5Ylläpito" with lore "-" to close then run [execute player command "/mirricraft gui admin"]
format slot 16 of player with player's skull named "&6Player" with lore "&o&f%player's name%" to close then run [execute player command "/mirricraft gui player"]
2023-04-29 13:40:54 +00:00
stop
2023-04-26 14:44:54 +00:00
else:
2023-04-30 18:12:54 +00:00
format slot 10 of player with compass named "&2Mene" with lore "-" to close then run [execute player command "/mirricraft gui visit"]
2023-04-29 23:08:50 +00:00
format slot 13 of player with diamond named "&bVIP" with lore "-" to close then run [execute player command "/mirricraft gui vip"]
format slot 16 of player with player's skull named "&6Player" with lore "&o&f%player's name%" to close then run [execute player command "/mirricraft gui player"]
2023-04-29 13:40:54 +00:00
stop
2023-04-26 14:44:54 +00:00
if arg-2 is set:
if arg-2 is "visit":
2023-04-29 13:40:54 +00:00
wait 2 tick
open chest inventory with 4 row named "MirriCraft - Mene" to player
wait 2 tick
2023-04-26 14:44:54 +00:00
2023-04-29 13:40:54 +00:00
loop integers between 0 and 35:
2023-04-29 14:26:34 +00:00
format slot loop-integer of player with gray stained glass pane named "&7" to be unstealable
2023-04-26 14:44:54 +00:00
2023-04-29 13:40:54 +00:00
format slot 11 of player with diamond sword with no nbt named "&f&nTruelo" with lore "&o&fSelviydy elämän haasteista" and "&7Avautuu myöhemmin" to close then run [execute player command "/mirricraft visit truelo"]
format slot 13 of player with allium named "&f&nUtopia" with lore "&o&fVain luovuus on rajanasi" to close then run [execute player command "/mirricraft visit utopia"]
format slot 15 of player with oak sapling named "&f&nSkyBlock" with lore "&o&fTunne vapauden tuulenvire" to close then run [execute player command "/mirricraft visit skyblock"]
format slot 21 of player with end crystal named "&f&nMinigames" with lore "&o&fHauskaa kavereiden kanssa" to close then run [execute player command "/mirricraft visit minigames"]
format slot 23 of player with ender eye named "&f&nMultiverse" with lore "&o&fKäväise vanhoissa maailmoissa" and "&7Suljettu toistaiseksi" to close then run [execute player command "/mirricraft visit multiverse"]
format slot 35 of player with nether star named "&fLobby" to close then run [execute player command "/mirricraft visit lobby"]
2023-04-26 14:44:54 +00:00
2023-04-29 13:40:54 +00:00
format slot 27 of player with arrow named "&fTakaisin" to close then run [execute player command "/mirricraft gui"]
2023-04-26 14:44:54 +00:00
2023-04-29 13:40:54 +00:00
stop
2023-04-26 14:44:54 +00:00
if arg-2 is "vip":
if player has the permission "mirricraft.vip":
wait 2 tick
open chest inventory with 4 row named "MirriCraft - VIP" to player
wait 2 tick
2020-10-24 04:33:04 +00:00
2023-04-26 14:44:54 +00:00
loop integers between 0 and 35:
format slot loop-integer of player with gray stained glass pane named "&7" to be unstealable
if player's world is "lobby":
format slot 12 of player with ender chest named "&fCosmetics" to close then run [execute player command "/mirricraft vip cosmetics"]
format slot 14 of player with music disc cat named "&fMusic" to close then run [execute player command "/mirricraft vip music"]
format slot 27 of player with arrow named "&fTakaisin" to close then run [execute player command "/mirricraft gui"]
stop
if arg-2 is "player":
wait 2 tick
open chest inventory with 4 row named "MirriCraft - %player's name%" to player
2023-04-26 14:44:54 +00:00
wait 2 tick
loop integers between 0 and 35:
format slot loop-integer of player with gray stained glass pane named "&7" to be unstealable
format slot 12 of player with ender chest named "&fEnderChest" to close then run [execute player command "/enderchest"]
format slot 14 of player with elytra named "&fFly" to close then run [execute player command "/fly"]
format slot 27 of player with arrow named "&fTakaisin" to close then run [execute player command "/mirricraft gui"]
stop
if arg-2 is "admin":
2023-04-29 13:40:54 +00:00
if player has the permission "mirricraft.admin":
wait 2 tick
open chest inventory with 4 row named "MirriCraft - Ylläpito" to player
wait 2 tick
2023-04-26 14:44:54 +00:00
2023-04-29 13:40:54 +00:00
loop integers between 0 and 35:
format slot loop-integer of player with gray stained glass pane named "&7" to be unstealable
2023-04-26 14:44:54 +00:00
2023-04-29 13:40:54 +00:00
format slot 27 of player with arrow named "&fTakaisin" to close then run [execute player command "/mirricraft gui"]
2023-04-26 14:44:54 +00:00
2023-04-29 13:40:54 +00:00
stop
2023-04-26 14:44:54 +00:00
command /lobby:
description: Lobby
executable by: players
trigger:
make player execute command "/mirricraft visit lobby"
stop