2021-06-28 21:50:46 +02:00
|
|
|
on load:
|
|
|
|
ScriptList("add", script)
|
|
|
|
on unload:
|
|
|
|
ScriptList("remove", script)
|
|
|
|
|
2021-06-28 11:56:53 +02:00
|
|
|
on chat: # chat
|
|
|
|
cancel event
|
|
|
|
if {nick.%uuid of player%} is set:
|
|
|
|
set {_player} to {nick.%uuid of player%}
|
|
|
|
else:
|
|
|
|
set {_player} to player's name
|
|
|
|
broadcast "<%{_player}%&r> %colored message%" in world of player
|
|
|
|
|
|
|
|
command nickname [<player>] <text>: # changement de pseudo
|
|
|
|
executable by: players
|
|
|
|
aliases: nick
|
|
|
|
description: Change ton nom ou celui d'un autre joueur. (max 15 charactères)
|
|
|
|
trigger:
|
|
|
|
if player is op:
|
|
|
|
set {_playerUUID} to uuid of player
|
|
|
|
set {_player} to player
|
|
|
|
set {_playerNAME} to player
|
2021-06-28 13:02:44 +02:00
|
|
|
if arg-1 is set:
|
|
|
|
set {_playerUUID} to uuid of arg-1
|
|
|
|
set {_player} to arg-1
|
2021-06-28 11:56:53 +02:00
|
|
|
if player is {_player}:
|
|
|
|
set {_playerNAME} to "vous"
|
2021-06-28 15:13:34 +02:00
|
|
|
else:
|
|
|
|
send "&aSurnom changé."
|
2021-06-28 13:02:44 +02:00
|
|
|
if arg-2 is "off":
|
2021-06-28 11:56:53 +02:00
|
|
|
delete {nick.%{_playerUUID}%}
|
|
|
|
send "&6Tu n'as plus de surnom. (changé par %player%&6)" to {_player}
|
|
|
|
else:
|
2021-06-28 13:02:44 +02:00
|
|
|
if length of arg-2 is greater than 15:
|
2021-06-28 11:56:53 +02:00
|
|
|
send "&4Ce surnom est trop long."
|
|
|
|
else:
|
2021-06-28 13:02:44 +02:00
|
|
|
set {nick.%{_playerUUID}%} to colored arg-2
|
2021-06-28 11:56:53 +02:00
|
|
|
send "&6Ton surnom est désormais &r%{nick.%{_playerUUID}%}%&6. (changé par %{_playerNAME}%&6)" to {_player}
|
|
|
|
else:
|
|
|
|
send option("errorMessage")
|
|
|
|
|
|
|
|
command msg <player> <text>: # DM
|
|
|
|
executable by: players
|
|
|
|
aliases: whisper, w, tell, t
|
|
|
|
description: Envoie un message privé à un joueur.
|
|
|
|
trigger:
|
2021-06-28 13:02:44 +02:00
|
|
|
send "&8[Moi -> %arg-1%&8]&7 %colored arg-2%" to player
|
|
|
|
send "&8[%player%&8 -> Moi] &b%colored arg-2%" to arg-1
|
2021-06-28 11:56:53 +02:00
|
|
|
set {dmReply.%uuid of player%} to arg-1
|
|
|
|
set {dmReply.%uuid of arg-1%} to player
|
|
|
|
|
|
|
|
command reponse <text>: # réponse à un DM
|
|
|
|
executable by: players
|
|
|
|
aliases: rep, r
|
|
|
|
description: Envoie un réponse à un joueur.
|
|
|
|
trigger:
|
|
|
|
if {dmReply.%uuid of player%} is set:
|
|
|
|
execute player command "msg %{dmReply.%uuid of player%}% %arg-1%"
|
|
|
|
else:
|
|
|
|
send "&4Tu n'as personne a qui répondre."
|