如果您主要在 Windows 上进行开发,并使用 Microsoft Visual Studio 来编写 C 或 C++ 代码,则 AGDE 是您的理想之选。如果您使用不同的工具编写 C 或 C++ 代码,请使用 Android Studio 针对 Android 开发应用。
AGDE 是 Android Game Development Kit 的一部分。Android Game Development Kit 包含许多支持以 Android 为平台打造出色游戏的库和工具。Android Game Development Kit 中的库与 AGDE 项目兼容。Android 图形检查器等工具可帮助您调整游戏,以实现最佳性能。
在 Visual Studio 中以 Android 为目标平台
AGDE 将 Android 作为平台目标添加到 Visual Studio 中。这让现有的多平台 Visual Studio 游戏项目能够快速集成 Android 这一新添加的平台。Visual Studio IntelliSense 功能与 AGDE 兼容。它支持当前所有的 Android CPU 架构:32 位和 64 位 ARM 和 Intel。
[[["易于理解","easyToUnderstand","thumb-up"],["解决了我的问题","solvedMyProblem","thumb-up"],["其他","otherUp","thumb-up"]],[["没有我需要的信息","missingTheInformationINeed","thumb-down"],["太复杂/步骤太多","tooComplicatedTooManySteps","thumb-down"],["内容需要更新","outOfDate","thumb-down"],["翻译问题","translationIssue","thumb-down"],["示例/代码问题","samplesCodeIssue","thumb-down"],["其他","otherDown","thumb-down"]],["最后更新时间 (UTC):2025-07-27。"],[],[],null,["# Develop your game in Microsoft Visual Studio\n\n[Android Game Development Extension](/games/agde) (AGDE) for Visual Studio\nallows you to target Android as a platform for your Visual Studio\nprojects. AGDE supports a full range of development activities: project\nmanagement, building, debugging, and profiling.\n\nAGDE is best suited to you if you're developing primarily on Windows and use\nMicrosoft Visual Studio to write C or C++ code. If you're writing C or C++ code\nusing different tools, use Android Studio to develop for Android.\n\nAGDE is part of the Android Game Development Kit. The Android Game Development\nKit includes libraries and tools that support making great games on Android. The\nlibraries in the Android Game Development Kit are compatible with AGDE projects.\nTools like the Android Graphics Inspector can help you tune your game for\noptimal performance.\n\nTarget Android in Visual Studio\n-------------------------------\n\nAGDE adds Android as a platform target to Visual Studio. This enables existing\nmulti-platform Visual Studio game projects to quickly integrate Android as a new\nplatform. Visual Studio IntelliSense features are compatible with AGDE. All\ncurrent Android CPU architectures are supported: both ARM and Intel in 32-bit\nand 64-bit.\n\nBuild in Visual Studio\n----------------------\n\nAGDE integrates with MSBuild for compiling and linking C++ code for Android. The\nAndroid NDK is used to supply the compiler and build toolchain. For developers\nthat have specific dependencies, AGDE is compatible with multiple versions of\nthe NDK. Project build settings are configured using the standard Visual Studio\nproperty system. AGDE is compatible with Incredibuild, enabling developers to\nuse existing distributed build infrastructure to speed up build times when\ncompiling for Android.\n\nDebug in Visual Studio\n----------------------\n\nAGDE supports deploying to, running on, and debugging with both an emulator and\na physical device. The debugger can also be attached to an already-running\nprocess. AGDE interfaces with LLDB for debugging support. With AGDE, debug\nsessions run inside Visual Studio, using its standard interface for breakpoints,\ntracing and variable inspection. Additional features include Memory and Register\nviews, and disassembly of native code. LLDB shell functionality is available\nthrough the Visual Studio Command Window. Unreal Engine developers using 4.26.1\nand later can use AGDE to debug on Android.\n\nProfile from Visual Studio\n--------------------------\n\nAGDE integrates with a standalone version of the Android Studio Profiler. This\nprofiler can be launched from Visual Studio and attached to a running game\nsession. The Android Studio Profiler displays real time usage statistics for\nCPU, memory, network, and energy.\n\nRequirements\n------------\n\nAGDE requires an Intel or AMD PC running Microsoft Windows with the following software installed:\n\n- .NET Core SDK 2.2\n- Android Studio 3.5 or later\n- Visual Studio 2017 (15.4.0 or later) or Visual Studio 2019 (16.0.0 or later)\n\nMore information\n----------------\n\n(Links to download)\n(Links to AGDE guide)"]]