Skip to content

Start

Your first script

From an empty project list to a running resource on your server in six steps. The generation itself takes a minute or two.

Before you start

  • A SwisserAI account with some credits. The speed cameras below cost under a hundred to generate.
  • Access to your FiveM server files, its server.cfg and, for scripts that store data, its database.
  • The framework your server runs, for example QBCore.

The six steps

We build speed cameras for a QBCore server: cameras in a config file, fines from the bank account, a message to the player.

  1. 1

    Start a new project

    In the sidebar open Coding, then My projects, and press New project.

    1. 1. New project: starts the setup
    2. 2. All, Working, Ready, Drafts: filter by status
    3. 3. Project card: opens the project
  2. 2

    Pick your framework

    Keep Generate a script and choose the framework your server runs. It decides which functions the code uses.

    1. 1. QBCore: the framework your server runs
  3. 3

    Pick a starting point

    Choose a template, here Speed Cameras. It fills in a prompt written for your framework. For your own idea, choose Describe it yourself.

    1. 1. Categories: narrow the list
    2. 2. Speed Cameras: fills in a prompt for QBCore
    3. 3. Describe it yourself: start from an empty prompt
  4. 4

    Check the name and the prompt

    The name becomes the resource name. Read the prompt and add what matters on your server: item names, jobs, prices, which phone or notification script you use.

    1. 1. Project name: also the resource name
    2. 2. Generation prompt: edit it before you generate
  5. 5

    Create and generate

    Press Create and generate. The project opens and the assistant starts at once. You watch it read, plan and write each file. This usually takes one to two minutes.

    A run in progress: each numbered step shows what the assistant reads, searches and writes.

    When it is done, the chat shows a summary, the files it made and the credits the run cost.

  6. 6

    Export and install

    Press Export to download the zip. On your server, create a folder in resources with the project name, unzip the files into it and add it to server.cfg:

    ensure speed-cameras

    If the project has an sql folder, import that file into your database first. Then start the server and test. The full guide is in Installing on your server.

Good to know

Keep the chat open while you test. When something is off, paste the error or describe what you saw, and the assistant fixes it.

Where to go from here

Sped up four times. After the request, each iteration shows what the assistant reads, searches and edits. The run ends with a summary, the changed files and the credits it cost.