Jump to content

Water & Electricity Shutoff Mod - Options


Reconix

Recommended Posts

I'm pretty sure this has been mentioned before and I know some others have been looking for a way to disable Water and Electricity shutoff's.

The better way of implementing this would be via a mod to the main sandbox options. ( I thought )

as you know you already have the options for Instant, then time rand range from 0-x

But it would be nice to have an option in there stating Never.

I've got this working(I think) but for some reason afterwards when selecting to use one of the random's it crashes, sure it has some thing to do with those two lines.

SandboxVars.WaterShutModifier = getSandboxOptions():randomWaterShut(self.water.selected);SandboxVars.ElecShutModifier = getSandboxOptions():randomElectricityShut(self.elec.selected);


The options obviously look like this.

self.water = self:addCombo(self.splitpoint, 60, 280, 20, "WATER SHUTOFF: ", {"Instant", "none", "0-30 days", "0-2 months", "0-6 months", "0-1 year", "0-5 years"}, 3, self, nil);self.elec = self:addCombo(self.splitpoint, 60, 280, 20, "ELECTRICITY SHUTOFF: ", {"Instant", "None", "0-30 days", "0-2 months", "0-6 months", "0-1 year", "0-5 years"}, 3, self, nil);

Wasn't to sure if one should just create a new function for that with if or it was something easy as a one liner to just add to the existing.

Help would be appreciated, thanks.

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