Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #-------------------------------------------
- # "Get Combo\ed" by JaydenJinx & WaterXCubic
- # Version 2.3Beta
- # Feel free to do whatever is needed!
- #-------------------------------------------
- on skript load:
- if {combo.arenacount} is not set:
- set {combo.arenacount} to 0
- command "/getcomboed" [<text>] [<text>] [<text>]:
- aliases: /gc
- trigger:
- if arg 1 is not set:
- if player has permission "combo.admin":
- message "&6-----&7GetCombo\ed &8&lAdmin&6-----"
- message "&c/gc duel [Player] &7- &eRequest to duel someone!"
- message "&c/gc cancel [Player] &7- &eCancels a duel request!"
- message "&c/gc stats [Player] &7- &eViews yours or another player's stats!"
- message "&c/gc createarena [Arena] &7- &eCreate an arena!"
- message "&c/gc deletearena [Arena] &7- &eDelete an arena!"
- message "&c/gc setspawn [Arena] [Spawn A/B] &7- &eSet the arena's spawns!"
- message "&c/gc listarenas &7- &eList all arenas!"
- stop
- else:
- message "&6-----&7GetCombo\ed&6-----"
- message "&c/gc duel [Player] &7- &eRequest to duel someone!"
- message "&c/gc cancel [Player] &7- &eCancels a duel request!"
- message "&c/gc stats [Player] &7- &eViews yours or another player's stats!"
- if arg 1 is "createarena":
- if player has permission "combo.admin":
- if arg 2 is set:
- if {combo.arena::%arg 2%} is set:
- message "&7GetCombo\ed &6>> &cThere's already an arena by the name of %arg 2%!"
- stop
- else if {combo.arena::%arg 2%} is not set:
- add 1 to {combo.arenacount}
- set {combo.arena::%arg 2%} to {combo.arenacount}
- set {combo.arena.inuse::%arg 2%} to arg 2
- message "&7GetCombo\ed &6>> &aCreated an arena called %arg 2%!"
- message "&cMake sure to set the player spawns!"
- stop
- else:
- message "&7GetCombo\ed &6>> &cSupply a name for the new arena!"
- stop
- else:
- message "&7GetCombo\ed &6>> &cInvalid Permissions!"
- if arg 1 is "setspawn":
- if player has permission "combo.admin":
- if arg 2 is set:
- if {combo.arena::%arg 2%} is not set:
- message "&7GetCombo\ed &6>> &cThat arena does not exist!"
- stop
- if arg 3 is set:
- if arg 3 is "a":
- set {combo.spawn::%arg 2%::a} to location of player
- message "&7GetCombo\ed &6>> &aSet A's spawn for the arena %arg 2%!"
- if {combo.spawn::%arg 2%::b} is set:
- set {combo.arena.notinuse::%arg 2%} to arg 2
- stop
- else if arg 3 is "b":
- set {combo.spawn::%arg 2%::b} to location of player
- message "&7GetCombo\ed &6>> &aSet B's spawn for the arena %arg 2%!"
- if {combo.spawn::%arg 2%::a} is set:
- set {combo.arena.notinuse::%arg 2%} to arg 2
- stop
- else:
- message "&7GetCombo\ed &6>> &c%arg 2% is not spawn A or B!"
- stop
- else if arg 2 is not set:
- message "&7GetCombo\ed &6>> &cYou must supply an arena to set the spawns for!"
- stop
- else:
- message "&7GetCombo\ed &6>> &cInvalid Permissions!"
- if arg 1 is "deletearena":
- if player has permission "combo.admin":
- if arg 2 is set:
- if {combo.arena::%arg 2%} is set:
- delete {combo.arena::%arg 2%}
- delete {combo.spawn::%arg 2%::*}
- remove 1 from {combo.arenacount}
- message "&7GetCombo\ed &6>> &aDeleted an arena named %arg 2%!"
- stop
- else:
- message "&7GetCombo\ed &6>> &cThere is no arena named %arg 2%!"
- stop
- else:
- message "&7GetCombo\ed &6>> &cSupply an arena to delete!"
- else:
- message "&7GetCombo\ed &6>> &cInvalid Permissions!"
- if arg 1 is "duel":
- if arg 2 is set:
- if arg 2 parsed as a player is player:
- message "&7GetCombo\ed &6>> &cYou can't duel yourself!"
- stop
- if arg 2 parsed as a player is online:
- set {combo.%player%.invited::%arg 2%} to arg 2
- message "&7GetCombo\ed &6>> &d%player% has challenged you to a duel." to arg 2 parsed as a player
- message "&7GetCombo\ed &6>> &dYou have challenged %arg 2% to a duel."
- message "&cWait for them to accept..."
- else:
- message "&7GetCombo\ed &6>> &c%arg 2% is not online!"
- else:
- message "&7GetCombo\ed &6>> &cSupply a player to duel!"
- if arg 1 is "cancel":
- if arg 2 is set:
- if arg 2 parsed as a player is online:
- if {combo.%player%.invited::%arg 2%} is set:
- delete {combo.%player%.invited:%arg 2%}
- message "&7GetCombo\ed &6>> &2You have canceled your request to duel!"
- else:
- message "&7GetCombo\ed &6>> &cYou haven't requested to duel %arg 2% yet!"
- stop
- else:
- message "&7GetCombo\ed &6>> &cThat player is not online!"
- else:
- message "&7GetCombo\ed &6>> &cSupply a player to cancel with!"
- if arg 1 is "accept":
- if arg 2 is set:
- if arg 2 parsed as a player is online:
- if {combo.%arg 2%.invited::%player%} is set:
- if size of {combo.arena.notinuse::*} > 0:
- loop {combo.arena.notinuse::*}:
- set {_a} to random string out of loop-index
- else:
- message "&7GetCombo\ed &6>> &cEither all arenas are in use or there are no ready arenas!"
- delete {combo.%player%.invited::%arg 2%}
- stop
- delete {combo.arena.notinuse::%{_a}%}
- set {combo.arena.inuse::%{_a}%} to true
- set {_o} to arg 2 parsed as a player
- set {_p} to player
- heal {_p}
- heal {_o}
- set {combo.ingame::%{_p}%} to "%{_a}%"
- set {combo.ingame::%{_o}%} to "%{_a}%"
- set {combo.pos.%{_p}%} to location of {_p}
- set {combo.pos.%{_o}%} to location of {_o}
- set {combo.armor::%{_p}%::helmet} to the helmet of {_p}
- set {combo.armor::%{_p}%::chestplate} to the chestplate of {_p}
- set {combo.armor::%{_p}%::leggings} to the leggings of {_p}
- set {combo.armor::%{_p}%::boots} to the boots of {_p}
- loop all items in inventory of {_p}:
- add loop-item to {combo.inv::%{_p}%::*}
- loop all items in inventory of {_o}:
- add loop-item to {combo.inv::%{_o}%::*}
- set {combo.armor::%{_o}%::helmet} to the helmet of {_o}
- set {combo.armor::%{_o}%::chestplate} to the chestplate of {_o}
- set {combo.armor::%{_o}%::leggings} to the leggings of {_o}
- set {combo.armor::%{_o}%::boots} to the boots of {_o}
- clear {_p}'s inventory
- clear {_o}'s inventory
- teleport {_p} to {combo.spawn::%{_a}%::a}
- teleport {_o} to {combo.spawn::%{_a}%::b}
- send "&7GetCombo\ed &6>> &2You're playing on map %{_a}%!" to {_p}
- send "&7GetCombo\ed &6>> &2You're playing on map %{_a}%!" to {_o}
- set {combo.arena.inuse::%arg 2%} to true
- message "&7GetCombo\ed &6>> &c%{_p}% has accepted your duel!" to {_o}
- message "&7GetCombo\ed &6>> &cYou have accepted %{_o}%'s duel!" to {_p}
- give {_p} 1 diamond sword of sharpness 5 and unbreaking 3 named "&7GetCombo\ed &6Duel Sword"
- give {_o} 1 diamond sword of sharpness 5 and unbreaking 3 named "&7GetCombo\ed &6Duel Sword"
- give {_p} 64 enchanted golden apple named "&7GetCombo\ed &dGapples"
- give {_p} 2 potion of strength 2 named "&7GetCombo\ed &dStrength"
- give {_p} 2 potion of speed 2 named "&7GetCombo\ed &dSpeed"
- give {_o} 64 enchanted golden apple named "&7GetCombo\ed &dGapples"
- give {_o} 2 potion of strength 2 named "&7GetCombo\ed &dStrength"
- give {_o} 2 potion of speed 2 named "&7GetCombo\ed &dSpeed"
- equip {_p} with all diamond armour of unbreaking 3 and protection 4 named "&7GetCombo\ed &6Duel Armour"
- equip {_o} with all diamond armour of unbreaking 3 and protection 4 named "&7GetCombo\ed &6Duel Armour"
- else:
- message "&7GetCombo\ed &6>> &cThat player has not requested to duel! Duel them with /gc duel %arg 2%!"
- else:
- message "&7GetCombo\ed &6>> &c%arg 2% is not online!"
- else:
- message "&7GetCombo\ed &6>> &cSupply a player to accept!"
- if arg 1 is "leave":
- if {combo.ingame::%player%} is set:
- message "&7GetCombo\ed &c>> &4How could you leave your opponent!"
- kill player
- else:
- message "&7GetCombo\ed &6>> &cYou aren't in a duel!"
- if arg 1 is "stats":
- if arg 2 is set:
- if {combo.wins::%arg 2%} is not set:
- set {combo.wins::%arg 2%} to 0
- if {combo.loses::%arg 2%} is not set:
- set {combo.loses::%arg 2%} to 0
- message "&6-----&7GetCombo\ed &6%arg 2%'s &8&lStats&6-----"
- message "&CWins &7- &e%{combo.wins::%arg 2%}%"
- message "&cLoses &7- &e%{combo.loses::%arg 2%}%"
- set {_wl} to {combo.wins::%arg 2%} / {combo.loses::%arg 2%}
- message "&cW/L Ratio &7- &e%{_wl}%"
- else:
- message "&6-----&7GetCombo\ed &8&lStats&6-----"
- message "&CWins &7- &e%{combo.wins::%player%}%"
- message "&cLoses &7- &e%{combo.loses::%player%}%"
- set {_wl} to {combo.wins::%player%} / {combo.loses::%player%}
- message "&cW/L Ratio &7- &e%{_wl}%"
- if arg 1 is "listarenas":
- if player has permission "combo.admin":
- message "&6-----&7GetCombo\ed &8&lArenas&6-----"
- if {combo.arenacount} is not set:
- message "&4No arenas have been made!"
- else if {combo.arenacount} is 0:
- message "&4No arenas have been made!"
- loop {combo.arena::*}:
- message "&7%loop-index%"
- else:
- message "&7GetCombo\ed &6>> &cInvalid Permissions!"
- if arg 1 is "reload":
- if player has permission "combo.admin":
- message "&7GetCombo\ed &6>> &5&lBegan reload!"
- make console execute command "sk reload getcomboed.sk"
- message "&7GetCombo\ed &6>> &2Reload finished!"
- else:
- message "&7GetCombo\ed &6>> &cInvalid Permissions!"
- on disconnect:
- if {combo.ingame::%player%} is set:
- kill player
- loop all players:
- if {combo.ingame::%loop-player%} is set:
- message "&7GetCombo\ed &6>> &dYou have won because the player you were fighting has left!"
- on death:
- if {combo.ingame::%victim%} is set:
- broadcast "&7GetCombo\ed &6>> &4&l%attacker% has defeated %victim%!"
- delete {combo.%attacker%.invited::%victim%}
- delete {combo.%victim%.invited::%attacker%}
- set the death message to ""
- clear drops
- delete {combo.arena.inuse::%{combo.ingame::%victim%}%}
- set {combo.arena.notinuse::%{combo.ingame::%victim%}%} to {combo.ingame::%victim%}
- clear attacker's inventory
- teleport attacker to {combo.pos.%attacker%}
- delete {combo.ingame::%attacker%}
- delete {combo.pos.%attacker%}
- remove speed from attacker
- remove strength from attacker
- remove regeneration from attacker
- remove absorption from attacker
- remove fire resistance from attacker
- remove resistance from attacker
- add 1 to {combo.wins::%attacker%}
- add 1 to {combo.loses::%victim%}
- set {combo.ks::%attacker%} to 0
- set {combo.ks::%victim%} to 0
- set the helmet of the attacker to {combo.armor::%attacker%::helmet}
- set the chestplate of the attacker to {combo.armor::%attacker%::chestplate}
- set the leggings of the attacker to {combo.armor::%attacker%::leggings}
- set the boots of the attacker to {combo.armor::%attacker%::boots}
- wait 1 tick
- delete {combo.armor::%attacker%::*}
- loop {combo.inv::%attacker%::*}:
- give attacker loop-value
- wait 1 tick
- delete {combo.inv::%attacker%::*}
- on command:
- if command is "/gc leave":
- stop
- if {combo.ingame::%player%} is true:
- cancel event
- message "&7GetCombo\ed &6>> &cYou can't use commands while in the arena!"
- message "&cUse /gc leave to leave the arena!"
- on join:
- if {combo.wins::%player%} is not set:
- set {combo.wins::%player%} to 0
- if {combo.loses::%player%} is not set:
- set {combo.loses::%player%} to 0
- set {combo.hs::%player%} to 0
- on damage:
- if {combo.ingame::%victim%} is set:
- if {combo.ingame::%attacker%} is not set:
- victim's health is less than 2
- cancel event
- if {combo.%attacker%.invited::%victim%} is not set:
- set {_a} to false
- else:
- set {_a} to true
- if {combo.%victim%.invited::%attacker%} is not set:
- set {_b} to false
- else:
- set {_b} to true
- if {_a} and {_b} are false:
- cancel event
- stop
- attacker is a player
- set the no damage time of victim to 1 tick
- set {combo.hs::%victim%} to 0
- add 1 to {combo.hs::%attacker%}
- set action bar of attacker to "&cYou're on a %{combo.hs::%attacker%}% hit streak!"
- on respawn:
- if {combo.ingame::%player%} is set:
- clear player's inventory
- delete {combo.ingame::%player%}
- teleport player to {combo.pos.%player%}
- delete {combo.pos.%player%}
- set the helmet of the player to {combo.armor::%player%::helmet}
- set the chestplate of the player to {combo.armor::%player%::chestplate}
- set the leggings of the player to {combo.armor::%player%::leggings}
- set the boots of the player to {combo.armor::%player%::boots}
- wait 1 tick
- delete {combo.armor::%player%::*}
- loop {combo.inv::%player%::*}:
- give player loop-value
- wait 1 tick
- delete {combo.inv::%player%::*}
- on pick up:
- if item is diamond helmet of unbreaking 3 and protection 4 named "&7GetCombo\ed &6Duel Armour":
- cancel event
- if item is diamond chestplate of unbreaking 3 and protection 4 named "&7GetCombo\ed &6Duel Armour":
- cancel event
- if item is diamond leggings of unbreaking 3 and protection 4 named "&7GetCombo\ed &6Duel Armour":
- cancel event
- if item is diamond boots of unbreaking 3 and protection 4 named "&7GetCombo\ed &6Duel Armour":
- cancel event
- if item is enchanted golden apple named "&7GetCombo\ed &dGapples":
- cancel event
- if item is potion of speed 2 named "&7GetCombo\ed &dSpeed":
- cancel event
- if item is potion of strength 2 named "&7GetCombo\ed &dStrength":
- cancel event
- if item is diamond sword of sharpness 5 and unbreaking 3 named "&7GetCombo\ed &6Duel Sword":
- cancel event
- on drop:
- if item is diamond helmet of unbreaking 3 and protection 4 named "&7GetCombo\ed &6Duel Armour":
- cancel event
- if item is diamond chestplate of unbreaking 3 and protection 4 named "&7GetCombo\ed &6Duel Armour":
- cancel event
- if item is diamond leggings of unbreaking 3 and protection 4 named "&7GetCombo\ed &6Duel Armour":
- cancel event
- if item is diamond boots of unbreaking 3 and protection 4 named "&7GetCombo\ed &6Duel Armour":
- cancel event
- if item is diamond sword of sharpness 5 and unbreaking 3 named "&7GetCombo\ed &6Duel Sword":
- cancel event
- if item is enchanted golden apple named "&7GetCombo\ed &dGapples":
- cancel event
- if item is potion of speed 2 named "&7GetCombo\ed &dSpeed":
- cancel event
- if item is potion of strength 2 named "&7GetCombo\ed &dStrength":
- cancel event
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement