For some reason if your one class you gain every ability so if you shift you go invis and you are resistant to poison I check in pex and it says I only have dwarf perm any ideas?
code_language.skript:
on join:
if {race.%player%} is true:
stop
else:
set {race.%player%} to false
wait 1 second
if {race.%player%} is false:
open chest with 1 rows named "Choose Your Character's race..." to player
format slot 3 of player with gold sword named "&e&lHuman" with lore "&ePassive: While Running they are Granted Strength" to close then run [make player execute command "racehuman"]
format slot 4 of player with gold shovel named "&c&lDwarf" with lore "&cPassive: While Sneaking they Turn Invisible" to close then run [make player execute command "racedwarf"]
format slot 5 of player with gold hoe named "&5Mage" with lore "&5Passive: While Poisoned they are cleared of it" to close then run [make player execute command "racemage"]
on inventory close:
wait 1 tick
if {race.%player%} is false:
open chest with 1 rows named "Choose Your Character's race..." to player
format slot 3 of player with gold sword named "&e&lHuman" with lore "&ePassive: While Running they are Granted Strength" to close then run [make player execute command "racehuman"]
format slot 4 of player with gold shovel named "&c&lDwarf" with lore "&cPassive: While Sneaking they Turn Invisible" to close then run [make player execute command "racedwarf"]
format slot 5 of player with gold hoe named "&5Mage" with lore "&5Passive: While Poisoned they are cleared of it" to close then run [make player execute command "racemage"]
command /racehuman:
trigger:
if {race.%player%} is true:
send "&c&l(!) &cYou have already choosen a race!"
if {race.%player%} is false:
set {race.%player%} to true
make console execute command "/pex user %player% add human"
make console execute command "/pex user %player% suffix "" &f&l(&bHuman&f&l)"""
make console execute command "/spawn %player%"
loop 100 times:
send "" to player
loop 1 times:
broadcast "&a&l(!) &a%player% has joined the &bHumans"
command /racedwarf:
trigger:
if {race.%player%} is true:
send "&c&l(!) &cYou have already choosen a race!"
if {race.%player%} is false:
set {race.%player%} to true
make console execute command "/pex user %player% add dwarf"
make console execute command "/pex user %player% suffix "" &f&l(&cDwarf&f&l)"""
make console execute command "/spawn %player%"
loop 100 times:
send "" to player
loop 1 times:
broadcast "&a&l(!) &a%player% has joined the &cDwarves"
command /racemage:
trigger:
if {race.%player%} is true:
send "&c&l(!) &cYou have already choosen a race!"
if {race.%player%} is false:
set {race.%player%} to true
make console execute command "/pex user %player% add mage"
make console execute command "/pex user %player% suffix "" &f&l(&5Mage&f&l)"""
make console execute command "/spawn %player%"
loop 100 times:
send "" to player
loop 1 times:
broadcast "&a&l(!) &a%player% has joined the Mages"
command /racechange:
trigger:
if {race.%player%} is false:
send "&c&l(!) &cYou need to choose a race first!"
if {race.%player%} is true:
set {race.%player%} to false
make console execute command "/pex user %player% remove human"
make console execute command "/pex user %player% remove dwarf"
make console execute command "/pex user %player% remove mage"
kick player
every 5 seconds:
loop all players:
if loop-player has {warrior.%player%} is true:
loop-player is sprinting
apply strength to loop-player for 6 seconds
if loop-player has permission "dwarf":
loop-player is sneaking
apply invisibility to loop-player for 6 seconds
if loop-player has permission "mage":
loop-player is poisoned
cure the loop-player from poison