개인 자료란 (JE)

  서버 커뮤니티

Profile 심심할때코딩함 대표칭호 없음
Profile

질문하기 스크립트

loop-player 하니까 보스바 타이머가 명령어를 친 사람한테만 뜨지 않아요

2024.07.31 조회 수 208 추천 수 0
이해도 초보자 
게임버전 (JE) 1.19 
게임버전 (BE) 관련없음 

/start <시간> 을 입력하면 모든 플레이어에게 보스바 타이머를 동일하게 띄우려고 아래에 loop all players 구문을 사용하여 스크립트를 작성하였습니다.

command /start [<number>]:

    trigger:

        if player is op:

            if arg-1 is not set:

                message "&c시작 시간을 입력해주세요."

                message "&6/start <시간(초)>"

            else if arg-1 is not bigger than 0:

                message "&c시작 시간은 1이상의 수여야만 합니다!"

            else:

                loop all players:

                    set {Timer::%uuid of loop-player%} to arg-1

                    set {MaxTimer::%uuid of loop-player%} to arg-1

                    create bossbar titled "&9&lPVP &f[&9남은 시간: &b%{Timer::%uuid of loop-player%}%&9초&f]" and id "PVP" for loop-player with progress 100 with colors blue with style segmented 10

/start를 입력하면 다른 사람들은 모두 보이는데 명령어를 입력한 사람만 보이지 않습니다. 어디가 틀린것이고 어떻게 고쳐야할까요?





4개의 댓글

개발이취미
2024.08.01

모두에게 동일하게 보여줄려고 하는거면 굳이 loop all players 가 필요할까요

@개발이취미

그럼 loop-player 에 all player로 하고 loop all players 구문을 없애면 될까요?

개발이취미
2024.08.02
@심심할때코딩함

구문이 이해가 안돼서 그러기는 한데 일단 루프하지마시고 해보세요

windy_wind
2024.08.03

id가 겹치니까 생성을 못하는거겠죠?

"PVP:%uuid of loop-player%"라든가 겹치지 않게 해야겠네요

뉴스 및 창작물
/files/thumbnails/632/197/004/262x150.crop.jpg?20260616133717

모드

Modrinth, Spark Universe와 합병하다.

BMlight

2026-06-16

0

/files/thumbnails/411/194/004/262x150.crop.jpg?20260606030535

이벤트

🎮 2026 군산 아마추어 e스포츠대회 참가자 모집! 🎮

MineStar

2026-06-04

0

사진이 없습니다.

소식

모장 인증서버 다운 5

명이

2026-06-03

0

/files/thumbnails/535/193/004/262x150.crop.jpg?20260601150848

건축

세탁소 컨텐츠 세트장 2

팀뉴일리시

2026-06-01

2

/files/thumbnails/340/187/004/262x150.crop.jpg?20260505002707

아티클

AI 검사기 디지털 시대에서 Minecraft 콘텐츠 진정성 향상

hicoyo

2026-05-05

0