Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # Kopanie
- on mine:
- set {_block} to single value "config.block" get of "plugins/Skript/scripts/mChatP0L/config.yml" parsed as number
- id of block is {_block}:
- set {_chat} to value "chat" get of "plugins/Skript/scripts/mChatP0L/players/%player%.yml" parsed as text
- if {_chat} is "false":
- set {_kop-stone} to value "stone" get of "plugins/Skript/scripts/mChatP0L/players/%player%.yml" parsed as number
- set {_amount} to single value "config.amount" get of "plugins/Skript/scripts/mChatP0L/config.yml" parsed as number
- add 1 to {_kop-stone}
- set "stone" to "%{_kop-stone}%" in yaml file "plugins/Skript/scripts/mChatP0L/players/%player%.yml"
- if {_kop-stone} is equal to {_amount}:
- set {_line} to value "message.line" get of "plugins/Skript/scripts/mChatP0L/config.yml" parsed as text
- set {_chat-unlock} to value "message.chat-unlock" get of "plugins/Skript/scripts/mChatP0L/config.yml" parsed as text
- send "%colored {_line}%"
- send "%colored {_chat-unlock}%"
- send "%colored {_line}%"
- set "chat" to "true" in yaml file "plugins/Skript/scripts/mChatP0L/players/%player%.yml"
- # Komenda
- command wykopane:
- trigger:
- executor is player:
- set {_line} to value "message.line" get of "plugins/Skript/scripts/mChatP0L/config.yml" parsed as text
- set {_cmd} to value "message.cmd" get of "plugins/Skript/scripts/mChatP0L/config.yml" parsed as text
- set {_amount} to single value "config.amount" get of "plugins/Skript/scripts/mChatP0L/config.yml" parsed as number
- set {_kop-stone} to value "stone" get of "plugins/Skript/scripts/mChatP0L/players/%player%.yml" parsed as number
- set {_block-name} to value "config.block-name" get of "plugins/Skript/scripts/mChatP0L/config.yml" parsed as text
- send "%colored {_line}%"
- replace all "{AMOUNT}" with "%{_amount}%" in {_cmd}
- replace all "{P-AMOUNT}" with "%{_kop-stone}%" in {_cmd}
- replace all "{BLOCK-NAME}" with "%{_block-name}%" in {_cmd}
- send "%colored {_cmd}%"
- send "%colored {_line}%"
- # Chat
- on chat:
- set {_chat} to value "chat" get of "plugins/Skript/scripts/mChatP0L/players/%player%.yml" parsed as text
- if {_chat} is "false":
- set {_line} to value "message.line" get of "plugins/Skript/scripts/mChatP0L/config.yml" parsed as text
- set {_chat} to value "message.chat" get of "plugins/Skript/scripts/mChatP0L/config.yml" parsed as text
- set {_amount} to single value "config.amount" get of "plugins/Skript/scripts/mChatP0L/config.yml" parsed as number
- set {_kop-stone} to value "stone" get of "plugins/Skript/scripts/mChatP0L/players/%player%.yml" parsed as number
- set {_block-name} to value "config.block-name" get of "plugins/Skript/scripts/mChatP0L/config.yml" parsed as text
- send "%colored {_line}%"
- replace all "{AMOUNT}" with "%{_amount}%" in {_chat}
- replace all "{P-AMOUNT}" with "%{_kop-stone}%" in {_chat}
- replace all "{BLOCK-NAME}" with "%{_block-name}%" in {_chat}
- send "%colored {_chat}%"
- send "%colored {_line}%"
- cancel event
- # Foldery i pliki
- on script load:
- if file "plugins/Skript/scripts/mChatP0L/config.yml" doesn't exists:
- create file "plugins/Skript/scripts/mChatP0L/config.yml"
- download from "http://pastebin.com/raw/RJbHLSyB" to "plugins/Skript/scripts/mChatP0L/config.yml"
- if folder "plugins/Skript/scripts/mChatP0L/players" doesn't exists:
- create folder "plugins/Skript/scripts/mChatP0L/players"
- loop all players:
- kick loop-player due to "Wejdz ponownie na serwer!"
- on join:
- if file "plugins/Skript/scripts/mChatP0L/players/%player%.yml" doesn't exists:
- create file "plugins/Skript/scripts/mChatP0L/players/%player%.yml"
- set "stone" to "0" in yaml file "plugins/Skript/scripts/mChatP0L/players/%player%.yml"
- set "chat" to "false" in yaml file "plugins/Skript/scripts/mChatP0L/players/%player%.yml"
- set {_chat} to value "chat" get of "plugins/Skript/scripts/mChatP0L/players/%player%.yml" parsed as text
- if {_chat} is "false":
- set {_line} to value "message.line" get of "plugins/Skript/scripts/mChatP0L/config.yml" parsed as text
- set {_join} to value "message.join" get of "plugins/Skript/scripts/mChatP0L/config.yml" parsed as text
- set {_amount} to single value "config.amount" get of "plugins/Skript/scripts/mChatP0L/config.yml" parsed as number
- set {_block-name} to value "config.block-name" get of "plugins/Skript/scripts/mChatP0L/config.yml" parsed as text
- replace all "{AMOUNT}" with "%{_amount}%" in {_join}
- replace all "{BLOCK-NAME}" with "%{_block-name}%" in {_join}
- send "%colored {_line}%" to player
- send "%colored {_join}%" to player
- send "%colored {_line}%" to player
Advertisement
Add Comment
Please, Sign In to add comment