options: version: 1.0 on script load: send "&r" to console send "&8&l| &fxCheck &8- &f_xKubus_" to console send "&8&l| &fEnabled version {@version}" to console if "{@version}" is not text from "https://code.skript.pl/R3AguebW/raw": send "&8&l| &cThere is an update! &8( &c&nv%text from ""https://code.skript.pl/R3AguebW/raw%"" &8)" to console send "&8&l| &cFor more info type /xcheck update" to console send "&r" to console else: send "&r" to console on join: if yaml value "check-updates" from "config" is true: if player has permission "*": if "{@version}" is not text from "https://code.skript.pl/R3AguebW/raw": send "&r" to player send "&8&l| &fᴛʜᴇʀᴇ ɪꜱ ᴀɴ ɴᴇᴡ ᴜᴘᴅᴀᴛᴇ ᴏꜰ xᴄʜᴇᴄᴋ!" to player send "&8&l| &fꜰᴏʀ ᴍᴏʀᴇ ɪɴꜰᴏ ᴛʏᴘᴇ /xᴄʜᴇᴄᴋ ᴜᴘᴅᴀᴛᴇ ᴄᴏᴍᴍᴀɴᴅ" to player send "&r" to player on first join: if player has permission "*": send "&r" to player send "&8&l| &fᴛʜᴀɴᴋꜱ ꜰᴏʀ ᴜꜱɪɴɢ ᴏᴜʀ ꜰᴀᴠᴏʀɪᴛᴇ ꜱᴄʀɪᴘᴛ" to player send "&r" to player function repText(text: text) :: text: replace all "%player%" with "%player%" in {_text} replace all "%checker%" with "%{_checker::%player%}%" replace all "%bans%" with "%{_bans::%player%}%" replace all "%time%" with "%{_time}%" replace all "%status%" with "%{_status::%player%}%" return {_text} on load: if yaml file "plugins/xCheck/config.yml" doesn't exist: load yaml "plugins/xCheck/config.yml" as "config" set yaml value "version" of "config" to "{@version}" set yaml value "update-checker" of "config" to true set yaml value "actionbar-messages" of "config" to true set yaml value "title-messages" of "config" to true set yaml value "subtitle-messages" of "config" to true set yaml value "checking-start-message" of "config" to true set yaml value "checking-ended-messsag" of "config" to true set yaml value "cage" of "config" to true set the comment of yaml node "cage" of "config" to "If you will change it to false, player will be freezed in his location and you will be teleported to him" set yaml value "cage-loc" of "config" to "---------" set yaml value "spawn" of "config" to true set the comments of yaml node "spawn" of "config" to "If 'cage' is enabled and if it is 'false' player will be teleported into his previos location after checking" set yaml value "spawn-loc" of "config" to "---------" set yaml value "checking-other-chat" of "config" to true set yaml value "checking-block-messages" of "config" to true set the comments of yaml node "checking-block-messages" of "config" to "If 'other-chat' is 'false' player's messages will not be sended on public chat" set yaml value "checking-block-commands" of "config" to true set yaml value "ban-player-after-leave" of "config" to true set yaml value "ban-player-after-leave.ban-time" of "config" to 10080 set the comments of yaml node "ban-player-after-leave" of "config" to "Ban time in minutes eg. 10080 minutes - 7 days" set yaml list "permitted-players" of "config" to "Notch" and "_xKubus_" and "jeb_" set the comments of yaml node "permitted-players" of "config" to "Players that cannot be checked and banned for cheating" set yaml list "ban-broadcast" of "config" to "&r" and "&8&l| &7ᴘʟᴀʏᴇʀ &f%player% &7ʟᴇꜰᴛ ᴅᴜʀɪɴɢ ᴄʜᴇᴄᴋɪɴɢ" and "&8&l| &7ᴄʜᴇᴄᴋᴇʀ&8: &f%checker%" and "&r" set yaml list "deny-command" of "config" to "&r" and "&8&l| &cʏᴏᴜ ᴄᴀɴ'ᴛ ᴅᴏ ɪᴛ ᴅᴜʀɪɴɢ ᴄʜᴇᴄᴋɪɴɢ" and "&r" set yaml list "deny-messages" of "config" to "&r" and "&8&l| &cʏᴏᴜ ᴄᴀɴ'ᴛ ᴅᴏ ɪᴛ ᴅᴜʀɪɴɢ ᴄʜᴇᴄᴋɪɴɢ, ᴜꜱᴇ /ʜᴇʟᴘᴏᴘ" and "&r" set yaml value "checking-other-chat-prefix" of "config" to "&c&lCHECKING &8&l|" on quit: if {_checking::%player%} is true: set {_checking::%player%} to false set {_banTime} to yaml value "ban-player-after-leave.ban-time" from "config" execute console command "tempban %player% %{_banTime}%m Logout" set {_text} to yaml list "ban-broadcast" from "config" set {_banBroadcast} to coloured repText({_text}) send "%{_banBroadcast}%" to all players stop on command: if {_checking::%player%} is true: set {_value} to coloured yaml value "checking-block-commands" from "config" if {_value} is true: cancel event set {_text} to yaml list "deny-command" from "config" set {_denyCommand} to coloured repText({_text}) send "%{_text}%" to player on chat: if {_checking::%player%} is true: set {_value} to yaml value "checking-block-messages" from "config" if {_value} is true: cancel event set {_text} to yaml list "deny-messages" from "config" set {_denyMessages} to coloured repText({_text}) send "%{_text}%" to player else: set {_value} to yaml value "checking-other-chat" from "config" if {_value} is true: cancel event set {_message} to message set {_text} to yaml list "checking-other-chat-prefix" from "config" set {_privateChatPrefix} to coloured repText({_text}) send "%{_text}% %player% &8>> &f%{_message}%" to {_checker::%player%} else: stop