> For the complete documentation index, see [llms.txt](https://utf8x.gitbook.io/paperscript-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://utf8x.gitbook.io/paperscript-docs/quick-start-guide.md).

# Quick Start Guide

This short guide will walk you through setting up PaperScript, initializing a project and building your first script.

#### Requirements

* A working install of PaperScript (see [Installing](/paperscript-docs/paperscript-cli/installing.md))
* A working copy of Skyrim SE/AE and CreationKit. Make sure to run CK before starting so the script sources get copied.
* A copy of the Papyrus Compier. This should get installed automatically with CK.
* A text exitor. We recommend Visual Studio Code with the PaperScript [VSCode Extension](/paperscript-docs/vscode-extension.md).

### Creating a New Project

Create a folder to store your project and run `paperscript init` in that folder. This will generate a `project.yaml` for you.

{% hint style="info" %}
The project initializer can detect where Skyrim is installed and set all paths automatically but it needs to run as Administrator to do this.
{% endhint %}

Afterwards, open the `project.yaml` file, fill in your project name and version and make sure all paths are set correctly.

### Write Some Code

Create a file in the `src/` directory with a `.pps` extension and write some PaperScript code. See [Syntax Reference](/paperscript-docs/syntax-reference.md) for a full reference.

Here is a minimal example:

```
script HelloWorldQuest : Quest {
  auto property PlayerREF: Auto
  auto property Gold001: MiscItem
  
  event OnInit() {
    RegisterForSingleUpdate()
  }
  
  event OnUpdate() {
    GiveGoldToActor(PlayerREF, 10)
  }
  
  def GiveGoldToActor(actor: Actor, amount: Int) {
    actor.AddItem(Gold001, amount)
  }
}
```

### Compile your Code

For the first run, it's usually a good idea to run a one-off build to make sure everything works correctly. To do so, run `paperscript build` .

When you're sure everything is configured correctly, you can run PaperScript in watch mode, where it will automatically recompile any changed files in your project. You can run PaperScript in watch mode with `paperscript watch`.

{% hint style="danger" %}
Watch mode is not implemented yet but it is coming soon.
{% endhint %}

### And that's it!

You should now have a fully functional PaperScript project. Happy coding!


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://utf8x.gitbook.io/paperscript-docs/quick-start-guide.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
