# Why should i use visual studio for writing c++ code? cant i compile from any other c++ compiler's and include it in unreal? why is this close coupling between unreal and visual studio?

**URL:** <https://forums.unrealengine.com/t/why-should-i-use-visual-studio-for-writing-c-code-cant-i-compile-from-any-other-c-compilers-and-include-it-in-unreal-why-is-this-close-coupling-between-unreal-and-visual-studio/451112>\
**Category:** C++\
**Tags:** engine-compile, unreal-engine, UE4, question, CPP, compile-editor\
**Created:** [June 23, 2019, 4:28am UTC](https://forums.unrealengine.com/t/why-should-i-use-visual-studio-for-writing-c-code-cant-i-compile-from-any-other-c-compilers-and-include-it-in-unreal-why-is-this-close-coupling-between-unreal-and-visual-studio/451112 "2019-06-23T04:28:21Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![MalleshKarre](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@MalleshKarre](https://forums.unrealengine.com/u/MalleshKarre)\
**Post date:** [June 23, 2019, 4:28am UTC](https://forums.unrealengine.com/t/why-should-i-use-visual-studio-for-writing-c-code-cant-i-compile-from-any-other-c-compilers-and-include-it-in-unreal-why-is-this-close-coupling-between-unreal-and-visual-studio/451112/1 "2019-06-23T04:28:21Z")

</div>

is there any other way to compile and include c++ files, other than using visual studio.

---

<div class="post-metadata">

**Author:** ![NorlinGames](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/norlingames/32/495614_2.png) [@NorlinGames](https://forums.unrealengine.com/u/NorlinGames)\
**Post date:** [June 23, 2019, 1:46pm UTC](https://forums.unrealengine.com/t/why-should-i-use-visual-studio-for-writing-c-code-cant-i-compile-from-any-other-c-compilers-and-include-it-in-unreal-why-is-this-close-coupling-between-unreal-and-visual-studio/451112/2 "2019-06-23T13:46:28Z")

</div>

You can use the UBT (Unreal Build Tool) directly with no Visual Studio usage.

Here are some links:

- [https://answers.unrealengine.com/questions/102308/building-unreal-projects-from-command-line.html](https://answers.unrealengine.com/questions/102308/building-unreal-projects-from-command-line.html)
- [https://wiki.unrealengine.com/How\_to\_package\_your\_game\_with\_commands](https://wiki.unrealengine.com/How_to_package_your_game_with_commands)
- [https://docs.unrealengine.com/en-US/Programming/BuildTools/UnrealBuildTool/index.html](https://docs.unrealengine.com/en-US/Programming/BuildTools/UnrealBuildTool/index.html)
- [Understanding Unreal Build Tool – Eric Lemes' Blog](https://ericlemes.com/2018/11/23/understanding-unreal-build-tool)

There is no decent documentation for this, so it’s mostly about googling or readin the UBT code to find the requred arguments and options.

Personally I’m working with UE4 projects with Sublime Text editor and my own build script (a simple wrapper for UBT commands).

[The script gist](https://gist.github.com/norlin/6805e16674ff3edea047068e607312bb) – it’s not a production ready script, it’s mostly made for myself and have some hardcoded stuff.  
Also it heavily depends on which exact versin of UE4 you’re using (the UBT arguments may change).

UPD: still, it requires the Visual Studio to be installed, since it’s using the compiler and other tools.

---

<div class="post-metadata">

**Author:** ![DerickGreen3](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@DerickGreen3](https://forums.unrealengine.com/u/DerickGreen3)\
**Post date:** [April 30, 2021, 7:19pm UTC](https://forums.unrealengine.com/t/why-should-i-use-visual-studio-for-writing-c-code-cant-i-compile-from-any-other-c-compilers-and-include-it-in-unreal-why-is-this-close-coupling-between-unreal-and-visual-studio/451112/4 "2021-04-30T19:19:52Z")

</div>

Help pls!!

---

<div class="post-metadata">

**Author:** ![NorlinGames](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/norlingames/32/495614_2.png) [@NorlinGames](https://forums.unrealengine.com/u/NorlinGames)\
**Post date:** [May 1, 2021, 6:56pm UTC](https://forums.unrealengine.com/t/why-should-i-use-visual-studio-for-writing-c-code-cant-i-compile-from-any-other-c-compilers-and-include-it-in-unreal-why-is-this-close-coupling-between-unreal-and-visual-studio/451112/6 "2021-05-01T18:56:22Z")

</div>

+1, a great new option! at the time of my answer there was no Rider for UE4 🙂

---

<div class="post-metadata">

**Author:** ![LivelyGeek](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/livelygeek/32/465099_2.png) [@LivelyGeek](https://forums.unrealengine.com/u/LivelyGeek)\
**Post date:** [March 24, 2022, 4:00pm UTC](https://forums.unrealengine.com/t/why-should-i-use-visual-studio-for-writing-c-code-cant-i-compile-from-any-other-c-compilers-and-include-it-in-unreal-why-is-this-close-coupling-between-unreal-and-visual-studio/451112/8 "2022-03-24T16:00:45Z")

</div>

Here is a useful video on showing how to use any other editor (in this case Sublime), how projects are structured, and how to use Unreal Build Tool directly.

[![](https://d3kjluh73b9h9o.cloudfront.net/original/4X/f/8/8/f885e3bef29474c9a807c1105191a7b1a0bae0ec.jpeg "Unreal Engine C++ Project Setup, From Scratch") ](https://www.youtube.com/watch?v=94FvzO1HVzY)
