We'll create a structure called FColoredTexture in C++ code to contain a texture and a modulating color:
- From Visual Studio, right-click on the Games/Chapter_02/Source/Chapter_02 folder and select Add | New item.... From the menu, select a Header file (.h) and then name the file ColoredTexture.h (not FColoredTexture).
- Under Location, make sure that you select the same folder as the other script files in the project (in my case, C:\Users\admin\Documents\Unreal Projects\Chapter_02\Source\Chapter_02) that is not the default:
- Once created, use the following code in ColoredTexture.h:
#pragma once #include "ObjectMacros.h"#include ...