YouDoNotKnowMyName Posted January 25, 2021 Share Posted January 25, 2021 Good evening everybody! Is there any way to make a script enable or disable every object ref of a layer? I have alreaedy searched the "scripting" section of the CK wiki but have not found anything like "SetLayerEnableState" ...And if I make my script have an object reference as a property, my layers don't show up in the list where you can pick the object reference to fill the property with ... So, I am a bit confused on how to do this ... Link to comment Share on other sites More sharing options...
Deleted77601483User Posted January 26, 2021 Share Posted January 26, 2021 If you want to disable/enable multiple objects at the same time, you should use Enable Markers as a sort of layering system. Basically it allows you to bind multiple objects to a single parent and when that parent is enabled/disabled the children will also be enabled/disabled. The children can be attached to the enable marker from the reference window under "Enable Parent" or "Enable Marker" or something like that. There you need to pick a reference to use as the parent. This reference can be basically any reference but the best way to go would be to create a specific object (like an XMarker or the enable parent placeholder object) that is hidden. Then when you enable/disable this specific reference, all references that have linked to this reference will follow the enable/disable state (or be the opposite state depending on how you configure it). The CK layers are for developing the mod only if I remember correctly. Link to comment Share on other sites More sharing options...
YouDoNotKnowMyName Posted January 26, 2021 Author Share Posted January 26, 2021 If you want to disable/enable multiple objects at the same time, you should use Enable Markers as a sort of layering system. Basically it allows you to bind multiple objects to a single parent and when that parent is enabled/disabled the children will also be enabled/disabled. The children can be attached to the enable marker from the reference window under "Enable Parent" or "Enable Marker" or something like that. There you need to pick a reference to use as the parent. This reference can be basically any reference but the best way to go would be to create a specific object (like an XMarker or the enable parent placeholder object) that is hidden. Then when you enable/disable this specific reference, all references that have linked to this reference will follow the enable/disable state (or be the opposite state depending on how you configure it). The CK layers are for developing the mod only if I remember correctly.I know about working with enable markers / X-Markers.I just thought I could use the "layers" ... So I will just use the "select all loaded references in the selected layer" thing and the "batch action window" to give all the objects on the layer an "enable parent" (enable marker). Ok, I guess ... Link to comment Share on other sites More sharing options...
F4llfield Posted November 15, 2022 Share Posted November 15, 2022 If you want to disable/enable multiple objects at the same time, you should use Enable Markers as a sort of layering system. Basically it allows you to bind multiple objects to a single parent and when that parent is enabled/disabled the children will also be enabled/disabled. The children can be attached to the enable marker from the reference window under "Enable Parent" or "Enable Marker" or something like that. There you need to pick a reference to use as the parent. This reference can be basically any reference but the best way to go would be to create a specific object (like an XMarker or the enable parent placeholder object) that is hidden. Then when you enable/disable this specific reference, all references that have linked to this reference will follow the enable/disable state (or be the opposite state depending on how you configure it). The CK layers are for developing the mod only if I remember correctly.I know about working with enable markers / X-Markers.I just thought I could use the "layers" ... So I will just use the "select all loaded references in the selected layer" thing and the "batch action window" to give all the objects on the layer an "enable parent" (enable marker). Ok, I guess ... Thanks to both of you. It was very useful to me! Link to comment Share on other sites More sharing options...
Recommended Posts