#LP/Skript conflict
1 messages · Page 1 of 1 (latest)
what....?
cant open the skript
can you paste in here
make sure add it in
there we go lmfao
took me a while to figure our how to do that lmfao
i think you use the /lp command wrong
instead of "permission set"
use "parent set"
so parent.set group.builder true?
the permission is for per player's permission
or just builder
/lp user <player> parent set <group>
like this i think
make sure remove the player's permission before adding to group
so I need to remove all group.fighter permissions from everyone?
is that what you mean?
oh yeah that was a test
player already in default group by default so you can remove the "on join:"
how do I check the
if player doesn't have permission "group.fighter":
then though
the group contains permission bro
btw
idk why u dont use variables instead permission
but it still works but just a lil slower ig
alright as to not override default its actually parent add and not set
small difference lmfao
you can just add group.default permission in the other groups
well I could or I could just replace parent set with parent add :>
hm
idk bro
sometimes it does add 3 groups
huh
like by mistake
you add a player 3 groups
fighter
builder
default
and you have to check again to fix it
thank you
yw
so this solved it for normal players, but I still get the msg that I'm already in the team for both of them
I checked my permissions and groups trough the lp editor
I have group.builder, group.default, group.owner, a meta lp editor key and my parent groups are builder, default and owner
send me the code
trough discord again or trough pastebin
discord
cooldown-time: 1 hour
on join:
wait 1 tick
if player doesn't have permission "group.fighter":
if player doesn't have permission "group.builder":
execute console command "lp user %player% parent add fighter"
send "&aHey! You have been given the Fighter role automatically, do /builder to switch to no pvp."
command /fighter:
trigger:
if player doesn't have permission "group.fighter":
if player has permission "skript.roles_cooldown":
execute console command "lp user %player% parent remove builder"
execute console command "lp user %player% parent add fighter"
send "&aYou are now part of the Fighter team!"
else if {teamCooldown::%player%} is set:
set {_timeLeft} to difference between now and {teamCooldown::%player%}
if {_timeLeft} < {@cooldown-time}:
set {_remaining} to difference between {@cooldown-time} and {_timeLeft}
send "&cYou cannot switch teams yet! Wait &e%{_remaining}%&c."
stop
execute console command "lp user %player% parent remove builder"
execute console command "lp user %player% parent add fighter"
send "&aYou are now part of the Fighter team!"
set {teamCooldown::%player%} to now
else:
send "&cYou are already part of the Fighter team!"```
trigger:
if player doesn't have permission "group.builder":
if player has permission "skript.roles_cooldown":
execute console command "lp user %player% parent remove fighter"
execute console command "lp user %player% parent add builder"
send "&aYou are now part of the Builder team!"
else if {teamCooldown::%player%} is set:
set {_timeLeft} to difference between now and {teamCooldown::%player%}
if {_timeLeft} < {@cooldown-time}:
set {_remaining} to difference between {@cooldown-time} and {_timeLeft}
send "&cYou cannot switch teams yet! Wait &e%{_remaining}%&c."
stop
execute console command "lp user %player% parent remove fighter"
execute console command "lp user %player% parent add builder"
send "&aYou are now part of the Builder team!"
set {teamCooldown::%player%} to now
else:
send "&cYou are already part of the Builder team!"```
if victim is a player:
if victim has permission "group.builder":
if attacker is a player:
cancel event
send "&cYou cannot PvP with Builders!" to attacker
else if attacker is a primed tnt:
cancel event
else if attacker is an ender crystal:
cancel event
else if attacker is a projectile:
if shooter is a player:
cancel event
send "&cYou cannot PvP with Builders!" to shooter
if attacker is a player:
if attacker has permission "group.builder":
if victim is a player:
cancel event
send "&cYou can't PvP while being a Builder!" to attacker
else:```
Yeah when I deop myself and do it again
when I do /builder it says im already in that
and /fighter just gives no output
whatsoever
and console doesnt log any lp changes either
remove the owner permission too
same thing happens
hm
so your permission is "group.builder" and "group.default" ?
Yes
cooldown-time: 1 hour
on join:
wait 1 tick
if player doesn't have permission "group.fighter":
if player doesn't have permission "group.builder":
execute console command "lp user %player% parent add fighter"
send "&aHey! You have been given the Fighter role automatically, do /builder to switch to no pvp."
command /fighter:
trigger:
if player doesn't have permission "group.fighter":
if player has permission "skript.roles_cooldown":
execute console command "lp user %player% parent remove builder"
execute console command "lp user %player% parent add fighter"
send "&aYou are now part of the Fighter team!"
else if {teamCooldown::%player%} is set:
set {_timeLeft} to difference between now and {teamCooldown::%player%}
if {_timeLeft} < {@cooldown-time}:
set {_remaining} to difference between {@cooldown-time} and {_timeLeft}
send "&cYou cannot switch teams yet! Wait &e%{_remaining}%&c."
else:
execute console command "lp user %player% parent remove builder"
execute console command "lp user %player% parent add fighter"
send "&aYou are now part of the Fighter team!"
set {teamCooldown::%player%} to now
else:
send "&cYou are already part of the Fighter team!"```
it should be like this i think
else has to be placed just after another if or else if section
is what the error says
which line
"else:"
hm
oh lol
lol
now to test it
ok
EPIC
that works!
thanks a lot :DDD
but now uh
if I op myself
it doesnt work anymore
again
is there a way to fix that
im confused lol
op = all perms
I used to be staff on a diff server
I was opped there too
But there it DID work
I might have something
I managed to fix it!!!
What I did is I searched online and apparently permission false overrides op
so I basically replaced all permission unset with permission set ... false
uhh, another issue
the part that's supossed to like say No pvping with builders! or so, doesnt work at all, and pvping just isnt possible
hm
just debug it
i tried to yeah
maybe other plugins
I think pvpmanager's messing with it
ok
strangely enough
it works on 1 player, but not the other
infact it works on everyone expect that 1 dude
he has the exact same permissions as someone else
what doesnt work
it doesnt send any msgs and pvp doesnt work
idk bro
sometimes luckperms kinda buggy
i recommended using variables instead
have you tried commands?
it seems like it doesnt work on anyone who logged on before I finalized the skript
ye i think
just use variables
no, i dont wanna
hm
didnt work it seems
when I ask them to do /fighter it doesnt give an output for them
oh
i know
you forgot to delete the cooldown after it ends
nope nvm
cooldown-time: 1 hour
on join:
wait 1 tick
if player doesn't have permission "group.fighter":
if player doesn't have permission "group.builder":
execute console command "lp user %player% parent add fighter"
send "&aHey! You have been given the Fighter role automatically, do /builder to switch to no pvp."
command /fighter:
trigger:
if player doesn't have permission "group.fighter":
if player has permission "skript.roles_cooldown":
execute console command "lp user %player% parent remove builder"
execute console command "lp user %player% parent add fighter"
send "&aYou are now part of the Fighter team!"
else if {teamCooldown::%player%} is set:
set {_timeLeft} to difference between now and {teamCooldown::%player%}
if {_timeLeft} < {@cooldown-time}:
set {_remaining} to difference between {@cooldown-time} and {_timeLeft}
send "&cYou cannot switch teams yet! Wait &e%{_remaining}%&c."
else:
execute console command "lp user %player% parent remove builder"
execute console command "lp user %player% parent add fighter"
send "&aYou are now part of the Fighter team!"
set {teamCooldown::%player%} to now
run task {@cooldown-time} later:
delete {teamCooldown::%player%}
else:
send "&cYou are already part of the Fighter team!"```
i think this should do
when the {teamCooldown::%player%} is set to now
after 1 hour it should delete
but you forgot to delete it so it stays
i added when the {teamCooldown::%player%} passed the cooldown time, it will delete after running the command
you should add on load: delete {teamCooldown::*}
wait a second
doesnt that bring back an older error
where we removed the stop part and replaced it with an else
nah it wont
nope
it brought it back
ah it for some reason uses parent again
wow its broken again
add this on load: delete {teamCooldown::*}
aha managed to fix it
test this
cooldown-time: 1 hour
on join:
wait 1 tick
if player doesn't have permission "group.fighter":
if player doesn't have permission "group.builder":
execute console command "lp user %player% parent add fighter"
send "&aHey! You have been given the Fighter role automatically, do /builder to switch to no pvp."
command /fighter:
trigger:
if player doesn't have permission "group.fighter":
if player has permission "skript.roles_cooldown":
execute console command "lp user %player% parent remove builder"
execute console command "lp user %player% parent add fighter"
send "&aYou are now part of the Fighter team!"
else if {teamCooldown::%player%} is set:
set {_timeLeft} to difference between now and {teamCooldown::%player%}
set {_remaining} to difference between {@cooldown-time} and {_timeLeft}
send "&cYou cannot switch teams yet! Wait &e%{_remaining}%&c."
else:
execute console command "lp user %player% parent remove builder"
execute console command "lp user %player% parent add fighter"
send "&aYou are now part of the Fighter team!"
set {teamCooldown::%player%} to now
run task {@cooldown-time} later:
delete {teamCooldown::%player%}
else:
send "&cYou are already part of the Fighter team!"```
i made it shorter
idk if it works or not
the "run task ... later:" is like "wait ..." but doesnt delay the next line