Section 2 - 17. Hello, World!

Okay so im a beginner at this, and need some help with the code in this section. So i’ve written down the code correct. When i try to launch my code it opens up virtual studio. That did not happen in the video, so im guessing something is wrong. Any ideas?

  • Tormod

Hi Tormod,

Welcome to our community! :slight_smile:

In which course are you?

What you describe, sounds correct. When you double click on your script in Unity, a script editor should launch. It is usually Visual Studio unless you selected another script editor in Edit > Preferences > External Tools.

It is not wrong by any means to use Visual Studio but if you prefer Visual Studio Code, make sure it is selected in the External Tools.

Did this help?

The thing is, i haven’t started using unity yet. Im currently trying to get familiar with the basic, so the Codes im writing is in VS code. But when i execute the code it opens VS. Not sure if that explains it better? The course im doing is called Unreal Engine C++ developer

That’s good to know. This is the Unity subforum, and I know Unity only, so I cannot help you with this problem. I’m moving your thread to the Unreal subforum. :slight_smile:

You are most likely typing “triplex.cpp” into the command prompt which is the same as double clicking it in File Explorer, it’ll just open the file in the default application for that file extension.

cl triplex.cpp

This will invoke the compiler (cl) and compile the file triplex.cpp and will output an executable of the same name i.e. triplex.exe. You would then type that to run the program

triplex.exe

The .exe can be omitted and it’ll mean the same thing (cl is also an executable i.e. cl.exe).

1 Like

Not sure what happened, but i can confirm that i have gotten past the problem. Thank you everyone for your help.

  • Tormod
1 Like

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.

Privacy & Terms