Table of Contents

Visual Studio Code Basics

Visual Studio Code (VS Code) is the bundled IDE that comes with GrindFest. This tutorial will show you the most important things you need to know to write your bot.

The Interface

VS Code Interface

There are two main areas you need to know:

  1. File Explorer (Left) - Shows all your files and folders in the project. Including your hero source code file HeroName.cs
  2. Code Editor (Center) - Where you write your bot code

Most Important Features

Auto-completion

When you type Hero. VS Code will show you all the things your hero can do. Just pick one from the list!

See Documentation

Hover your mouse over any method like Hero.Say() and VS Code will tell you what it does.

Error Detection

If you make a mistake, VS Code will show red squiggly lines under the problem. Hover over it to see what's wrong.

Go to Definition

Ctrl + Click on any method to see how it works.

Essential Shortcuts

  • Ctrl + S - Save your file (very important!) Game automatically reloads your scripts when you save.
  • Ctrl + Z - Undo if you make a mistake
  • Ctrl + / - Add or remove a comment (//)
  • Ctrl + Shift + P - Open Command Palette (find any command)

Tips

  1. Let VS Code suggest methods - don't try to remember them all
  2. If something is underlined in red, hover over it to see the problem
  3. Use // to add comments explaining what your code does
  4. Name your methods and variables clearly
  5. Enable Autosave: VS Code doesn't save automatically by default. You can turn on Auto Save by going to File > Auto Save to save your work automatically.

Learn More

Want to learn more about VS Code? Check out the official Getting Started Guide for detailed explanations of all VS Code features.

That's it! VS Code will help you write better code. Now go back to Writing Your First Bot to continue learning.