Dzień dobry korzystam ze skryptu @Helios1993 na lvl wygląda następująco:
options:
#config
starting-needed-xp: 200
max-lvl: 120
needed-xp-multiplier: 1.33
announce-new-level-every-x-levels: 10
#messages
get-xp-message: "&a+%{_a}% xp &2%{lvl::xp::%{_p}%}%/%{lvl::wymxp::%{_p}%}% &c%{lvl::pp::%{_p}%}%%%"
max-lvl-reached-message-on-xp-get: "&cMasz maksymalny poziom!"
new-lvl-message: "&2&lAwansowales na &a&l%{lvl::lvl::%{_p}%}% &2&lpoziom!"
announce-new-level-every-x-levels-message: "&aGracz &2%{_p}% &aosiagnal &2&l%{lvl::lvl::%{_p}%}% &apoziom!"
function addExp(a: number, p: player):
if {lvl::wymxp::%{_p}%} is not set:
set {lvl::wymxp::%{_p}%} to {@starting-needed-xp}
add {_a} to {lvl::xp::%{_p}%}
set {lvl::pp::%{_p}%} to {lvl::xp::%{_p}%} / {lvl::wymxp::%{_p}%} * 100
send action bar {@get-xp-message} to {_p}
if {lvl::xp::%{_p}%} is more than {lvl::wymxp::%{_p}%}:
if {lvl::lvl::%{_p}%} is {@max-lvl}:
send action bar {@max-lvl-reached-message-on-xp-get} to {_p}
else:
set {lvl::xp::%{_p}%} to 0
add 1 to {lvl::lvl::%{_p}%}
send {@new-lvl-message} to {_p}
set {lvl::wymxp::%{_p}%} to rounded {lvl::wymxp::%{_p}%} * {@needed-xp-multiplier}
clear {lvl::pp::%{_p}%}
if {lvl::lvl::%{_p}%} is divisible by {@announce-new-level-every-x-levels}:
send {@announce-new-level-every-x-levels-message} to all players
command /lvl [<text="%player%">]:
aliases: /poziom, /level
trigger:
if (arg-1 parsed as player) is online:
if {lvl::lvl::%arg-1%} is not set:
set {lvl::lvl::%arg-1%} to 0
if {lvl::xp::%arg-1%} is not set:
set {lvl::xp::%arg-1%} to 0
if {lvl::pp::%arg-1%} is not set:
set {lvl::pp::%arg-1%} to 0
if {lvl::wymxp::%arg-1%} is not set:
set {lvl::wymxp::%arg-1%} to {@starting-needed-xp}
send "&8[&c*&8]----------[&cPoziom&8]----------[&c*&8]"
send "&cPoziom: &7%{lvl::lvl::%arg-1%}%"
send "&cPostęp: &7%{lvl::xp::%arg-1%}%&8/&7%{lvl::wymxp::%arg-1%}% &8(&c%{lvl::pp::%arg-1%}%&c%%&8)"
send "&8[&c*&8]----------[&c%arg-1%&8]----------[&c*&8]"
else:
send "&cNie ma takiego gracza na serwerze!"
I teraz pytanie jak w pluginie PlayerRanks* lub innym mogę wyświetlić dany lvl gracza na chacie?
Pytanie
Addiss9 44
Dzień dobry korzystam ze skryptu @Helios1993 na lvl wygląda następująco:
options: #config starting-needed-xp: 200 max-lvl: 120 needed-xp-multiplier: 1.33 announce-new-level-every-x-levels: 10 #messages get-xp-message: "&a+%{_a}% xp &2%{lvl::xp::%{_p}%}%/%{lvl::wymxp::%{_p}%}% &c%{lvl::pp::%{_p}%}%%%" max-lvl-reached-message-on-xp-get: "&cMasz maksymalny poziom!" new-lvl-message: "&2&lAwansowales na &a&l%{lvl::lvl::%{_p}%}% &2&lpoziom!" announce-new-level-every-x-levels-message: "&aGracz &2%{_p}% &aosiagnal &2&l%{lvl::lvl::%{_p}%}% &apoziom!" function addExp(a: number, p: player): if {lvl::wymxp::%{_p}%} is not set: set {lvl::wymxp::%{_p}%} to {@starting-needed-xp} add {_a} to {lvl::xp::%{_p}%} set {lvl::pp::%{_p}%} to {lvl::xp::%{_p}%} / {lvl::wymxp::%{_p}%} * 100 send action bar {@get-xp-message} to {_p} if {lvl::xp::%{_p}%} is more than {lvl::wymxp::%{_p}%}: if {lvl::lvl::%{_p}%} is {@max-lvl}: send action bar {@max-lvl-reached-message-on-xp-get} to {_p} else: set {lvl::xp::%{_p}%} to 0 add 1 to {lvl::lvl::%{_p}%} send {@new-lvl-message} to {_p} set {lvl::wymxp::%{_p}%} to rounded {lvl::wymxp::%{_p}%} * {@needed-xp-multiplier} clear {lvl::pp::%{_p}%} if {lvl::lvl::%{_p}%} is divisible by {@announce-new-level-every-x-levels}: send {@announce-new-level-every-x-levels-message} to all players command /lvl [<text="%player%">]: aliases: /poziom, /level trigger: if (arg-1 parsed as player) is online: if {lvl::lvl::%arg-1%} is not set: set {lvl::lvl::%arg-1%} to 0 if {lvl::xp::%arg-1%} is not set: set {lvl::xp::%arg-1%} to 0 if {lvl::pp::%arg-1%} is not set: set {lvl::pp::%arg-1%} to 0 if {lvl::wymxp::%arg-1%} is not set: set {lvl::wymxp::%arg-1%} to {@starting-needed-xp} send "&8[&c*&8]----------[&cPoziom&8]----------[&c*&8]" send "&cPoziom: &7%{lvl::lvl::%arg-1%}%" send "&cPostęp: &7%{lvl::xp::%arg-1%}%&8/&7%{lvl::wymxp::%arg-1%}% &8(&c%{lvl::pp::%arg-1%}%&c%%&8)" send "&8[&c*&8]----------[&c%arg-1%&8]----------[&c*&8]" else: send "&cNie ma takiego gracza na serwerze!"I teraz pytanie jak w pluginie PlayerRanks* lub innym mogę wyświetlić dany lvl gracza na chacie?
Edytowane przez Addiss9Odnośnik do komentarza
https://skript.pl/temat/41557-poziom-na-chacie/Udostępnij na innych stronach
6 odpowiedzi na to pytanie
Rekomendowane odpowiedzi