Skip to main content

Your First Script

This is the moment it gets real. You're about to write code that runs inside a multiplayer World. Let's start with the classics โ€” print a message, then spawn something.

Create a Packageโ€‹

Scripts live inside Packages. Let's make one:

  1. Open HELIX Studio from the Launcher
  2. Go to File โ†’ New Package
  3. Name it my-first-package
  4. Choose Script Package as the type
  5. Hit Create

Your Package folder is now set up with the right structure, and a starter script file is waiting for you.

Hello HELIX!โ€‹

Open the main script file in your Package. Let's make sure everything works:

Blueprintโ€” Hello HELIX! โ€” Print a message on BeginPlayScroll to zoom ยท Drag to pan ยท Drag nodes to move
Event BeginPlayPrint StringIn String"Hello HELIX!"

In HELIX Studio, open your Package Blueprint, find Event BeginPlay, and wire it to a Print String node with the message Hello HELIX!.

Run your World with the Package loaded. You should see "Hello HELIX!" in the output log. If you do โ€” congratulations, you're a HELIX scripter now.

Spawn an Actorโ€‹

Printing is great for debugging, but let's do something visible. Here's how to spawn a prop in the World when the script loads:

Blueprintโ€” Spawn a cube actor above the originScroll to zoom ยท Drag to pan ยท Drag nodes to move
Event BeginPlaySpawn Actor from ClassClassStaticMeshActorSpawn Location(0, 0, 200)ActorSet Static MeshTargetNew MeshCube

Drag out from Event BeginPlay, add a Spawn Actor from Class node, set the class to StaticMeshActor, and configure the spawn transform. Then set its mesh to a basic cube.

Run the World again. You should see a cube hovering above the ground. It's not much to look at โ€” but it was conjured into existence by your code, in a multiplayer World, running on Unreal Engine 5.

What happened here?โ€‹

  • You created a Package to hold your scripts
  • You wrote a server-side script that runs when the Package loads
  • You spawned an Actor (a physical object in the World)

Server-side scripts run on the server and control the authoritative game state. Later you'll learn about client-side scripts for UI, effects, and input handling. But the server is where the real game logic lives.

What's next?โ€‹

You've got a World with objects and scripts. Now let's publish it so other people can see what you've built.

โœจ