HeyYou Posted April 15, 2023 Share Posted April 15, 2023 Would it be possible to have conduit only visible in build mode?? Is there a keyword for that, or something interesting like that? Link to comment Share on other sites More sharing options...
DieFeM Posted April 15, 2023 Share Posted April 15, 2023 Usually for making an object only visible in workshop mode the event OnWorkshopMode is used to Enable/Disable it. But I'm afraid that disabling a conduit could cause unexpected issues to the power grid so, if that is the case, you could make use of destruction stages, in which the conduit uses a transparent material swap, or a transparent model if the original one doesn't allow for material swaps. So when you enter in workshop mode it uses a destruction stage that makes it visible, and when exits from workshop mode it changes the destruction stage to use the invisible one.To change destruction stages you can make use of DamageObject and ClearDestruction. To setup the destruction stages you need to use "Edit Destruction Data" in the conduit. If you need examples you can check cars or flora for destruction stages. Link to comment Share on other sites More sharing options...
HeyYou Posted April 16, 2023 Author Share Posted April 16, 2023 Hhhmmm.... Now THAT is interesting. Gonna have to do some diggin'. Would that cause issues when entering/leaving workshop mode, if there is a LOT of conduit?? Link to comment Share on other sites More sharing options...
DieFeM Posted April 16, 2023 Share Posted April 16, 2023 I don't know, maybe. "Build your own pool" uses OnMenuOpenCloseEvent though, along with RegisterForMenuOpenCloseEvent("WorkshopMenu") at OnWorkshopObjectPlaced, and UnregisterForMenuOpenCloseEvent("WorkshopMenu") in the OnWorkshopObjectDestroyed, if the above mentioned method doesn't work as good as you would like, you might want to try with this other event. It seemed to replace the objects marker/water instantly. Link to comment Share on other sites More sharing options...
HeyYou Posted April 16, 2023 Author Share Posted April 16, 2023 I don't know, maybe. "Build your own pool" uses OnMenuOpenCloseEvent though, along with RegisterForMenuOpenCloseEvent("WorkshopMenu") at OnWorkshopObjectPlaced, and UnregisterForMenuOpenCloseEvent("WorkshopMenu") in the OnWorkshopObjectDestroyed, if the above mentioned method doesn't work as good as you would like, you might want to try with this other event. It seemed to replace the objects marker/water instantly.That's a good point. I have used that mod, and place a fair bit of water...... Convenient that it uses 'markers' with collision for placement. :) Link to comment Share on other sites More sharing options...
Recommended Posts