hi guys, i wrote an script, where the player can get a specified amount of "Checkpoints".
These Checkpoints are packed ice blocks which the player have to destroy.
the problem is now, that the blocks that should get placed at the locations, don't get placed..
Also there are no error in console or chat.
Here's my script:
These Checkpoints are packed ice blocks which the player have to destroy.
the problem is now, that the blocks that should get placed at the locations, don't get placed..
Also there are no error in console or chat.
Here's my script:
Code:
# CHECKPOINTS SKRIPT BY Yuchaa
on load:
set {lizenz.warning} to "&8❙ &2Lizenz &8× &7Der Command geht nicht da die Lizenz nicht aktiviert ist!"
set {location::I} to location at (2138, 15, -536) in world "world" parsed as world
set {location::II} to location at (2130, 15, -535) in world "world" parsed as world
set {location::III} to location at (2123, 15, -533) in world "world" parsed as world
set {location::IV} to location at (2126, 15, -526) in world "world" parsed as world
set {location::V} to location at (2119, 15, -525) in world "world" parsed as world
set {location::CH} to location at (2126, 15, -530) in world "world" parsed as world
set {location::SH} to location at (2143, 15, -530) in world "world" parsed as world
add {location::I} to {loc::*}
add {location::II} to {loc::*}
add {location::III} to {loc::*}
add {location::IV} to {loc::*}
add {location::V} to {loc::*}
on join:
set {uuid::%player%} to player's uuid
if {Strafpunkte::%{uuid::%player%}%} is not set:
set {Strafpunkte::%{uuid::%player%}%} to 0
if {Strafpunkte::%{uuid::%player%}%} is greater than 0:
execute console command "/tp %player% %{location::CH}%"
set block at {location::II} to packed ice
command /checkpoints [<text>] [<player>] [<integer>] [<text>]:
aliases: /cp
permission: cp.admin
permission message: &8❙ &cStrafpunkte &8× &7Du kannst diesen Befehl nicht ausführen
usage: /checkpoints [<Syntax>] [<player>] [<integer>] [<reason>]
trigger:
if {lizenz.use} is true:
if arg-1 is "give":
if arg-2 is a player:
if arg-3 is set:
if arg-4 is set:
send "&8❙ &cStrafpunkte &8× &7Du hast erfolgreich dem Spieler &e%player-arg%&7 Checkpoints gegeben!" to player
send "&8❙ &cStrafpunkte &8× &7Du wurdest von &e%player%&7 zu &e%arg-3%&7 Strafpunkte verurteilt!" to player-arg
broadcast "&e%player-arg% &cwurde von &e%player% &czu &e%arg-3% &cCheckpoints verurteilt!"
broadcast "&cGrund: &e%arg-4%"
set {_Checkpoints} to arg-3
add {_Checkpoints} to {Strafpunkte::%{uuid::%arg-2%}%}
execute console command "/kick %player-arg% Bitte rejoinen"
else:
send "&8❙ &cStrafpunkte &8× &7Du musst einen Grund angeben!" to player
else:
send "&8❙ &cStrafpunkte &8× &7Du musst eine Anzahl angeben!" to player
else:
send "&8❙ &cStrafpunkte &8× &7Spieler nicht gefunden!" to player
else if arg-1 is "reset":
if arg-2 is a player:
set {Strafpunkte::%{uuid::%arg-2%}%} to 0
send "&8❙ &cStrafpunkte &8× &7Du hast die Checkpoints von &e%player-arg%&7 gecleart!" to player
send "&8❙ &cStrafpunkte &8× &7Deine Strafpunkte wurden von &e%player%&7 gecleart!" to player-arg
else:
send "&8❙ &cStrafpunkte &8× &7Spieler nicht gefunden!" to player
else:
send "&8❙ &cStrafpunkte &8× &7Bitte nutze /Checkpoints Give/reset Name Anzahl Grund" to player
else:
send {lizenz.warning} to player
on break:
if event-block is a packed ice:
if {Strafpunkte::%{uuid::%event-player%}%} is greater than 0:
remove 1 from {Strafpunkte::%{uuid::%event-player%}%}
set {_var} to random element out of {loc::*}
set block at {_var} to packed ice
send action bar "&6Verbleibende Checkpoints: &e%{Strafpunkte::%{uuid::%player%}%}%" to player
else:
teleport player to {location::SH}
send "&8❙ &cStrafpunkte &8× &7Sei beim nächsten mal vorsichtiger und beachte unsere Regeln!" to player
command /strafe:
trigger:
send "&8❙ &cStrafpunkte &8× &cDu hast noch &e%{Strafpunkte::%{uuid::%player%}%}% &cStrafpunkte!" to player