After finding out that there's no easy way to tell Prison Architect that an object requires a water connection to work, I decided to try and simulate the requirement with scripting. Assuming I can already tell whether or not my object has a working water connection (should be doable with GetNearbyObjects) is there an easy way to disable my object and prevent prisoners from using it, then re-enable it later, using lua? I tried fiddling with the On property but it seemed to have no effect, presumably because my object is not electrical.
I can probably do it in a rather round-about fashion by defining a brand new object that represents my base object in a 'disabled' state, then use scripting to swap between them automatically with Spawn and Delete, but that seems like overkill.
Can I make an object temporarily unusable?
Moderator: NBJeff
-
- level2
- Posts: 105
- Joined: Sat Apr 26, 2014 11:47 pm
Re: Can I make an object temporarily unusable?
You can spawn a new object and attach it to the slot used.
There is no other way I'm having the same problem.
There is no other way I'm having the same problem.
Who is online
Users browsing this forum: No registered users and 4 guests