public static SgtSingularity Create(int layer, Transform parent, Vector3 localPosition, Quaternion localRotation, Vector3 localScale) { var gameObject = SgtHelper.CreateGameObject("Singularity", layer, parent, localPosition, localRotation, localScale); var singularity = gameObject.AddComponent <SgtSingularity>(); return(singularity); }
public static SgtCorona Create(int layer, Transform parent, Vector3 localPosition, Quaternion localRotation, Vector3 localScale) { var gameObject = SgtHelper.CreateGameObject("Corona", layer, parent, localPosition, localRotation, localScale); var corona = gameObject.AddComponent <SgtCorona>(); return(corona); }
public static SgtStarfieldBox Create(int layer, Transform parent, Vector3 localPosition, Quaternion localRotation, Vector3 localScale) { var gameObject = SgtHelper.CreateGameObject("Starfield Box", layer, parent, localPosition, localRotation, localScale); var starfieldBox = gameObject.AddComponent <SgtStarfieldBox>(); return(starfieldBox); }
public static SgtAtmosphere Create(int layer, Transform parent, Vector3 localPosition, Quaternion localRotation, Vector3 localScale) { var gameObject = SgtHelper.CreateGameObject("Atmosphere", layer, parent, localPosition, localRotation, localScale); var atmosphere = gameObject.AddComponent <SgtAtmosphere>(); return(atmosphere); }
public static SgtBeltSimple Create(int layer, Transform parent, Vector3 localPosition, Quaternion localRotation, Vector3 localScale) { var gameObject = SgtHelper.CreateGameObject("Belt Simple", layer, parent, localPosition, localRotation, localScale); var simpleBelt = gameObject.AddComponent <SgtBeltSimple>(); return(simpleBelt); }
public static SgtAccretion Create(int layer, Transform parent, Vector3 localPosition, Quaternion localRotation, Vector3 localScale) { var gameObject = SgtHelper.CreateGameObject("Accretion", layer, parent, localPosition, localRotation, localScale); var accretion = gameObject.AddComponent <SgtAccretion>(); return(accretion); }
public static SgtLightningSpawner Create(int layer, Transform parent, Vector3 localPosition, Quaternion localRotation, Vector3 localScale) { var gameObject = SgtHelper.CreateGameObject("Lightning Spawner", layer, parent, localPosition, localRotation, localScale); var lightningSpawner = gameObject.AddComponent <SgtLightningSpawner>(); return(lightningSpawner); }
public static SgtBeltCustom Create(int layer, Transform parent, Vector3 localPosition, Quaternion localRotation, Vector3 localScale) { var gameObject = SgtHelper.CreateGameObject("Belt Custom", layer, parent, localPosition, localRotation, localScale); var beltCustom = gameObject.AddComponent <SgtBeltCustom>(); return(beltCustom); }
public static SgtRing Create(int layer, Transform parent, Vector3 localPosition, Quaternion localRotation, Vector3 localScale) { var gameObject = SgtHelper.CreateGameObject("Ring", layer, parent, localPosition, localRotation, localScale); var ring = gameObject.AddComponent <SgtRing>(); return(ring); }
public static SgtSpacetime Create(int layer, Transform parent, Vector3 localPosition, Quaternion localRotation, Vector3 localScale) { var gameObject = SgtHelper.CreateGameObject("Spacetime", layer, parent, localPosition, localRotation, localScale); var spacetime = gameObject.AddComponent <SgtSpacetime>(); return(spacetime); }
public static SgtLens Create(int layer, Transform parent, Vector3 localPosition, Quaternion localRotation, Vector3 localScale) { var gameObject = SgtHelper.CreateGameObject("Lens", layer, parent, localPosition, localRotation, localScale); var lens = gameObject.AddComponent <SgtLens>(); return(lens); }
public static SgtBackdrop Create(int layer, Transform parent, Vector3 localPosition, Quaternion localRotation, Vector3 localScale) { var gameObject = SgtHelper.CreateGameObject("Backdrop", layer, parent, localPosition, localRotation, localScale); var backdrop = gameObject.AddComponent <SgtBackdrop>(); return(backdrop); }
public static SgtDepthRaycast Create(int layer, Transform parent, Vector3 localPosition, Quaternion localRotation, Vector3 localScale) { var gameObject = SgtHelper.CreateGameObject("Depth Raycast", layer, parent, localPosition, localRotation, localScale); var depthRaycast = gameObject.AddComponent <SgtDepthRaycast>(); return(depthRaycast); }
public static SgtShapeGroup Create(int layer, Transform parent, Vector3 localPosition, Quaternion localRotation, Vector3 localScale) { var gameObject = SgtHelper.CreateGameObject("Shape Group", layer, parent, localPosition, localRotation, localScale); var shapeGroup = gameObject.AddComponent <SgtShapeGroup>(); return(shapeGroup); }
public static SgtProminence Create(int layer, Transform parent, Vector3 localPosition, Quaternion localRotation, Vector3 localScale) { var gameObject = SgtHelper.CreateGameObject("Prominence", layer, parent, localPosition, localRotation, localScale); var prominence = gameObject.AddComponent <SgtProminence>(); return(prominence); }
public static SgtDebrisGrid Create(int layer, Transform parent, Vector3 localPosition, Quaternion localRotation, Vector3 localScale) { var gameObject = SgtHelper.CreateGameObject("Debris Grid", layer, parent, localPosition, localRotation, localScale); var debrisGrid = gameObject.AddComponent <SgtDebrisGrid>(); return(debrisGrid); }
public static SgtTerrainPlanet Create(int layer, Transform parent, Vector3 localPosition, Quaternion localRotation, Vector3 localScale) { var gameObject = SgtHelper.CreateGameObject("Terrain Planet", layer, parent, localPosition, localRotation, localScale); var instance = gameObject.AddComponent <SgtTerrainPlanet>(); gameObject.AddComponent <SgtTerrainPlanetMaterial>(); return(instance); }
public SgtStarfieldCustom MakeEditableCopy(int layer, Transform parent, Vector3 localPosition, Quaternion localRotation, Vector3 localScale) { #if UNITY_EDITOR SgtHelper.BeginUndo("Create Editable Starfield Copy"); #endif var gameObject = SgtHelper.CreateGameObject("Editable Starfield Copy", layer, parent, localPosition, localRotation, localScale); var customStarfield = SgtHelper.AddComponent <SgtStarfieldCustom>(gameObject, false); var quads = new List <SgtStarfieldStar>(); var starCount = BeginQuads(); for (var i = 0; i < starCount; i++) { var quad = SgtPoolClass <SgtStarfieldStar> .Pop() ?? new SgtStarfieldStar(); NextQuad(ref quad, i); quads.Add(quad); } EndQuads(); // Copy common settings customStarfield.Color = Color; customStarfield.Brightness = Brightness; customStarfield.MainTex = MainTex; customStarfield.Layout = Layout; customStarfield.LayoutColumns = LayoutColumns; customStarfield.LayoutRows = LayoutRows; customStarfield.LayoutRects = new List <Rect>(LayoutRects); customStarfield.BlendMode = BlendMode; customStarfield.RenderQueue = RenderQueue; customStarfield.PowerRgb = PowerRgb; customStarfield.ClampSize = ClampSize; customStarfield.ClampSizeMin = ClampSizeMin; customStarfield.Stretch = Stretch; customStarfield.StretchVector = StretchVector; customStarfield.StretchScale = StretchScale; customStarfield.StretchLimit = StretchLimit; customStarfield.Near = Near; customStarfield.NearTex = NearTex; customStarfield.NearThickness = NearThickness; customStarfield.Pulse = Pulse; customStarfield.PulseOffset = PulseOffset; customStarfield.PulseSpeed = PulseSpeed; // Copy custom settings customStarfield.Stars = quads; // Update customStarfield.UpdateMaterial(); customStarfield.UpdateMeshesAndModels(); return(customStarfield); }
public SgtStarfieldCustom MakeEditableCopy(int layer, Transform parent, Vector3 localPosition, Quaternion localRotation, Vector3 localScale) { #if UNITY_EDITOR SgtHelper.BeginUndo("Create Editable Starfield Copy"); #endif var gameObject = SgtHelper.CreateGameObject("Editable Starfield Copy", layer, parent, localPosition, localRotation, localScale); var customStarfield = SgtHelper.AddComponent <SgtStarfieldCustom>(gameObject, false); var stars = customStarfield.Stars; var starCount = BeginQuads(); for (var i = 0; i < starCount; i++) { var star = SgtPoolClass <SgtStarfieldStar> .Pop() ?? new SgtStarfieldStar(); NextQuad(ref star, i); stars.Add(star); } EndQuads(); // Copy common settings customStarfield.Color = color; customStarfield.Brightness = brightness; customStarfield.MainTex = mainTex; customStarfield.Layout = layout; customStarfield.LayoutColumns = layoutColumns; customStarfield.LayoutRows = layoutRows; customStarfield.layoutRects = new List <Rect>(layoutRects); customStarfield.blendMode = blendMode; customStarfield.renderQueue = renderQueue; customStarfield.powerRgb = powerRgb; customStarfield.clampSize = clampSize; customStarfield.clampSizeMin = clampSizeMin; customStarfield.stretch = stretch; customStarfield.stretchVector = stretchVector; customStarfield.stretchScale = stretchScale; customStarfield.stretchLimit = stretchLimit; customStarfield.near = near; customStarfield.nearTex = nearTex; customStarfield.nearThickness = nearThickness; customStarfield.pulse = pulse; customStarfield.pulseOffset = pulseOffset; customStarfield.pulseSpeed = pulseSpeed; return(customStarfield); }
public SgtBeltCustom MakeEditableCopy(int layer, Transform parent, Vector3 localPosition, Quaternion localRotation, Vector3 localScale) { #if UNITY_EDITOR SgtHelper.BeginUndo("Create Editable Belt Copy"); #endif var gameObject = SgtHelper.CreateGameObject("Editable Belt Copy", layer, parent, localPosition, localRotation, localScale); var customBelt = SgtHelper.AddComponent <SgtBeltCustom>(gameObject, false); var quads = new List <SgtBeltAsteroid>(); var quadCount = BeginQuads(); for (var i = 0; i < quadCount; i++) { var asteroid = SgtPoolClass <SgtBeltAsteroid> .Pop() ?? new SgtBeltAsteroid(); NextQuad(ref asteroid, i); quads.Add(asteroid); } EndQuads(); // Copy common settings customBelt.Color = Color; customBelt.Brightness = Brightness; customBelt.MainTex = MainTex; customBelt.Layout = Layout; customBelt.LayoutColumns = LayoutColumns; customBelt.LayoutRows = LayoutRows; customBelt.LayoutRects = new List <Rect>(LayoutRects); customBelt.BlendMode = BlendMode; customBelt.RenderQueue = RenderQueue; customBelt.OrbitOffset = OrbitOffset; customBelt.OrbitSpeed = OrbitSpeed; customBelt.Lit = Lit; customBelt.LightingTex = LightingTex; customBelt.AmbientColor = AmbientColor; customBelt.PowerRgb = PowerRgb; // Copy custom settings customBelt.Asteroids = quads; // Update customBelt.UpdateMaterial(); customBelt.UpdateMeshesAndModels(); return(customBelt); }
public SgtBeltCustom MakeEditableCopy(int layer, Transform parent, Vector3 localPosition, Quaternion localRotation, Vector3 localScale) { #if UNITY_EDITOR SgtHelper.BeginUndo("Create Editable Belt Copy"); #endif var gameObject = SgtHelper.CreateGameObject("Editable Belt Copy", layer, parent, localPosition, localRotation, localScale); var customBelt = SgtHelper.AddComponent <SgtBeltCustom>(gameObject, false); var asteroids = customBelt.Asteroids; var quadCount = BeginQuads(); for (var i = 0; i < quadCount; i++) { var asteroid = SgtPoolClass <SgtBeltAsteroid> .Pop() ?? new SgtBeltAsteroid(); NextQuad(ref asteroid, i); asteroids.Add(asteroid); } EndQuads(); // Copy common settings customBelt.Color = Color; customBelt.Brightness = Brightness; customBelt.mainTex = mainTex; customBelt.layout = layout; customBelt.layoutColumns = layoutColumns; customBelt.layoutRows = layoutRows; customBelt.layoutRects = new List <Rect>(layoutRects); customBelt.blendMode = blendMode; customBelt.renderQueue = renderQueue; customBelt.orbitOffset = orbitOffset; customBelt.orbitSpeed = orbitSpeed; customBelt.lit = lit; customBelt.lightingTex = lightingTex; customBelt.ambientColor = ambientColor; customBelt.powerRgb = powerRgb; return(customBelt); }