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|" set yaml list "help-message" of "config" to "&r" and "&axᴄʜᴇᴄᴋ - ʜᴇʟᴘ ᴘᴀɢᴇ" and "&r" and "&a» &f/check " and "&a» &f/clear " and "&a» &f/cheaty " and "&a» &f/coop " and "&a» &f/xcheck tp" and "&a» &f/xcheck spectate " and "&a» &f/xcheck stats " and "&a» &f/xcheck resetstats " and "&a» &f/xcheck setcage" and "&a» &f/xcheck setlobby" and "&a» &f/xcheck history " and "&a» &f/xcheck help" and "&r" set yaml value "countdown-message" of "config" to "&8&l| &fᴄʜᴇᴄᴋɪɴɢ ᴡɪʟʟ ꜱᴛᴀʀᴛ ᴀꜰᴛᴇʀ &c%time% &fꜱᴇᴄᴏɴᴅꜱ, ɪꜰ ʏᴏᴜ ᴡᴀɴᴛ ᴛᴏ ᴄᴀɴᴄᴇʟ &nᴄʟɪᴄᴋ ʜᴇʀᴇ" set yaml value "check-title" of "config" to "&4&lʏᴏᴜ ᴀʀᴇ ᴄʜᴇᴄᴋɪɴɢ" set yaml value "check-subtitle" of "config" to "&4&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 on any move: set {_value} to yaml value "cage" from "config" if {_value} is false: if {_checking::%player%} is true: cancel event set {_text} to yaml list "deny-messages" from "config" set {_denyMessages} to coloured repText({_text}) send "%{_text}%" to player on damage: set {_value} to yaml value "cage" from "config" if {_value} is false: if {_checking::%victim%} is true: cancel event set {_text} to yaml list "deny-messages" from "config" set {_denyMessages} to coloured repText({_text}) send "%{_text}%" to victim on damage: set {_value} to yaml value "cage" from "config" if {_value} is false: if {_checking::%attacker%} is true: cancel event set {_text} to yaml list "deny-messages" from "config" set {_denyMessages} to coloured repText({_text}) send "%{_text}%" to attacker on break: set {_value} to yaml value "cage" from "config" if {_value} is false: if {_checking::%player%} is true: cancel event set {_text} to yaml list "deny-messages" from "config" set {_denyMessages} to coloured repText({_text}) send "%{_text}%" to attacker command /check []: trigger: if {_checking::%{_p}%} is false: set {_value} to yaml value "cage" from "config" if {_value} is true: set {_value} to yaml value "cage-loc" from "config" if {_value} is set: set {_value} to yaml value "spawn" from "config" if {_value} is true: set {_value} to yaml value "spawn-loc" if {_value} is set: set {_text} to yaml value "countdown-message" from "config" set {_time} to 5 loop 5 times: set {_compond} to coloured repText({_text}) set {_a} to new text component from "%{_compond}%" set click event of {_a} to a new click event to run command "/xcheck cancel" remove 1 from {_time} send component {_a} to player if {_cancel::%player%} is true: stop set {_cage} to yaml value "cage-loc" from "config" teleport arg-player to {_cage} teleport player to {_cage} set {_checking::%arg-player%} to true set {_checker::%arg-player%} to player set {_title} to yaml value "check-title" from "config" set {_titleCheck} to coloured repText({_title}) set {_subtitle} to yaml value "check-subtitle" from "config" set {_subtitleCheck} to coloured repText({_subtitle}) loop untill stop: if {_checking::%arg-player%} is true: send title "%{_titleCheck}%" with subtitle "%{_subtitleCheck}%" to arg-player else: stop loop command /xcheck [] [] []: aliases: check, xkubus trigger: if arg 1 is not set: set {_text} to yaml list "help-message" from "config" set {_helpMessage} to coloured repText({_text}) send "%{_text}%" to attacker if arg 1 is "check":