이 문서에서는 Play 관리 설치를 사용하여 PC용 Google Play 게임즈에 게임을 게시하는 방법을 보여줍니다.
Play 관리 설치를 사용하면 Google Play에서 Windows 앱 번들 (WAB) 파일에 제공된 게임 파일과 메타데이터를 사용하여 게임의 설치, 업데이트, 제거를 관리합니다.
시작하기 전에
Google Play 게임즈 SDK를 게임에 통합합니다.
게임을 WAB 파일로 패키징
Play 관리 설치 WAB 파일을 만들려면 다음 단계를 따르세요.
Play 게시 도구를 다운로드합니다. Windows 명령줄 또는 Powershell에서 이 도구를 실행할 수 있습니다.
원하는 이름으로 Play 게시 구성 파일을 만듭니다. 예를 들어 다음 형식의
play_publishing_config.xml가 있습니다.<?xml version="1.0" encoding="UTF-8"?> <play-publishing-config version="1.0"> <!-- Application metadata: This section contains basic information about your game. --> <application> <package-name>PACKAGE_NAME</package-name> <version-name>VERSION_NAME</version-name> </application> <!-- Game files: This section specifies which game files to include in the bundle and how to treat them. --> <game-files> <file-set> <root-folder-path>PATH_TO_ROOT_FOLDER</root-folder-path> <!-- absolute or relative to the parent directory of the config xml --> <!-- Exclusions: A list of files or folders to exclude from the bundle. This is useful for removing development files, temporary data, or redundant assets. --> <exclusions> <file-path>REGEX_PATTERN_OF_EXCLUDED_FILES</file-path> <file-path>PATH_TO_BE_EXCLUDED</file-path> </exclusions> <!-- File attributes: Define special handling for certain files during installation and updates. --> <file-attribute value=FILE_ATTRIBUTE_VALUE> <file-path>PATH_TO_FILE</file-path> <file-path>REGEX_PATTERN_OF_FILE_ATTRIBUTE_FILES</file-path> </file-attribute> </file-set> </game-files> <!-- This file represents the startup process for this game. Google Play Games for PC should start this process when user clicks on "Play" on this game. --> <launch-command> <path>PATH_TO_LAUNCH_FILE</path> <arguments>ARGUMENTS</arguments> </launch-command> <!-- Lifecycle operations: Custom actions to be performed during the game's installation and uninstallation. --> <lifecycle-operations> <!-- Install operations: These actions run when the game is installed. 'requiresElevation="true"' will trigger a UAC prompt for administrator rights. There are three types of install operations that can be specified. An instance of each is listed below. --> <install-operation requiresElevation=INSTALL_OPERATION_REQUIRES_ELEVATION> <operation-identifier>OPERATION_IDENTIFIER_STRING</operation-identifier> <execute-file> <path>PATH_TO_INSTALL_EXECUTE_FILE</path> <arguments>ARGUMENTS</arguments> </execute-file> </install-operation> <install-operation requiresElevation=INSTALL_OPERATION_REQUIRES_ELEVATION> <operation-identifier>OPERATION_IDENTIFIER_STRING</operation-identifier> <update-registry baseKey=BASE_KEY> <sub-key>SUB_KEY_PATH</sub-key> <value-name>VALUE_NAME</value-name> <value type=REGISTRY_VALUE_TYPE>VALUE_TEXT</value> </update-registry> </install-operation> <!-- Uninstall operations: These actions run before the game is uninstalled. --> <uninstall-operation requiresElevation=UNINSTALL_OPERATION_REQUIRES_ELEVATION> <execute-file> <path>PATH_TO_UNINSTALL_EXECUTE_FILE</path> <arguments>ARGUMENTS</arguments> </execute-file> </uninstall-operation> </lifecycle-operations> </play-publishing-config>
다음을 바꿉니다.
PACKAGE_NAME: 게임의 패키지 이름입니다. Google Play에서 게임과 연결될 고유 식별자입니다. 예:com.yourcompany.yourgame패키지 이름은 다음 규칙을 준수해야 합니다.- 애플리케이션 ID는 두 개 이상의 세그먼트(한 개 이상의 점)로 구성해야 합니다.
- 각 세그먼트는 문자로 시작해야 합니다.
- 모든 문자는 영숫자 또는 밑줄 (
[a-zA-Z0-9_])이어야 합니다.
VERSION_NAME: 게임의 버전 문자열입니다. 임의의 문자열일 수 있지만 게임에 업로드된 모든 WAB에서 고유해야 합니다. 예:1.0,1.0.1-beta,2025.11.24,v1.rc1PATH_TO_ROOT_FOLDER: 게임 파일이 포함된 루트 폴더의 경로입니다. 이 폴더의 모든 파일은 예외에 언급된 파일을 제외하고 번들에 추가됩니다. 이 경로는play_publishing_config.xml파일이 포함된 디렉터리에 대한 절대 또는 상대 경로일 수 있습니다.exclusions: (선택사항) 번들에서 제외할PATH_TO_ROOT_FOLDER내 파일의 파일 경로 또는 패턴을 지정합니다.exclusions요소 내에 여러file-path요소를 포함할 수 있습니다. 경로는 다음 두 가지 방법 중 하나로 표현할 수 있습니다.- 파일 경로: 제외할 파일의 경로입니다.
- 정규식 문자열: 정규식 문자열과 일치하는 모든 파일이 번들에서 제외됩니다. RE2 구문을 사용합니다.
file-attribute: (선택사항) 특정 파일 또는 정규 표현식 패턴과 일치하는 파일의 속성을 정의합니다.FILE_ATTRIBUTE_VALUE: 다음 중 하나일 수 있습니다.SKIP_UPDATE: 업데이트 중에 이 속성은 파일이 아직 없는 경우에만 파일을 복사하여 기존 파일의 변경사항을 유지하도록 시스템에 지시합니다.MODIFIED_ON_DEVICE: 업데이트해야 하지만 설치 후 기기에서 수정할 수 있는 파일에 사용합니다. 시스템은 업데이트 중에 전체 새 파일을 다운로드하고 설치된 버전을 덮어씁니다. 이 파일이 설치 무결성 검사 중에 설치된 버전과 다른 경우 설치가 손상된 것으로 간주되지 않습니다.
file-path: 이 속성의 파일을 식별합니다. 각file-attribute요소 내에 여러file-path요소를 포함할 수 있습니다. 각 경로는 다음 두 가지 방법 중 하나로 표현할 수 있습니다.- 파일 경로: 이 속성을 연결할 파일의 경로입니다.
- 정규식 문자열: 정규식 문자열과 일치하는 모든 파일이 속성 값과 연결됩니다. RE2 구문을 사용합니다.
PATH_TO_LAUNCH_FILE: 게임을 실행하는 데 사용되는 실행 파일의 경로입니다.ARGUMENTS: (선택사항) 명령줄 인수입니다.<arguments>요소는<launch-command>,<install-operation>또는<uninstall-operation>에 지정된 실행 파일에 인수를 전달하는 데 사용됩니다.<arguments>요소의 각 사용은 정의된 실행 파일에만 적용되므로 실행 파일마다 다른 인수를 지정할 수 있습니다.- 실행 파일에 인수가 여러 개 있는 경우 공백으로 구분합니다.
- 실행 파일에 필요한 경우
--또는-을 인수에 추가합니다. 예:<arguments>--package_name --version_name</arguments>
lifecycle-operations: (선택사항) 게임 설치 또는 제거 중에 실행할 맞춤 작업입니다.install-operation: 게임이 설치될 때 실행할 작업입니다.execute-file및update-registry의 두 가지 유형의 설치 작업을 지정할 수 있습니다.uninstall-operation: 게임이 제거되기 전에 실행할 작업입니다.update-registry작업은 제거 중에 자동으로 되돌려집니다.INSTALL_OPERATION_REQUIRES_ELEVATION: 설치 작업을 관리자 권한으로 실행해야 하는지 여부를 나타냅니다.- 'true': 관리자로 실행합니다.
- 'false': 현재 사용자로 실행합니다. 지정되지 않은 경우 기본값입니다.
UNINSTALL_OPERATION_REQUIRES_ELEVATION: 제거 작업을 관리자 권한으로 실행해야 하는지 여부를 나타냅니다.- 'true': 관리자로 실행합니다.
- 'false': 현재 사용자로 실행합니다. 지정되지 않은 경우 기본값입니다.
operation-identifier:install-operation를 식별하는 고유한 문자열입니다.execute-file: 실행 파일을 실행합니다.PATH_TO_INSTALL_EXECUTE_FILE: 설치 중에 실행할 실행 파일의 경로입니다.PATH_TO_UNINSTALL_EXECUTE_FILE: 제거 전에 실행할 실행 파일의 경로입니다.
update-registry: Windows 레지스트리 항목을 만들거나 업데이트합니다.BASE_KEY: Windows 레지스트리에서 사용할 루트 키를 정의합니다. 허용되는 값:HKEY_CLASSES_ROOT,HKEY_CURRENT_CONFIG,HKEY_CURRENT_USER,HKEY_LOCAL_MACHINE,HKEY_PERFORMANCE_DATA,HKEY_USERSupdate-registry작업을 실행할 때 사용된baseKey에 따라 상위install-operation에서requiresElevation="true"를 설정합니다.HKEY_LOCAL_MACHINE또는HKEY_CURRENT_CONFIG:requiresElevation="true"를 설정합니다.HKEY_CURRENT_USER:requiresElevation="true"이 필요하지 않습니다.HKEY_CLASSES_ROOT: 머신 전체 섹션에 쓰는 경우에만requiresElevation="true"를 설정합니다. 사용자별 섹션에는 필요하지 않습니다.HKEY_USERS: 모든 사용자의 프로필을 포함합니다. 현재 사용자가 아닌 프로필(예: 다른 사용자 또는.DEFAULT)을 수정할 때는requiresElevation="true"를 설정합니다.
SUB_KEY_PATH: Windows 레지스트리 내의 특정 키 경로를 나타내며, 기본baseKey아래에 중첩됩니다.VALUE_NAME: 지정된 하위 키 내에서 수정하려는 데이터 항목의 이름을 지정합니다.REGISTRY_VALUE_TYPE: 이 속성은 레지스트리에 기록되는 값의 데이터 유형을 지정합니다. 지원되는 값은 문자열의 경우STRING, 32비트 숫자의 경우DWORD입니다.VALUE_TEXT: 레지스트리 키에 저장할 데이터입니다.
정규 표현식 사용 방법
file-path태그에서 RE2 구문 정규 표현식을 사용하여 파일 그룹에 제외 또는 파일 속성을 적용할 수 있습니다. 디렉터리 구분자에는 슬래시/를 사용하고 특수 정규 표현식 문자는 백슬래시\로 이스케이프 처리해야 합니다. 예를 들어\.를 사용하여 리터럴 점.과 일치시키거나\d를 사용하여 숫자와 일치시킵니다.다음은 몇 가지 일반적인 예입니다.
- 모든 디렉터리에서 특정 확장자 (예: .log)가 있는 모든 파일과 일치
.*\.log를 사용하여game.log또는logs/errors.log와 같이.log로 끝나는 모든 경로와 일치시킵니다.<file-path>.*\.log</file-path>
- 특정 폴더 (예: 'temp') 내의 모든 파일 및 하위 디렉터리와 일치
temp/.*를 사용하여temp/data.txt또는temp/saves/file.sav과 같이temp/로 시작하는 모든 경로와 일치시킵니다.<file-path>temp/.*</file-path>
- 특정 폴더에서 패턴과 일치하는 파일 찾기
assets/level\d\.dat를 사용하여assets/level1.dat,assets/level2.dat와 일치시키되assets/other.dat와는 일치시키지 않습니다.<file-path>assets/level\d\.dat</file-path>
- 경로에 폴더 이름이 표시되는 경우 일치
.*/cache/.*을 사용하여game/cache/file.txt또는temp/cache/other.log와 같이cache이라는 이름의 디렉터리 아래에 있는 파일을 일치시킵니다.<file-path>.*/cache/.*</file-path>
- 확장자가 여러 개인 파일과 일치 (예: .ini, .cfg, .sav)
.*\.(ini|cfg|sav)을 사용하여.ini,.cfg,.sav로 끝나는 모든 파일(예:settings.ini,config.cfg,saves/slot1.sav)과 일치시킵니다.<file-path>.*\.(ini|cfg|sav)</file-path>
- 특정 디렉터리에서 특정 확장자가 있는 파일과 일치 (예: music/ 또는 sfx/의 .ogg)
(music|sfx)/.*\.ogg를 사용하여music/또는sfx/디렉터리 아래에 있는.ogg파일과 일치시킵니다.music/level1.ogg또는sfx/explosion.ogg와 일치하지만voice/intro.ogg와는 일치하지 않습니다.<file-path>(music|sfx)/.*\.ogg</file-path>
Play 게시 구성 파일 예시
다음은
TestGame이라는 게임의play_publishing_config.xml예시입니다.<?xml version="1.0" encoding="UTF-8"?> <play-publishing-config version="1.0"> <application> <package-name>com.test.package</package-name> <version-name>1.0</version-name> </application> <game-files> <file-set> <root-folder-path>C:\Users\Username\game-files</root-folder-path> <exclusions> <file-path>mock_game\d\.exe</file-path> <!-- exclude files using a regex --> <file-path>deprecated_graphics</file-path> <!-- exclude a folder --> <file-path>.*\.log</file-path> <!-- recursively exclude all files with .log extension --> </exclusions> <file-attribute value="SKIP_UPDATE"> <file-path>settings.ini</file-path> </file-attribute> <file-attribute value="MODIFIED_ON_DEVICE"> <file-path>game_assets\d\.zip</file-path> <!-- define the path using regex --> </file-attribute> </file-set> </game-files> <launch-command> <path>launcher_test_game.exe</path> <arguments>--launch-arg</arguments> <!-- optional --> </launch-command> <lifecycle-operations> <install-operation requiresElevation="true"> <operation-identifier>elevated-execute-file</operation-identifier> <execute-file> <path>install_file.exe</path> <arguments>--arg</arguments> <!-- optional --> </execute-file> </install-operation> <install-operation requiresElevation="true"> <operation-identifier>elevated-update-registry</operation-identifier> <update-registry baseKey="HKEY_LOCAL_MACHINE"> <sub-key>SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\TestGame</sub-key> <value-name>InstallLocation</value-name> <value type="STRING">C:\Program Files\TestGame</value> </update-registry> </install-operation> <uninstall-operation requiresElevation="true"> <execute-file> <path>uninstall.exe</path> <arguments>--test-arg</arguments> <!-- optional --> </execute-file> </uninstall-operation> </lifecycle-operations> </play-publishing-config>
build-bundle명령어를 사용하여 Windows 명령줄 또는 PowerShell에서 Play 게시 도구를 실행합니다.playpublishingtool.exe build-bundle --input=PLAY_PUBLISHING_CONFIG_PATH --output=WAB_OUTPUT_PATH
이름이 같은 기존 WAB 파일을 덮어쓰려면
--force인수를 사용하세요.playpublishingtool.exe build-bundle --input=PLAY_PUBLISHING_CONFIG_PATH --output=WAB_OUTPUT_PATH --force
다음을 바꿉니다.
PLAY_PUBLISHING_CONFIG_PATH: Play 게시 구성의 경로입니다. 예:path\to\play_publishing_config.xmlWAB_OUTPUT_PATH: WAB 파일의 경로입니다. 예:path\to\output_bundle.wab
Play 게시 도구 사용 방법
현재 작업 디렉터리에
playpublishingtool.exe,play_publishing_config.xml, 게임 파일이game_files/에 있는 경우:.\ ├── game_files/ ├── play_publishing_config.xml ├── playpublishingtool.exe
같은 디렉터리에
pmi_bundle.wab을 만들려면 다음을 실행하세요.playpublishingtool.exe build-bundle --input=play_publishing_config.xml --output=pmi_bundle.wab
도구에서 번들을 빌드하는 동안 터미널에 진행률 표시줄이 표시됩니다.
Building bundle: [==== ] 40%
성공하면 다음과 비슷한 출력이 표시됩니다.
Building bundle: [===========] 100% Successfully built the managed install bundle at pmi_bundle.wab
폴더에서 WAB 파일을 찾습니다.
.\ ├── game_files/ ├── pmi_bundle.wab ├── play_publishing_config.xml ├── playpublishingtool.exe