World: type: world debug: false events: on player chats: - if { - flag player afk:! } - define list li@ - define player - foreach : - if ].list_keys[Factions.miscellaneous.ignorelist].contains[]> { - define list ]> } - determine recipients:]> on player walks: - if ! { - queue clear } - if ].abs.is[OR_MORE].to[0.4]> || ].abs.is[OR_MORE].to[0.4]> || ].abs.is[OR_MORE].to[0.4]> { - narrate "<&c>Teleport cancelled..." - flag player warping:! } on player join: - if ! { - announce "<&7>[<&a>+<&7>] <&b><&l><&r><&e> has joined the game." } else { - narrate "<&7>[<&a>+<&7>] <&4><&l><&r><&e> has joined the game." targets: } - run s@PlayPoints d: instantly on player quit: - if ! { - announce "<&7>[<&c>-<&7>] <&b><&l><&r><&e> has left the game." } - flag player afk:! EcoCommand: type: command name: eco usage: /eco (give|take|set) (player) (amount) description: Adjusts player balances script: - if ! { - queue clear } - choose : - case 3: - if ]> == null { - narrate "<&c>That player eithe does not exist or is not online." - queue clear } - if ! { - narrate "<&c>That is not a valid amount." - queue clear } - choose : - case give: - money give quantity: players:]> - narrate "<&a>$ <&b>has been added to <&sq>s account." targets: - narrate "<&a>$ <&b>has been added to your account." targets:]> - case take: - money take quantity: players:]> - narrate "<&a>$ <&b>has been taken to <&sq>s account." targets: - narrate "<&a>$ <&b>has been taken to your account." targets:]> - case set: - money set quantity: players:]> - narrate "<&b><&sq>s balance has been set to <&a>$<&b>." targets: - narrate "<&b>Your balance has been set to <&a>$<&b>." targets:]> - default: - narrate "<&c>Usage /eco (give|take|set) (player) (amount)" PayCommand: type: command name: pay usage: /pay (player) (amount) description: Pay money to another player script: - choose : - case 2: - if ]> == null || ]> { - narrate "<&c>That player either does not exist or is not online." - queue clear } - if ! { - narrate "<&c>That is not a valid amount." - queue clear } - if ]> { - narrate "<&c>You do not have enough money." - queue clear } - money take quantity: players: - money give quantity: players:]> - narrate "<&b>You paid <&a>$ <&b>to <&a>]>." targets: - narrate "<&b> has paid you <&a>$ <&b>." targets:]> - default: - narrate "<&c>Usage /pay (player) (amount)" BalCommand: type: command name: bal usage: /bal description: Checks your current balances aliases: - balance - money - currency script: - narrate "<&2>=<&6>=<&2>=<&6>=<&2>=<&6>=<&2>=<&6>=<&2>=<&6>=<&2>=<&6>=<&2>=<&6>=<&2>=<&6>=<&2>=<&6>=<&2>=<&6>=" - narrate "<&b>Balance<&7><&co> <&e>$" - narrate "<&2>=<&6>=<&2>=<&6>=<&2>=<&6>=<&2>=<&6>=<&2>=<&6>=<&2>=<&6>=<&2>=<&6>=<&2>=<&6>=<&2>=<&6>=<&2>=<&6>=" BaltopCommand: type: command debug: false name: baltop usage: /baltop (page#) description: Checks the top balances on the server. speed: 0 script: - if { - narrate "<&c>Please do not spam this command." - queue clear } - narrate "<&2>=<&6>=<&2>=<&6>=<&2>=<&6>=<&2>=<&6>=<&2>=<&6>=<&2>=<&6>=<&2>=<&6>=<&2>=<&6>=<&2>=<&6>=<&2>=<&6>=<&2>=<&6>=<&2>=<&6>=<&2>=<&6>=<&2>=<&6>=" - if && matches number { - define page } else { - define page 1 - narrate "<&6>Ordering balances for <&a> <&6>players..." } - define li - define mod ]> - repeat 10: - if ]||null> == null { - narrate "<&e>---- Page <&6> <&e>of <&6> <&e>----" - queue clear } - narrate " <&6>].as_int>. <&f>]>].name> <&7>- <&a>$<&e>]>].money.as_money>" - narrate "<&e>---- Page <&6> <&e>of <&6> <&e>----" - flag baltop duration:3s MsgCommand: type: command name: message usage: /msg (player) (message) description: Send a message to a player aliases: - m - msg script: - if { - narrate "<&c>Usage: /msg (player) (message)" - queue clear } - define type chat - inject s@LawEnforcement instantly - define sender - define target ]> - flag messaged: - flag messaged: - if ]> { - narrate "<&c>You can<&sq>t message yourself..." - queue clear } - if ]].is_empty> { - narrate "<&c>Please specify an online player." - queue clear } - narrate "<&b> <&7>-<>> <&b>You<&7><&co> " targets: - narrate "<&b>You <&7>-<>> <&b><&7><&co> " targets: ReplyCommand: type: command name: reply usage: /reply description: Reply to a message aliases: - r - reply script: - if ! { - narrate "<&c>No one has messaged you since you last logged in." - queue clear } - narrate "<&b> <&7>-<>> <&b>You<&7><&co> " targets: - narrate "<&b>You <&7>-<>> <&b><&7><&co> " targets: IgnoreCommand: type: command debug: false name: ignore usage: /ignore (player) description: Ignores all messages from the designated player. aliases: - begonethot - shutup script: - if == 0 { - narrate "<&c>Usage /ignore (player)" - queue clear } - define target - if ]> == null || == { - narrate "<&c>That player is offline or is an invalid option." - queue clear } - if ].contains[Factions.miscellaneous.ignorelist]> && ].list_keys[Factions.miscellaneous.ignorelist].contains[]> { - yaml set id: Factions.miscellaneous.ignorelist:<-: - narrate "<&b> is no longer being ignored." targets: - narrate "<&a> is no longer ignoring you." targets: } else { - yaml set id: Factions.miscellaneous.ignorelist:->: - narrate "<&c> is now being ignored." targets: - narrate "<&c> is now ignoring you." targets: } TPAllCommand: type: command debug: true name: tpall usage: /tpall (flagname) description: Teleports all players to your location (optionally specify a player flag to sort by) script: - if ! { - narrate "<&c>You do not have permission to use this command" - queue clear } - if == 0 { - teleport - narrate "<&6>You have been teleported by a staff member." targets: - queue clear } - define flag - foreach ]]> { - teleport - narrate "<&6>You have been teleported by a staff member." targets: } TPAHereCommand: type: command debug: true name: tpahere usage: /tpahere (player) description: Request to teleport a player to your location. script: - if == 0 { - narrate "<&c>Usage /tpahere (player)" - queue clear } - define target - if ]> == null || == { - narrate "<&c>That player is offline or is an invalid option." - queue clear } - if ]||null> { - narrate "<&c>You are already teleporting to that player." - queue clear } - if ]||null> { - flag tpa:<-: - flag tpaccept:<-: - narrate "<&b>Overriding previous tpa request to this player." } - flag tpahere:->: duration:s - flag tpaccept:->: duration:s - narrate "<&6>Request sent to <&c><&6>." targets: - narrate "<&c> <&6>has requested that you teleport to them.<&nl><&6>To accept this request, type <&c>/tpaccept (name)<&6>.<&nl><&6>To deny this request, type <&c>/tpdeny (name)<&6>.<&nl><&6>This reqeust will timeout after <&c> seconds<&6>." targets: TPACommand: type: command debug: true name: tpa usage: /tpa (player) description: Request to teleport to a player. script: - if == 0 { - narrate "<&c>Usage /tpa (player)" - queue clear } - define target - if ]> == null || == { - narrate "<&c>That player is offline or is an invalid option." - queue clear } - if ]||null> { - narrate "<&c>You are already teleporting to that player." - queue clear } - if ]||null> { - flag tpahere:<-: - flag tpaccept:<-: - narrate "<&b>Overriding previous tpahere request from this player." } - flag tpa:->: duration:s - flag tpaccept:->: duration:s - narrate "<&6>Request sent to <&c><&6>." targets: - narrate "<&c> <&6>has requested to teleport to you.<&nl><&6>To accept this request, type <&c>/tpaccept (name)<&6>.<&nl><&6>To deny this request, type <&c>/tpdeny (name)<&6>.<&nl><&6>This reqeust will timeout after <&c> seconds<&6>." targets: TPAcceptCommand: type: command debug: true name: tpaccept usage: /tpaccept (player) description: Request to teleport to a player. script: - if == 0 { - narrate "<&c>Usage /tpaccept (player)" - queue clear } - define target - if ]> == null || !]||null> { - narrate "<&c>That player is offline or is an invalid option." - queue clear } - narrate "<&6>Teleport request accepted." targets:| - flag tpaccept:<-: - if ]||null> { - flag tpa:<-: - run s@TeleportCheck d:||player| instantly } else { - flag tpahere:<-: - run s@TeleportCheck d:||player| instantly } TPDenyCommand: type: command debug: true name: tpdeny usage: /tpdeny (player) description: Denies a teleport request from a player. script: - if == 0 { - narrate "<&c>Usage /tpdeny (player)" - queue clear } - define target - if ]> == null || !]||null> { - narrate "<&c>That player is offline or is an invalid option." - queue clear } - narrate "<&6>Teleport request denied." targets:| - flag tpaccept:<-: - flag tpa:<-: - flag tpahere:<-: WarpsCommand: type: command debug: true name: warps usage: /warps description: Lists available warps script: - define list li@ - foreach : - define list li@].separated_by[,<&sp>]> - narrate "<&6>Warps<&co> >" WarpCommand: type: command debug: true name: warp usage: /warp (warpname) description: Warps to a specified valid warp. script: - if == 0 { - narrate "<&c>Usage<&co> /warp (warpname)" - queue clear } - if { - narrate "<&c>Already teleporting..." - queue clear } - if ]> { - run s@TeleportCheck d:||warp instantly } HomesCommand: type: command debug: true name: homes usage: /homes description: Lists all of your set homes. script: - define list li@ - foreach ].list_keys[Factions.homes]||null>: - define list li@].separated_by[,<&sp>]> - narrate "<&6>Homes<&co> >" HomeCommand: type: command debug: true name: home usage: /home (homename) description: Warps to one of your set homes. script: - if == 0 { - narrate "<&c>Usage<&co> /home (homename)" - queue clear } - if { - narrate "<&c>Already teleporting..." - queue clear } - if ].list_keys[Factions.homes].is_empty||true> || !].list_keys[Factions.homes].contains[]> { - narrate "<&c>You do not have a home with that name." - queue clear } - run s@TeleportCheck d:||home instantly SetHomeCommand: type: command debug: true name: sethome usage: /sethome (homename) description: Sets a home at your current location. script: - if == 0 { - narrate "<&c>Usage<&co> /sethome (homename)" - queue clear } - if ].list_keys[Factions.homes].contains[]||null> { - narrate "<&c>You already have a home with that name." - queue clear } - yaml set id: Factions.homes.: - narrate "<&b>Home <&dq><&dq> has been set!" SpawnCommand: type: command debug: true name: spawn usage: /spawn description: Warps to spawn script: - if { - narrate "<&c>Already teleporting..." - queue clear } - run s@TeleportCheck d:|spawn|warp instantly ShopCommand: type: command debug: true name: shop usage: /shop description: Warps to the Shop script: - if { - narrate "<&c>Already teleporting..." - queue clear } - run s@TeleportCheck d:|shop|warp instantly