music_quiz: 무대 의존 제거 + 정적 데이터 스토리지화 + 매 틱 게이팅

- 무대 한정 코드 제거: repeat/map/ (트리/조명), images/image_custom (파이브가이즈),
  load.mcfunction의 map 스코어보드·fill·counter 초기화
- 매 틱 디스패치를 init 상태로 게이팅:
  · timer는 init>=2, check_answer는 init in {5,6}에서만 호출
  · idle(init=0) 틱의 함수 호출 8개 → 4개
- 곡 50개를 매크로 체인(250+ 명령/회) → 스토리지 리스트 O(1) 룩업으로 전환
  mq:init/songs가 mq:main.songs를 적재, setanswer는 index-1로 인덱스 룩업
- 버튼/트리거 정의를 mq:init/buttons / mq:init/triggers로 분리해
  mq:main.button_defs · trigger_defs 스토리지 리스트로 관리
- repeat/triggers/trigger.mcfunction: 투표 후처리 산술 블록 중 변하지 않는
  max_player·rest_player 재계산 제거, $(n)_player 갱신만 1라인
- 작가용 메모 수정.txt 제거
- README.md: 변경 사항·새 구조·스토리지 스키마 반영

566 lines -, 154 lines +.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
Claude (owner)
2026-05-13 15:45:35 +09:00
parent b1babad05a
commit 2b61af28a8
16 changed files with 212 additions and 561 deletions

View File

@@ -1,6 +0,0 @@
# r = EAST | NORTH | SOUTH | WEST
# 파이브가이즈 간판
data modify storage mq:main command_block.image set value "ts placeloc fiveguys1.png world EAST 90 72 -168 90 73 -170 1 솔리드스킵"
function mq:images/image_set with storage mq:main command_block

View File

@@ -0,0 +1,7 @@
data modify storage mq:main button_defs set value []
data modify storage mq:main button_defs append value {n:"start", x:140, y:62, z:-225, f:"south", c:"function mq:commands/start with storage mq:main"}
data modify storage mq:main button_defs append value {n:"stop", x:142, y:62, z:-225, f:"south", c:"function mq:commands/stop with storage mq:main"}
data modify storage mq:main button_defs append value {n:"skip", x:144, y:62, z:-225, f:"south", c:"function mq:commands/skip"}
data modify storage mq:main button_defs append value {n:"hint", x:146, y:62, z:-225, f:"south", c:"function mq:commands/hint"}
data modify storage mq:main button_defs append value {n:"replay", x:148, y:62, z:-225, f:"south", c:"function mq:commands/replay"}
data modify storage mq:main button_defs append value {n:"test", x:144, y:62, z:-213, f:"north", c:"function mq:commands/test"}

View File

@@ -0,0 +1,51 @@
data modify storage mq:main songs set value []
data modify storage mq:main songs append value {title:"Lose My Mind", author:"Don Toliver", alias:[" "," "," "]}
data modify storage mq:main songs append value {title:"The Chase", author:"Hearts2Hearts", alias:[" "," "," "]}
data modify storage mq:main songs append value {title:"HOT SAUCE", author:"BABYMONSTER", alias:[" "," "]}
data modify storage mq:main songs append value {title:"Golden", author:"HUNTR/X", alias:[""," "]}
data modify storage mq:main songs append value {title:"돌림판", author:"머쉬베놈", alias:["Spin the wheel"]}
data modify storage mq:main songs append value {title:"OVERDRIVE", author:"TWS", alias:["",""]}
data modify storage mq:main songs append value {title:"눈물참기", author:"QWER", alias:[]}
data modify storage mq:main songs append value {title:"깨어", author:"tripleS", alias:[]}
data modify storage mq:main songs append value {title:"like JENNIE", author:"제니", alias:[" "," "," "," "]}
data modify storage mq:main songs append value {title:"Rich Man", author:"aespa", alias:[" "," "]}
data modify storage mq:main songs append value {title:"I DO ME", author:"KiiiKiii", alias:[" "," "," "]}
data modify storage mq:main songs append value {title:"SIGN", author:"izna", alias:["",""]}
data modify storage mq:main songs append value {title:"WICKED", author:"ALLDAY PROJECT", alias:["",""]}
data modify storage mq:main songs append value {title:"Good Thing", author:"i-dle", alias:["굿 "," "," "]}
data modify storage mq:main songs append value {title:"0+0", author:"한로로", alias:[]}
data modify storage mq:main songs append value {title:"HANDS UP", author:"MEOVV", alias:[" "," "," "]}
data modify storage mq:main songs append value {title:"Blue Valentine", author:"NMIXX", alias:[" "," "]}
data modify storage mq:main songs append value {title:"Flower", author:"오반", alias:["",""]}
data modify storage mq:main songs append value {title:"Soda Pop", author:"Saja Boys", alias:[" "," "]}
data modify storage mq:main songs append value {title:"REBEL HEART", author:"IVE", alias:[" "," "]}
data modify storage mq:main songs append value {title:"GO!", author:"CORTIS", alias:["","!","GO","","!"]}
data modify storage mq:main songs append value {title:"BEEP", author:"izna", alias:["","",""]}
data modify storage mq:main songs append value {title:"Pookie", author:"FIFTY FIFTY", alias:["",""]}
data modify storage mq:main songs append value {title:"DAISIES", author:"Justin Bieber", alias:["","",""]}
data modify storage mq:main songs append value {title:"빌려온 고양이", author:"ILLIT", alias:[]}
data modify storage mq:main songs append value {title:"TOO BAD", author:"OfficialGDRAGON", alias:[" "," "," "]}
data modify storage mq:main songs append value {title:"시작의 아이", author:"마크툽", alias:[]}
data modify storage mq:main songs append value {title:"STYLE", author:"Hearts2Hearts", alias:["",""]}
data modify storage mq:main songs append value {title:"Good Goodbye", author:"화사", alias:["굿 굿"," "," "]}
data modify storage mq:main songs append value {title:"너에게 닿기를", author:"10CM", alias:[]}
data modify storage mq:main songs append value {title:"IRIS OUT", author:"Kenshi Yonezu", alias:[" "," "," "]}
data modify storage mq:main songs append value {title:"Sugar On My Tongue", author:"Tyler, The Creator", alias:[" "," "," "]}
data modify storage mq:main songs append value {title:"Hollywood Action", author:"BOYNEXTDOOR", alias:[" "," "]}
data modify storage mq:main songs append value {title:"SPAGHETTI", author:"LE SSERAFIM", alias:["",""]}
data modify storage mq:main songs append value {title:"Gabriela", author:"KATSEYE", alias:["",""]}
data modify storage mq:main songs append value {title:"LIKE YOU BETTER", author:"프로미스나인", alias:[" "," "," "," "," "]}
data modify storage mq:main songs append value {title:"뛰어", author:"BLACKPINK", alias:["jump"]}
data modify storage mq:main songs append value {title:"CHANEL", author:"Tyla", alias:["",""]}
data modify storage mq:main songs append value {title:"오늘만 I LOVE YOU", author:"BOYNEXTDOOR", alias:[" "," "]}
data modify storage mq:main songs append value {title:"earthquake", author:"지수", alias:["","",""," "]}
data modify storage mq:main songs append value {title:"윽!", author:"염따", alias:[""]}
data modify storage mq:main songs append value {title:"Abracadabra", author:"Lady Gaga", alias:["",""]}
data modify storage mq:main songs append value {title:"멸종위기사랑", author:"이찬혁", alias:[]}
data modify storage mq:main songs append value {title:"Dirty Work", author:"aespa", alias:[" "," "," "," "," "]}
data modify storage mq:main songs append value {title:"HOT", author:"LE SSERAFIM", alias:["",""]}
data modify storage mq:main songs append value {title:"FAMOUS", author:"ALLDAY PROJECT", alias:["",""]}
data modify storage mq:main songs append value {title:"XOXZ", author:"IVE", alias:[" "," ",""]}
data modify storage mq:main songs append value {title:"여름이었다", author:"H1-KEY", alias:[]}
data modify storage mq:main songs append value {title:"LOV3", author:"식케이", alias:["3","3"]}
data modify storage mq:main songs append value {title:"Drive", author:"Ed Sheeran", alias:["",""]}

View File

@@ -0,0 +1,5 @@
data modify storage mq:main trigger_defs set value []
data modify storage mq:main trigger_defs append value {n:"stop", n2:"중지", c:"function mq:commands/stop with storage mq:main"}
data modify storage mq:main trigger_defs append value {n:"skip", n2:"스킵", c:"function mq:commands/skip"}
data modify storage mq:main trigger_defs append value {n:"hint", n2:"힌트", c:"function mq:commands/hint"}
data modify storage mq:main trigger_defs append value {n:"replay", n2:"다시재생", c:"function mq:commands/replay"}

View File

@@ -30,11 +30,15 @@ data merge storage mq:main { \
} \
}
data merge storage func:temp {}
data merge storage mq:tmp {}
function mq:init/songs
function mq:init/buttons
function mq:init/triggers
scoreboard objectives remove func.temp
scoreboard objectives remove status
scoreboard objectives remove main
scoreboard objectives remove map
scoreboard objectives remove buttons
scoreboard objectives remove answer
scoreboard objectives remove leave_game
@@ -42,7 +46,6 @@ scoreboard objectives remove leave_game
scoreboard objectives add func.temp dummy
scoreboard objectives add status dummy
scoreboard objectives add main dummy
scoreboard objectives add map dummy
scoreboard objectives add buttons dummy
scoreboard objectives add answer dummy
scoreboard objectives add leave_game custom:leave_game
@@ -53,9 +56,6 @@ scoreboard players set yp status 0
scoreboard players set ts status 0
scoreboard players set two func.temp 2
scoreboard players set tree map -1
fill 94 78 -279 194 78 -279 minecraft:red_wool
scoreboard players set lamp1 map -1
bossbar add mq:process [{"text":"진행도: ","color": "yellow","bold": true},{"text":"0","color": "yellow","bold": true},{"text":"/","color": "yellow","bold": true},{"text":"0","color": "yellow","bold": true}]

View File

@@ -1,6 +1,3 @@
$execute if score index main matches $(index) run data modify storage mq:main answer.author set value "$(author)"
$execute if score index main matches $(index) run data modify storage mq:main command_block.name set value "$(title)"
$execute if score index main matches $(index) run data modify storage mq:main command_block.alias set value $(alias)
data modify storage mq:main answer.title set from storage mq:main command_block.name
data modify storage mq:main answer.alias set from storage mq:main command_block.alias
$data modify storage mq:main answer set from storage mq:main songs[$(idx)]
$data modify storage mq:main command_block.name set from storage mq:main songs[$(idx)].title
$data modify storage mq:main command_block.alias set from storage mq:main songs[$(idx)].alias

View File

@@ -1,304 +1,8 @@
function mq:quiz/macro/setanswer { \
index: 1, \
title: "Lose My Mind", \
author: "Don Toliver", \
alias: [" "," ", " "] \
}
function mq:quiz/macro/setanswer { \
index: 2, \
title: "The Chase", \
author: "Hearts2Hearts", \
alias: [" ", " ", " "] \
}
function mq:quiz/macro/setanswer { \
index: 3, \
title: "HOT SAUCE", \
author: "BABYMONSTER", \
alias: [" ", " "] \
}
function mq:quiz/macro/setanswer { \
index: 4, \
title: "Golden", \
author: "HUNTR/X", \
alias: [""," "] \
}
function mq:quiz/macro/setanswer { \
index: 5, \
title: "", \
author: "", \
alias: ["Spin the wheel"] \
}
function mq:quiz/macro/setanswer { \
index: 6, \
title: "OVERDRIVE", \
author: "TWS", \
alias: ["", ""] \
}
function mq:quiz/macro/setanswer { \
index: 7, \
title: "", \
author: "QWER", \
alias: [] \
}
function mq:quiz/macro/setanswer { \
index: 8, \
title: "", \
author: "tripleS", \
alias: [] \
}
function mq:quiz/macro/setanswer { \
index: 9, \
title: "like JENNIE", \
author: "", \
alias: [" ", " ", " ", " "] \
}
function mq:quiz/macro/setanswer { \
index: 10, \
title: "Rich Man", \
author: "aespa", \
alias: [" ", " "] \
}
function mq:quiz/macro/setanswer { \
index: 11, \
title: "I DO ME", \
author: "KiiiKiii", \
alias: [" ", " ", " "] \
}
function mq:quiz/macro/setanswer { \
index: 12, \
title: "SIGN", \
author: "izna", \
alias: ["", ""] \
}
function mq:quiz/macro/setanswer { \
index: 13, \
title: "WICKED", \
author: "ALLDAY PROJECT", \
alias: ["", ""] \
}
function mq:quiz/macro/setanswer { \
index: 14, \
title: "Good Thing", \
author: "i-dle", \
alias: ["굿 ", " ", " "] \
}
function mq:quiz/macro/setanswer { \
index: 15, \
title: "0+0", \
author: "", \
alias: [] \
}
function mq:quiz/macro/setanswer { \
index: 16, \
title: "HANDS UP", \
author: "MEOVV", \
alias: [" ", " ", " "] \
}
function mq:quiz/macro/setanswer { \
index: 17, \
title: "Blue Valentine", \
author: "NMIXX", \
alias: [" ", " "] \
}
function mq:quiz/macro/setanswer { \
index: 18, \
title: "Flower", \
author: "", \
alias: ["", ""] \
}
function mq:quiz/macro/setanswer { \
index: 19, \
title: "Soda Pop", \
author: "Saja Boys", \
alias: [" ", " "] \
}
function mq:quiz/macro/setanswer { \
index: 20, \
title: "REBEL HEART", \
author: "IVE", \
alias: [" ", " "] \
}
function mq:quiz/macro/setanswer { \
index: 21, \
title: "GO!", \
author: "CORTIS", \
alias: ["", "!", "GO", "", "!"] \
}
function mq:quiz/macro/setanswer { \
index: 22, \
title: "BEEP", \
author: "izna", \
alias: ["", "", ""] \
}
function mq:quiz/macro/setanswer { \
index: 23, \
title: "Pookie", \
author: "FIFTY FIFTY", \
alias: ["", ""] \
}
function mq:quiz/macro/setanswer { \
index: 24, \
title: "DAISIES", \
author: "Justin Bieber", \
alias: ["", "", ""] \
}
function mq:quiz/macro/setanswer { \
index: 25, \
title: " ", \
author: "ILLIT", \
alias: [] \
}
function mq:quiz/macro/setanswer { \
index: 26, \
title: "TOO BAD", \
author: "OfficialGDRAGON", \
alias: [" ", " ", " "] \
}
function mq:quiz/macro/setanswer { \
index: 27, \
title: " ", \
author: "", \
alias: [] \
}
function mq:quiz/macro/setanswer { \
index: 28, \
title: "STYLE", \
author: "Hearts2Hearts", \
alias: ["", ""] \
}
function mq:quiz/macro/setanswer { \
index: 29, \
title: "Good Goodbye", \
author: "", \
alias: ["굿 굿", " ", " "] \
}
function mq:quiz/macro/setanswer { \
index: 30, \
title: " ", \
author: "10CM", \
alias: [] \
}
function mq:quiz/macro/setanswer { \
index: 31, \
title: "IRIS OUT", \
author: "Kenshi Yonezu", \
alias: [" ", " ", " "] \
}
function mq:quiz/macro/setanswer { \
index: 32, \
title: "Sugar On My Tongue", \
author: "Tyler, The Creator", \
alias: [" ", " ", " "] \
}
function mq:quiz/macro/setanswer { \
index: 33, \
title: "Hollywood Action", \
author: "BOYNEXTDOOR", \
alias: [" ", " "] \
}
function mq:quiz/macro/setanswer { \
index: 34, \
title: "SPAGHETTI", \
author: "LE SSERAFIM", \
alias: ["", ""] \
}
function mq:quiz/macro/setanswer { \
index: 35, \
title: "Gabriela", \
author: "KATSEYE", \
alias: ["", ""] \
}
function mq:quiz/macro/setanswer { \
index: 36, \
title: "LIKE YOU BETTER", \
author: "", \
alias: [" ", " ", " ", " ", " "] \
}
function mq:quiz/macro/setanswer { \
index: 37, \
title: "", \
author: "BLACKPINK", \
alias: ["jump"] \
}
function mq:quiz/macro/setanswer { \
index: 38, \
title: "CHANEL", \
author: "Tyla", \
alias: ["", ""] \
}
function mq:quiz/macro/setanswer { \
index: 39, \
title: " I LOVE YOU", \
author: "BOYNEXTDOOR", \
alias: [" ", " "] \
}
function mq:quiz/macro/setanswer { \
index: 40, \
title: "earthquake", \
author: "", \
alias: ["", "", ""," "] \
}
function mq:quiz/macro/setanswer { \
index: 41, \
title: "!", \
author: "", \
alias: [""] \
}
function mq:quiz/macro/setanswer { \
index: 42, \
title: "Abracadabra", \
author: "Lady Gaga", \
alias: ["", ""] \
}
function mq:quiz/macro/setanswer { \
index: 43, \
title: "", \
author: "", \
alias: [] \
}
function mq:quiz/macro/setanswer { \
index: 44, \
title: "Dirty Work", \
author: "aespa", \
alias: [" ", " ", " ", " ", " "] \
}
function mq:quiz/macro/setanswer { \
index: 45, \
title: "HOT", \
author: "LE SSERAFIM", \
alias: ["", ""] \
}
function mq:quiz/macro/setanswer { \
index: 46, \
title: "FAMOUS", \
author: "ALLDAY PROJECT", \
alias: ["", ""] \
}
function mq:quiz/macro/setanswer { \
index: 47, \
title: "XOXZ", \
author: "IVE", \
alias: [" ", " ", ""] \
}
function mq:quiz/macro/setanswer { \
index: 48, \
title: "", \
author: "H1-KEY", \
alias: [] \
}
function mq:quiz/macro/setanswer { \
index: 49, \
title: "LOV3", \
author: "", \
alias: ["3", "3"] \
}
function mq:quiz/macro/setanswer { \
index: 50, \
title: "Drive", \
author: "Ed Sheeran", \
alias: ["", ""] \
}
scoreboard players operation song_idx func.temp = index main
scoreboard players remove song_idx func.temp 1
execute store result storage mq:tmp idx int 1 run scoreboard players get song_idx func.temp
function mq:quiz/macro/setanswer with storage mq:tmp
scoreboard players set stop buttons -1
scoreboard players set skip buttons -1

View File

@@ -1,48 +1,6 @@
function mq:repeat/buttons/btn { \
n: "start", \
x: 140, \
y: 62, \
z: -225, \
f: "south", \
c: "function mq:commands/start with storage mq:main" \
}
function mq:repeat/buttons/btn { \
n: "stop", \
x: 142, \
y: 62, \
z: -225, \
f: "south", \
c: "function mq:commands/stop with storage mq:main" \
}
function mq:repeat/buttons/btn { \
n: "skip", \
x: 144, \
y: 62, \
z: -225, \
f: "south", \
c: "function mq:commands/skip" \
}
function mq:repeat/buttons/btn { \
n: "hint", \
x: 146, \
y: 62, \
z: -225, \
f: "south", \
c: "function mq:commands/hint" \
}
function mq:repeat/buttons/btn { \
n: "replay", \
x: 148, \
y: 62, \
z: -225, \
f: "south", \
c: "function mq:commands/replay" \
}
function mq:repeat/buttons/btn { \
n: "test", \
x: 144, \
y: 62, \
z: -213, \
f: "north", \
c: "function mq:commands/test" \
}
function mq:repeat/buttons/btn with storage mq:main button_defs[0]
function mq:repeat/buttons/btn with storage mq:main button_defs[1]
function mq:repeat/buttons/btn with storage mq:main button_defs[2]
function mq:repeat/buttons/btn with storage mq:main button_defs[3]
function mq:repeat/buttons/btn with storage mq:main button_defs[4]
function mq:repeat/buttons/btn with storage mq:main button_defs[5]

View File

@@ -1,22 +0,0 @@
execute unless score lamp1 map matches 0.. run scoreboard players set lamp1 map 1
execute unless score lamp1.on map matches 0.. run scoreboard players set lamp1.on map 94
execute unless score lamp1.off map matches 0.. run scoreboard players set lamp1.off map 85
execute unless score lamp1.on2 map matches 0.. run scoreboard players set lamp1.on2 map 44
execute unless score lamp1.off2 map matches 0.. run scoreboard players set lamp1.off2 map 35
execute if score lamp1 map matches 1.. run scoreboard players add lamp1 map 1
execute if score lamp1 map matches 3 if score lamp1.on map matches 195.. run scoreboard players set lamp1.on map 94
execute if score lamp1 map matches 3 if score lamp1.off map matches 195.. run scoreboard players set lamp1.off map 94
execute if score lamp1 map matches 3 if score lamp1.on2 map matches 195.. run scoreboard players set lamp1.on2 map 94
execute if score lamp1 map matches 3 if score lamp1.off2 map matches 195.. run scoreboard players set lamp1.off2 map 94
execute if score lamp1 map matches 3 run execute store result storage mq:main map.lamp1.on int 1 run scoreboard players get lamp1.on map
execute if score lamp1 map matches 3 run execute store result storage mq:main map.lamp1.off int 1 run scoreboard players get lamp1.off map
execute if score lamp1 map matches 3 run execute store result storage mq:main map.lamp1.on2 int 1 run scoreboard players get lamp1.on2 map
execute if score lamp1 map matches 3 run execute store result storage mq:main map.lamp1.off2 int 1 run scoreboard players get lamp1.off2 map
execute if score lamp1 map matches 3 run function mq:repeat/map/macro/lamp1 with storage mq:main map.lamp1
execute if score lamp1 map matches 3 run scoreboard players add lamp1.on map 1
execute if score lamp1 map matches 3 run scoreboard players add lamp1.off map 1
execute if score lamp1 map matches 3 run scoreboard players add lamp1.on2 map 1
execute if score lamp1 map matches 3 run scoreboard players add lamp1.off2 map 1
execute if score lamp1 map matches 3.. run scoreboard players set lamp1 map 1

View File

@@ -1,4 +0,0 @@
$execute if score lamp1.on map matches 94..194 positioned $(on) 78 -279 if block ~ ~ ~1 minecraft:redstone_lamp run setblock ~ ~ ~ minecraft:redstone_block
$execute if score lamp1.off map matches 94..194 positioned $(off) 78 -279 if block ~ ~ ~1 minecraft:redstone_lamp run setblock ~ ~ ~ minecraft:red_wool
$execute if score lamp1.on2 map matches 94..194 positioned $(on2) 78 -279 if block ~ ~ ~1 minecraft:redstone_lamp run setblock ~ ~ ~ minecraft:redstone_block
$execute if score lamp1.off2 map matches 94..194 positioned $(off2) 78 -279 if block ~ ~ ~1 minecraft:redstone_lamp run setblock ~ ~ ~ minecraft:red_wool

View File

@@ -1,60 +0,0 @@
execute unless score tree map matches 0.. run scoreboard players set tree map 1
execute if score tree map matches 1.. run scoreboard players add tree map 1
# 1층 시작
execute if score tree map matches 6 run setblock 142 66 -186 minecraft:redstone_lamp[lit=true]
execute if score tree map matches 6 run setblock 147 66 -191 minecraft:redstone_lamp[lit=true]
execute if score tree map matches 6 run setblock 142 66 -196 minecraft:redstone_lamp[lit=true]
execute if score tree map matches 6 run setblock 137 66 -191 minecraft:redstone_lamp[lit=true]
# 1층 끝
execute if score tree map matches 16 run setblock 142 66 -186 minecraft:redstone_lamp[lit=false]
execute if score tree map matches 16 run setblock 147 66 -191 minecraft:redstone_lamp[lit=false]
execute if score tree map matches 16 run setblock 142 66 -196 minecraft:redstone_lamp[lit=false]
execute if score tree map matches 16 run setblock 137 66 -191 minecraft:redstone_lamp[lit=false]
# 2층 시작
execute if score tree map matches 16 run setblock 142 70 -195 minecraft:redstone_lamp[lit=true]
execute if score tree map matches 16 run setblock 138 70 -191 minecraft:redstone_lamp[lit=true]
execute if score tree map matches 16 run setblock 142 70 -187 minecraft:redstone_lamp[lit=true]
execute if score tree map matches 16 run setblock 146 70 -191 minecraft:redstone_lamp[lit=true]
# 2층 끝
execute if score tree map matches 26 run setblock 142 70 -195 minecraft:redstone_lamp[lit=false]
execute if score tree map matches 26 run setblock 138 70 -191 minecraft:redstone_lamp[lit=false]
execute if score tree map matches 26 run setblock 142 70 -187 minecraft:redstone_lamp[lit=false]
execute if score tree map matches 26 run setblock 146 70 -191 minecraft:redstone_lamp[lit=false]
# 3층 시작
execute if score tree map matches 26 run setblock 142 74 -194 minecraft:redstone_lamp[lit=true]
execute if score tree map matches 26 run setblock 139 74 -191 minecraft:redstone_lamp[lit=true]
execute if score tree map matches 26 run setblock 142 74 -188 minecraft:redstone_lamp[lit=true]
execute if score tree map matches 26 run setblock 145 74 -191 minecraft:redstone_lamp[lit=true]
# 3층 끝
execute if score tree map matches 36 run setblock 142 74 -194 minecraft:redstone_lamp[lit=false]
execute if score tree map matches 36 run setblock 139 74 -191 minecraft:redstone_lamp[lit=false]
execute if score tree map matches 36 run setblock 142 74 -188 minecraft:redstone_lamp[lit=false]
execute if score tree map matches 36 run setblock 145 74 -191 minecraft:redstone_lamp[lit=false]
# 4층 시작
execute if score tree map matches 36 run setblock 142 78 -193 minecraft:redstone_lamp[lit=true]
execute if score tree map matches 36 run setblock 140 78 -191 minecraft:redstone_lamp[lit=true]
execute if score tree map matches 36 run setblock 142 78 -189 minecraft:redstone_lamp[lit=true]
execute if score tree map matches 36 run setblock 144 78 -191 minecraft:redstone_lamp[lit=true]
# 4층 끝
execute if score tree map matches 46 run setblock 142 78 -193 minecraft:redstone_lamp[lit=false]
execute if score tree map matches 46 run setblock 140 78 -191 minecraft:redstone_lamp[lit=false]
execute if score tree map matches 46 run setblock 142 78 -189 minecraft:redstone_lamp[lit=false]
execute if score tree map matches 46 run setblock 144 78 -191 minecraft:redstone_lamp[lit=false]
# TOP 시작
execute if score tree map matches 46 run setblock 142 81 -191 minecraft:redstone_lamp[lit=true]
# TOP 끝
execute if score tree map matches 56 run setblock 142 81 -191 minecraft:redstone_lamp[lit=false]
execute if score tree map matches 61.. run scoreboard players set tree map 1

View File

@@ -18,23 +18,7 @@ execute if score init main matches 0..1 \
run function mq:quiz/start with storage mq:main
function mq:repeat/triggers/trigger { \
n:"stop", \
n2:"", \
c:"function mq:commands/stop with storage mq:main" \
}
function mq:repeat/triggers/trigger { \
n:"skip", \
n2:"", \
c:"function mq:commands/skip" \
}
function mq:repeat/triggers/trigger { \
n:"hint", \
n2:"", \
c:"function mq:commands/hint" \
}
function mq:repeat/triggers/trigger { \
n:"replay", \
n2:"", \
c:"function mq:commands/replay" \
}
function mq:repeat/triggers/trigger with storage mq:main trigger_defs[0]
function mq:repeat/triggers/trigger with storage mq:main trigger_defs[1]
function mq:repeat/triggers/trigger with storage mq:main trigger_defs[2]
function mq:repeat/triggers/trigger with storage mq:main trigger_defs[3]

View File

@@ -20,11 +20,6 @@ $execute as @a if score @s $(n) matches 1 run scoreboard players set @s $(n) 2
$execute as @a if score @s $(n) matches 3 run function mq:tellraw {"text":"","color":"black",msg:[{"selector":"@s","color": "yellow","bold": true}," : ",{"text":"이미 $(n2)투표를 하셨습니다.","color": "red"}]}
$execute as @a if score @s $(n) matches 3 run scoreboard players set @s $(n) 2
$execute store result score rest_player $(n) if entity @a
$execute unless score rest_player $(n) matches 0 run scoreboard players operation rest_player $(n) %= two func.temp
$execute store result score max_player $(n) if entity @a
$execute unless score real_max_player $(n) matches 0 run scoreboard players operation max_player $(n) /= two func.temp
$execute unless score real_max_player $(n) matches 0 run scoreboard players operation max_player $(n) += rest_player $(n)
$execute store result score $(n)_player $(n) if entity @a[scores={$(n)=2..}]
$execute unless score real_max_player $(n) matches 0 \

View File

@@ -1,9 +1,7 @@
function mq:repeat/check_server
function mq:repeat/players
function mq:repeat/check_answer
function mq:repeat/timer
function mq:repeat/buttons/handler
function mq:repeat/triggers/handler
function mq:repeat/check_server
function mq:repeat/map/tree
function mq:repeat/map/lamp1
execute if score init main matches 2.. run function mq:repeat/timer
execute if score init main matches 5..6 run function mq:repeat/check_answer

View File

@@ -1,9 +0,0 @@
- function/
- load.mcfunction
- buttons/
- handler.mcfunction
- quiz/
- setanswer.mcfunction
# 이미지 명령어 추가