Jump to content

Welcome to the Forum!

The best place to exchange builds and ideas! Vote for the best ideas and suggestions here.

Join the Avorion Discord!

Connect with other passionate players and talk about the latest news.

DLC Avorion Into the Rift Out Now!

Now available on Steam!

[Help] Possible to hook into SectorNameGenerator?


Recommended Posts

I would like to create a mod that changes the names of the sectors displayed on the map.

Is it possible to overwrite/extend this function in scripts/lib/sectornamegenerator.lua:

function SectorNameGenerator.generateSectorName(xycountseed)

For example to return the current sector name but with a prefix like this:

return "prefix" .. name
Link to comment
Share on other sites

SectorNameGenerator.generateSectorName_orig = SectorNameGenerator.generateSectorName
function SectorNameGenerator.generateSectorName(xycountseed)
    return "Prefix " .. SectorNameGenerator.generateSectorName_orig(x, y, count, seed)
  • Thanks 1
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Create New...