#thing
1 messages · Page 1 of 1 (latest)
I've only been coding in skript for a couple weeks I have no idea what that means
to debug, you could for example broadcast something after the if statement
ok
it sent the message
alr do you got any idea how to fix it?
By the way, debugging is not a skript-exclusive term
It applies to all coding
you could manually drop the loot i guess, just set the victim's inventory to a list, and drop that at the location of victim's death
I do not have the foggiest Idea how to do that
set {_items::*} to all items in inventory of victim
loop {_items::*}:
drop loop-value at location of victim
I guess
and cancel the victims drops, so you dont get duplicate items
also loop this list, instead of the players inventory for the midas sword
on death of player:
attacker is a player
victim is a player
set {sharpness::%victim%} to 0
set {_items::*} to all items in inventory of victim
loop {_items::*}:
if loop-value is netherite sword named "&6&lMidas &6&lSword":
disenchant loop-value
drop loop-value at location of victim
it says loop-value cannot be disenchanted
got any idea how to fix it
on death of player:
attacker is a player
victim is a player
cancel drops
set {sharpness::%victim%} to 0
set {_items::*} to all items in inventory of victim
loop {_items::*}:
if loop-value is netherite sword named "&6&lMidas &6&lSword":
set {_item} to loop-value
disenchant {_item}
drop {_item} at location of victim
else:
drop loop-value at location of victim
wait i am stupid
now
Tbh this is pretty complex for just wanting to drop an disenchanted item, and there might be an easier way to do it, but not sure how to achieve that
so it does disenchant it but it also drops the enchanted one
you saw the updated code?
you need to have the cancel drops thing in your code to disable the original drops
dont know how I didnt see that thanks a lot for helping btw
is it working intended now?
yes