music_quiz: dialog 기반 정답 입력 + 큐 기반 first-submit-wins 추가
정답 입력 UI 를 dialog 로 제공 (mq:dialog/answer), #minecraft:quick_actions 태그 등록으로 빠른행동키에서 바로 열 수 있게 함. 동시 제출 시 먼저 제출한 사람이 정답으로 인정되도록 mq:answer/ 에 submit_seq 기반 FIFO 큐 + 매크로 기반 제출자 lookup 으로 처리. tick/stop/setanswer 도 새 큐 흐름에 맞춰 업데이트.
This commit is contained in:
@@ -0,0 +1,2 @@
|
||||
# queue entry 의 seq 점수를 가진 플레이어(@s) 컨텍스트로 judge 실행
|
||||
$execute as @a[scores={submit_seq=$(seq)},limit=1] run function mq:answer/judge
|
||||
@@ -0,0 +1,3 @@
|
||||
# judge.input 과 judge.answer 가 같으면 @s answer = 1
|
||||
# 매크로 치환으로 answer 필드를 NBT predicate 의 리터럴로 박아넣음
|
||||
$execute if data storage mq:tmp judge {input:"$(answer)"} run scoreboard players set @s answer 1
|
||||
Reference in New Issue
Block a user