Hi all,
I have searched far and wide, plugins, the rust assembly, and oxide. I can't seem to find a way to loop through and record the positions of monuments or radtowns.
Any guidance would be appreciated!
Thanks,
Looping through static prefabs
Discussion in 'Rust Development' started by Calytic, May 29, 2015.
-
Calytic Community Admin Community Mod
-
Calytic Community Admin Community Mod
Bumping.
[DOUBLEPOST=1433899873,1433874767][/DOUBLEPOST]Do I have to do physics overlapsphere on the entire map and check for layer masks? I am not familiar with Unity.
What are the Layer Masks for a radtown/monument? The prefab ids appear to be different. -
Not sure how much flaws this has but you could try doing this:
Code:void OnServerInitialized() { var gameobjects = UnityEngine.Object.FindObjectsOfType<GameObject>(); Puts($"Found {gameobjects.Length} gameobjects on the map."); foreach (var go in gameobjects) if (go.name.ToLower().Contains("monument")) Puts($"Found monument {go.name} at {go.transform.position}"); }