Skip to content

Commit f3f5c57

Browse files
authored
Merge pull request #13649 from TylerMSFT/buildoptions
Buildoptions
2 parents 765f294 + c08580a commit f3f5c57

File tree

3 files changed

+38
-13
lines changed

3 files changed

+38
-13
lines changed

gamedev/unreal/get-started/vs-tools-unreal-add-class-module-plugin.md

Lines changed: 38 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,14 @@
11
---
22
title: "Add Unreal Engine classes, modules, and plugins in Visual Studio"
33
description: "Learn how to add Unreal Engine classes, modules, and plugins to your Unreal Engine project from within Visual Studio"
4-
ms.date: 07/25/2024
4+
ms.date: 03/17/2025
55
ms.topic: how-to
66
ms.service: visual-studio
77
ms.subservice: unreal-engine-tools
88
author: TylerMSFT
99
ms.author: TWhitney
1010
manager: Coxford
11+
1112
#customer intent: As a C++ game developer using Unreal Engine and Visual Studio, I want to add classes, modules, and plugins to my Unreal Engine project from within Visual Studio so that I can stay in my development environment and not have to switch between the Unreal Engine Editor and Visual Studio.
1213
---
1314

@@ -23,7 +24,7 @@ In this article, learn how to use Visual Studio Tools for Unreal Engine to:
2324

2425
The following must be installed:
2526

26-
- Visual Studio version 17.11 (17.11 preview versions ok) or later.
27+
- Visual Studio version 17.11 or later.
2728
- Unreal Engine version 5 or later.
2829
- Visual Studio Tools for Unreal Engine. See [Install Visual Studio Tools for Unreal Engine](vs-tools-unreal-install.md) for installation instructions.
2930
- Complete the [Quickstart: Visual Studio Tools for Unreal Engine](vs-tools-unreal-quickstart.md) to download and build the Lyra game and configure it to use Visual Studio Tools for Unreal Engine.
@@ -49,26 +50,38 @@ To add an Unreal Engine module in Visual Studio, follow these steps after comple
4950
Modules can only be created in the **Source** folder or as a module of a plugin inside the **Plugins** folder.\
5051
The **Build** path shows where the `Build.cs` file is created. The `Build.cs` file contains configuration information for the module.
5152

53+
## Build a single Unreal Engine module
54+
55+
After adding the module, build it to make it available in the Unreal Engine Editor. Rather than build the entire project, you can build just the module.
56+
57+
In **Solution Explorer**, right-click on the module folder and select **Build**. This builds the plugin and makes it available in the Unreal Engine Editor.
58+
59+
:::image type="complex" source="../media/vs-build-module-menu.png" alt-text="A screenshot of the menu to build the module.":::
60+
The menu options after right-clicking the module folder MyModule are visible. The entry Build this Unreal Engine module is highlighted.
61+
:::image-end:::
62+
63+
Build output is displayed in the **Output** window. If the build is successful, the module is available in the Unreal Engine Editor. If the build fails, the **Output** window displays the error messages.
64+
5265
## Add Unreal Engine classes in Visual Studio
5366

5467
You can now add Unreal Engine classes to your Unreal Engine project from within Visual Studio. You no longer have to switch between the Unreal Editor and Visual Studio to add a class, or need to synchronize the Visual Studio solution with your Unreal Engine project file afterwards.
5568

5669
To add an Unreal Engine class in Visual Studio, follow these steps after completing [Quickstart: Visual Studio Tools for Unreal Engine](vs-tools-unreal-quickstart.md) to download and build the Lyra game. The steps assume that you have the `LyraStarterGame.sln` solution open in Visual Studio:
5770

58-
1. In **Solution Explorer**, choose a folder where you want the new class to go. In the LyraStarterGame project, you could add a new class to the **LyraStarterGame** > **Source** folder, for example.
59-
1. Right-click the folder and choose **Add** > **Unreal Engine item...** to open the **Add New Item** dialog:
71+
1. In **Solution Explorer**, select a folder where you want the new class to go. In the LyraStarterGame project, you could add a new class to the **LyraStarterGame** > **Source** folder, for example.
72+
1. Right-click the folder and select **Add** > **Unreal Engine item...** to open the **Add New Item** dialog:
6073
:::image type="complex" source="../media/vs-add-new-unreal-engine-item-dialog-class.png" alt-text="A screenshot of the Add New Item dialog, with Unreal Engine Common Classes selected.":::
6174
It has options for adding an Unreal Engine Common Classes (which is selected), Empty Unreal Engine Module, and Unreal Engine Plugins.
6275
:::image-end:::
63-
1. Choose **Unreal Engine Common Classes** and then choose **Add** to open the **Add Unreal Engine Class** dialog:
76+
1. Select **Unreal Engine Common Classes** and then select **Add** to open the **Add Unreal Engine Class** dialog:
6477
:::image type="complex" source="../media/vs-add-unreal-engine-class-dialog.png" alt-text="A screenshot of the Add New Unreal Engine class dialog.":::
6578
Options for selecting a base such as Actor, Character, and so on, are visible. There's a field for the class name and a dropdown for the module to add the class to. The paths to the header file and source file are listed. A checkbox is selected to refresh IntelliSense information using Unreal Editor tools.
6679
:::image-end:::
67-
1. Choose a **Class name**. Visual Studio warns you if the name conflicts with an existing class or file.
68-
1. Choose a **Base class**. Selecting a base class ensures that the right headers and macros are included for that class type.
69-
1. Choose a module to add to your class to using the **Select a module to add the class** dropdown. The module name is the name of the folder that contains the module.
80+
1. Select a **Class name**. Visual Studio warns you if the name conflicts with an existing class or file.
81+
1. Select a **Base class**. Selecting a base class ensures that the right headers and macros are included for that class type.
82+
1. Select a module to add to your class using the **Select a module to add the class** dropdown. The module name is the name of the folder that contains the module.
7083
1. Select the **Refresh IntelliSense information using Unreal Editor tools** checkbox to choose whether Visual Studio uses Unreal Editor tools to update the IntelliSense information. Choose this to cause the Unreal Build Tool to regenerate the Visual Studio solution file.
71-
1. Choose **OK** to generate the header and source files for the new class and add them to the Visual Studio solution file. This results in a prompt to reload the project. Choose **Reload** to reload the project.
84+
1. Select **OK** to generate the header and source files for the new class and add them to the Visual Studio solution file. Select **Reload** in the prompt that appears to reload the project.
7285

7386
## Add Unreal Engine plugins in Visual Studio
7487

@@ -77,19 +90,31 @@ You can now add Unreal Engine plugins to your Unreal Engine project from within
7790
To add an Unreal Engine plugin in Visual Studio, follow these steps after completing [Quickstart: Visual Studio Tools for Unreal Engine](vs-tools-unreal-quickstart.md) to download and build the Lyra game. The steps assume that you have the `LyraStarterGame.sln` solution open in Visual Studio:
7891

7992
1. In **Solution Explorer**, choose a folder where you want the new plugin to go. In the LyraStarterGame project, you could add a new plugin to the **LyraStarterGame** > **Source** folder, for example.
80-
1. Right-click the folder and choose **Add** > **Unreal Engine item...** to open the **Add New Item** dialog:
93+
1. Right-click the folder and select **Add** > **Unreal Engine item...** to open the **Add New Item** dialog:
8194
:::image type="complex" source="../media/vs-add-new-unreal-engine-item-dialog-plugin.png" alt-text="A screenshot of the Add New Item dialog, with Unreal Engine Plugins selected.":::
8295
It has options for adding an Unreal Engine Common Classes, Empty Unreal Engine Module, and Unreal Engine Plugins (which is selected).
8396
:::image-end:::
84-
1. Choose **Unreal Engine Plugins** and then choose **Add** to open the **Add Unreal Engine Plugin** dialog:
97+
1. Select **Unreal Engine Plugins** and then select **Add** to open the **Add Unreal Engine Plugin** dialog:
8598
:::image type="complex" source="../media/vs-add-unreal-engine-plugin-dialog.png" alt-text="A screenshot of the Add New Unreal Engine plugin dialog.":::
8699
There's a list of Plugin types (Advanced is selected), and fields for the plugin name, path, author, description, and URL. There's an Is plugin in beta checkbox (unchecked) and a Refresh IntelliSense information using Unreal Editor Tools checkbox (checked).
87100
:::image-end:::
88-
1. Choose the type of your plugin from the **Plugin type** list.
101+
1. Select the type of your plugin from the **Plugin type** list.
89102
1. Provide the **Plugin name**, **Plugin author**, **Plugin Description**, and **Plugin url**.
90103
1. Check the **Is plugin in beta** box as needed.
91104
1. Select the **Refresh IntelliSense information using Unreal Editor tools** checkbox to choose whether Visual Studio uses the Unreal Editor tools to update the IntelliSense information. This causes the Unreal Build Tool to regenerate the Visual Studio solution file.
92-
1. Choose **Add** to generate the plugin header and source files for the new plugin and add them to the Visual Studio solution file. This results in a prompt to reload the project. Choose **Reload** to reload the project.
105+
1. Select **Add** to create the plugin header and source files for the new plugin and add them to the Visual Studio solution file. This results in a prompt to reload the project. Choose **Reload** to reload the project.
106+
107+
## Build a single Unreal Engine plugin
108+
109+
After adding the plugin, build it to make it available in the Unreal Engine Editor. Rather than build the entire project, you can build just the plugin.
110+
111+
In **Solution Explorer**, right-click on the plugin folder and choose **Build this Unreal Engine plugin**. This builds the plugin and makes it available in the Unreal Engine Editor.
112+
113+
:::image type="complex" source="../media/vs-build-plugin-menu.png" alt-text="A screenshot of the menu to build the plugin.":::
114+
The menu options after right-clicking the plugin folder MyPlugin are visible. The entry Build this Unreal Engine plugin is highlighted.
115+
:::image-end:::
116+
117+
If the build is successful, the plugin is available in the Unreal Engine Editor. If the build fails, the **Output** window displays the error messages.
93118

94119
## Related content
95120

243 KB
Loading
207 KB
Loading

0 commit comments

Comments
 (0)