> For the complete documentation index, see [llms.txt](https://azuriohs-organization.gitbook.io/r-type/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://azuriohs-organization.gitbook.io/r-type/how-to-create-your-own-game/step-3-create-window-entity.md).

# Step 3 - Create window entity

Now that we have all the necessary components, we can create our first entity.

For example, one of the most important entities in a graphical project is the window.\\

**1. Create the Entity**

To create a new entity (here, a window entity):

```cpp
Engine::Entity windowEntity = GameEngine.CreateEntity("windowTest");
```

**2. Create the Window Component**

Next, create the window component through the render system:

```cpp
std::shared_ptr<Subsystems::Render::IWindow> windowComponent = render->CreateWindow();
```

**3. Initialize the Component**

Now, set up and initialize your component — for example, the window name, height, and width:

```cpp
windowComponent->SetWindowName("Test");
windowComponent->SetHeight(600);
windowComponent->SetWidth(900);
windowComponent->InitWindow();
```

**4. Attach the Component to the Entity**

Finally, attach the component to your entity using the component pool:

```cpp
windowPool.Add(windowEntity.GetId(), windowComponent);
```
