ServersYour serverFor creatorsForumFAQDocumentationSecurity
Download the launcher
  1. Trilogy Hub
  2. Your own server

Your own GTA San Andreas DE server

You start a Trilogy Hub server from the launcher. The world starts empty, and you write what happens in it in Lua.

How do I set up a server?

You start and stop the server from the launcher. Add your Lua resources, start the server and publish it on the list so players can join.

  1. Install the Trilogy Hub launcher and sign in.
  2. Create a new server in the servers tab.
  3. Open the server files and put your resources in the resources folder.
  4. Start the server. In its console you turn resources on and off with the start, stop and restart commands.
  5. Publish the server on the list.

What does a resource look like?

A resource is a folder in resources/ with a meta.xml file, just like in MTA:SA. server scripts stay on the server, client scripts are sent to players, and shared scripts run on both sides.

-- Car on command: RGB colour, headlights, custom plate
addCommandHandler("auto", function(player)
    local x, y, z = getElementPosition(player)
    local car = createVehicle(536, x + 3, y, z)  -- Blade
    setVehicleColor(car, 255, 122, 34, 20, 20, 20)
    setVehicleHeadLightColor(car, 255, 180, 90)
    setVehiclePlateText(car, "GROVE 4L")
    warpPedIntoVehicle(player, car)
end)

-- Sunset over Los Santos
setTime(19, 30)
setWeatherBlended(1)

-- Weapon wheel slow motion from Definitive Edition
setSlowMotionEnabled(true, "wheel")
  • Players download client files once, and on later visits only the files that changed.
  • Client scripts and HTML/JS/CSS page files can be stored on the player's machine encrypted (protected="true").
  • Everything a resource creates disappears when you stop it.

How does a server get on the list?

A published server appears on the list in every player's launcher. When you shut it down, it disappears from the list of online servers on its own.

Questions

Will my MTA:SA scripts work?

Partly. The Trilogy Hub API uses a similar model: resources with meta.xml, events, exports and the same names for many functions. A ready-made resource needs reviewing, because not every function has a counterpart.

How do I set up my own server?

You start the server from the launcher. Put your Lua resources in the resources folder, start the server and publish it on the list so others can join.

Can I play with friends?

Yes. You add friends in the launcher, see who is online and chat with them. Pick a server from the list and join with the PLAY button.

Grove Street is waiting.