Jump to content

[0.26] xsotantransformed sector generator removes all sector scripts


Rinart73

Recommended Posts

Avorion: 0.26

 

During "xsotantransformed.lua" sector generation it picks random generator script, executes it and then destroys everything so it looks like it was an actual sector before. The problem is this part of the code (line 176-178):

for _, script in pairs(sector:getScripts()) do
    sector:removeScript(script)
end

 

It removes ALL scripts, even the ones that shouldn't be removed like relationchanges, spawnpersecutors, boardingutility, warzonecheck and radiochatter+ modded scripts that should be persistent.

 

My suggestion is replacing that code with this one:

 

for _, script in pairs(sector:getScripts()) do
    sector:removeScript(script)
end
-- restore basic scripts
include("data/scripts/sector/init.lua")

 

This way sector will get back it's persistent scripts.

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...