Welcome to skUnity! This is a forum where members of the Skript community can communicate and interact. Skript Resource Creators can post their Resources for all to see and use.
If you haven't done so already, feel free to join our official Discord server to expand your level of interaction with the comminuty!
Now, what are you waiting for? Join the community now!
You can always check out skUnity Downloads for downloads and any other information about Skript!
#Delete last line
set {_s} to size of lore of loop-item
delete line {_s} of lore of loop-item
It says I cannot delete the lore of a loop item.This should work:
Code:#Delete last line set {_s} to size of lore of loop-item delete line {_s} of lore of loop-item
set {_item} to loop-item
nopeHmm, I can’t test if this works at the moment, but perhaps you can try to save the item as a (temp) variable, i.e.
Then change the lore of that.Code:set {_item} to loop-item
If that doesn’t work, then I’m not really sure haha
Are you sure? This returns no errors for me:nope
same error
on death of player:
loop drops:
if lore of loop-item contains "&7Soulbound I":
remove loop-item from drops
set {_i} to loop-item
set {_s} to size of lore of {_i}
delete line {_s} of lore of {_i}
wait 5 ticks
add {_s} to victim's inventory
ok it has no errors but when I respawn the items are gone.Are you sure? This returns no errors for me:
Code:on death of player: loop drops: if lore of loop-item contains "&7Soulbound I": remove loop-item from drops set {_i} to loop-item set {_s} to size of lore of {_i} delete line {_s} of lore of {_i} wait 5 ticks add {_s} to victim's inventory
Does it still happen when nothing is done to the lore of the item?ok it has no errors but when I respawn the items are gone.
on death of player:
loop drops:
if lore of loop-item contains "&7Soulbound I":
remove loop-item from drops
wait 5 ticks
add loop-item to victim's inventory
no the dropped item doesnt have removed lore.Does it still happen when nothing is done to the lore of the item?
Code:on death of player: loop drops: if lore of loop-item contains "&7Soulbound I": remove loop-item from drops wait 5 ticks add loop-item to victim's inventory
no the dropped item doesnt have removed lore.
on death of player:
loop drops:
if lore of loop-item contains "&7Soulbound I":
remove loop-item from drops
set {_i} to loop-item
set {_s} to size of lore of {_i}
delete line {_s} of lore of {_i}
add {_i} to {_to.give}
wait 5 ticks
add {_to.give} to victim's inventory
Now there is no dropped item or item in my inventory.It's because they put 5 ticks delay directly into loop. Try this:
Code:on death of player: loop drops: if lore of loop-item contains "&7Soulbound I": remove loop-item from drops set {_i} to loop-item set {_s} to size of lore of {_i} delete line {_s} of lore of {_i} add {_i} to {_to.give} wait 5 ticks add {_to.give} to victim's inventory
Now there is no dropped item or item in my inventory.
on death of player:
loop drops:
if lore of loop-item contains "&7Soulbound I":
remove loop-item from drops
set {_i} to loop-item
set {_s} to size of lore of {_i}
delete line {_s} of lore of {_i}
add {_i} to {_to.give::*}
wait 5 ticks
add {_to.give::*} to victim's inventory
worksWhoops.. forgot to make it array variable:
Code:on death of player: loop drops: if lore of loop-item contains "&7Soulbound I": remove loop-item from drops set {_i} to loop-item set {_s} to size of lore of {_i} delete line {_s} of lore of {_i} add {_i} to {_to.give::*} wait 5 ticks add {_to.give::*} to victim's inventory
Never mind. It's inconsistent and when it does work sometimes it removes the wrong lore.Whoops.. forgot to make it array variable:
Code:on death of player: loop drops: if lore of loop-item contains "&7Soulbound I": remove loop-item from drops set {_i} to loop-item set {_s} to size of lore of {_i} delete line {_s} of lore of {_i} add {_i} to {_to.give::*} wait 5 ticks add {_to.give::*} to victim's inventory