hasitem엔 내구도 감지는 없지만 다른 방법으로 공용으로 감지 할수 있어요 대충 목검의 내구도가 달면 메세지를 띄우는 것은 1. clear @a[tag=a] wooden_sword 1 1 2. tag @a[tag=a] add test 3. tag @a[hasitem={item=wooden_sword,location=slot.weapon.mainhand}] remove test 4. replaceitem entity @a[tag=a,tag=test] slot.weapon.mainhand}] wooden_sword 1 0 {"item_lock":{"mode":"lock_in_inventory"}} 5. execute as @a[tag=a,tag=test] run say test
혹시 slot.armor.head 에 철투구가 "없는" 플레이어 감지 ㄱㄴ?
1. tag @a remove air (반복 | 무조건부)
2. tag @a[hasitem={item=iron_helmet,location=slot.armor.head}] add air (체인 | 무조건부)
3. testfor @a[tag=!air] (체인 | 무조건부)
@@시빈드굳이 그렇게 안하고 그냥 execute unless 쓰면 됨(아닐 경우 작동)
hasitem 으로 내구도 감지 어떻게하나요?
hasitem엔 내구도 감지는 없지만 다른 방법으로 공용으로 감지 할수 있어요 대충 목검의 내구도가 달면 메세지를 띄우는 것은 1. clear @a[tag=a] wooden_sword 1 1
2. tag @a[tag=a] add test
3. tag @a[hasitem={item=wooden_sword,location=slot.weapon.mainhand}] remove test
4. replaceitem entity @a[tag=a,tag=test] slot.weapon.mainhand}] wooden_sword 1 0 {"item_lock":{"mode":"lock_in_inventory"}}
5. execute as @a[tag=a,tag=test] run say test
@@시빈드 이러면 사람 많을때 딜레이 걸리지 않나요?
@@JinWoo06_ @r 이 아니라 딜레이는 없습니다
@@시빈드 혹시 어디에 조건부를 쓰고 순서가 어떻게 되는지 적어주실수 있나요?
@@JinWoo06_ 1번은 반복 나머진 무조건부 하면됨미다
완벽한 강좌네요!
감사합니다