> ## Documentation Index
> Fetch the complete documentation index at: https://devdocs.xbox.com/llms.txt
> Use this file to discover all available pages before exploring further.

# MicrosoftGame.config 元素 - ModFolder (已淘汰)

> MicrosoftGame.config 元素 - ModFolder (已淘汰)

# MicrosoftGame.config 元素 - ModFolder (已淘汰)

定義遊戲檔案的使用者模組位置。

## 父系

此元素的父系是 DesktopRegistration 元素。

## 需求

此元素為選用，不需要設定。

## 平台

此元素僅適用於 PC 裝置。

## 行為

* 屬性為 Name。
* Name 屬性的預設值為 `<PackageName>_Mods`。
* Name 屬性允許的值為位於套件根目錄的任何有效資料夾名稱。

## 備註

* 自 2022 年 3 月 GDK 起，由於套件安裝方式的變更，此元素現已淘汰。如需詳細資訊，請參閱[一般檔案安裝概觀](/zh-TW/build/core-features/common/packaging/packaging-flatfileinstall)。
* 若在您的 MicrosoftGame.config 中設定此元素，在 2022 年 3 月 Microsoft Game Development Kit (GDK) 及未來的版本中將會忽略此元素。
* 若這些元素出現在已更新為 `Game configVersion="1"` 的 MicrosoftGame.config 中，嘗試封裝您的遊戲時將會出現錯誤。錯誤會輸出 "The DesktopRegistration entries "modFolder", "enableWritesToPackageRoot", "disableRegistryWriteVirtualization" and "disableFilesystemWriteVirtualization" are deprecated in configVersion >= 1"。從 MicrosoftGame.config 移除這些元素即可解決此問題。如需 `Game configVersion="1"` 及其是否影響您遊戲的詳細資訊，請參閱 [MicrosoftGame.config 版本詳細資料](/zh-TW/reference/system/microsoftgameconfig/microsoftgameconfig-schema#MicrosoftGameConfig-VersionDetails)。

## 另請參閱

[MicrosoftGame.config 參考 - 目錄](/zh-TW/reference/system/microsoftgameconfig/elements/gc-microsoftgameconfig-toc)


## Related topics

- [MicrosoftGame.config Element - ModFolder (DEPRECATED)](/zh-CN/reference/system/microsoftgameconfig/elements/microsoftgameconfig-element-modfolder.md)
- [MicrosoftGame.config 要素 - ModFolder (非推奨)](/ja-jp/reference/system/microsoftgameconfig/elements/microsoftgameconfig-element-modfolder.md)
- [Elemento de MicrosoftGame.config - ModFolder (EN DESUSO)](/es/reference/system/microsoftgameconfig/elements/microsoftgameconfig-element-modfolder.md)
- [MicrosoftGame.config Element - DesktopRegistration](/zh-CN/reference/system/microsoftgameconfig/elements/microsoftgameconfig-element-desktopregistration.md)
- [MicrosoftGame.config Element - DisableFilesystemWriteVirtualization (DEPRECATED)](/zh-CN/reference/system/microsoftgameconfig/elements/microsoftgameconfig-element-disablefilesystemwritevirtualization.md)
