Jump to content

[1.2.2] [WIP] INSTANTIATOR - a plugin that allows you to create accretion disks, custom star coronas, nebulas & even more!


Recommended Posts

About

INSTANTIATOR is the plugin that allows you to place primitives and billboards around the celestial bodies and do a lot of manipulations with them.

 

How to use it?

1. Drop everything from the .zip file to your GameData folder

2. Open the file "Object.cfg" in any text editor (Notepad++ for example)

This file contains the list of the objects and its parameters.

The object config node looks like this:

SCALED_OBJECT
{
          name = ExampleSphere
	  type = sphere             
	  scale = 12000, 12000, 12000   
	  shader = Unlit/Transparent   
	  main_tex = /example_tex            
	  rotation = 0, 0, 0        
	  bodyName = Kerbin          
	  invertNormals = false    
}

Let's break it down!

name - the name of GameObject

type  - for now there's 3 object types - "cube", "sphere" and "billboard". 

                        NOTE: the objects of type billboard can be applied to the bodies that has the Sun template (or to The Sun itself)  ONLY.

scale - the scale of the GameObject (x,y,z)

shader - You can use any shader that is present in Unity.

main_tex - path to the texture 

rotation - the rotation of the GameObject (x,y,z)

bodyName - the name of the parent body

invertNormals - inverts the normals of the mesh

 

 

DOWNLOAD:

Compiled (An example is included)

Source

88x31.png

 

 

 

Planet packs that uses it:

Gameslinx's Planet Pack by @Gameslinx

Kargantua System

 

Warning! It's the alpha version and it may contain a lot of glitches. If you find a one, please let me know.

Planned features:

 -Edit all the material parameters

 -Load custom .mu files

 

 

 

Edited by Artyomka15
Add-on Posting Rules
Link to post
Share on other sites

You can do things like this:

qPOdyeC.jpg

 

Also, is there a way to add 'depth' to the accretion disks? It's 2d at the moment :) 

 

And a suggestion: At the moment the effects rotate along with the initial body's rotation. Would it be possible to separate this out and provide a rotation axis independent to the parent body? 

Edited by Gameslinx
Link to post
Share on other sites
20 minutes ago, Gameslinx said:

You can do things like this:

qPOdyeC.jpg

 

Also, is there a way to add 'depth' to the accretion disks? It's 2d at the moment :) 

 

And a suggestion: At the moment the effects rotate along with the initial body's rotation. Would it be possible to separate this out and provide a rotation axis independent to the parent body? 

For the depth - you can adjust the scale along the Y axis, but the disk will look, well, pretty strange...

 

And for the rotation - for now i didn't find the way to do that... :( 

 

Edited by Artyomka15
Link to post
Share on other sites

Now THIS!!! This is what I'm talking about! You've just made modding history here @Artyomka15! :D Now... I would like to make a suggestion, I noticed that the Instantiator effects tend to unload with the parent body. Can you fix this so we can makes these effects work at massive distances?

Link to post
Share on other sites
On 19.03.2017 at 3:05 AM, EnriqueBNew said:

Compatibility with 1.2.1?

It's should be compatible with any version that came out after the release.

16 hours ago, daniel l. said:

Also can you add XYZ coordinates to this? So we can make our objects hold different locations relative to the central body if we wish.

I'll soon release an update which will include this feature :) 

Link to post
Share on other sites

Gonna report a bug. When looking at the accretion disk from above it spins the correct way, however looking at the disk from below reverses the texture and looks like it's spinning the wrong way.

Link to post
Share on other sites
  • 2 weeks later...

May I ask @Artyomka15 how am I able to create a nebula? I'm intrigued because I've been looking into how space engine does it, but it's not written in the same programming language as KSP (for unity - probably C#)

If you have a moment, are you able to explain how I can create a nebula?

Link to post
Share on other sites

Another issue with the pulsarloader. I'm not trying to use any of the pulsar features of the mod, so I have no entry for it (whatsoever) in the Objects.cfg config.

NullReferenceException: Object reference not set to an instance of an object
  at INSTANTIATOR.PulsarLoader.Update () [0x00000] in <filename unknown>:0 
 
(Filename:  Line: -1)

NullReferenceException: Object reference not set to an instance of an object
  at INSTANTIATOR.PulsarLoader.Update () [0x00000] in <filename unknown>:0 

^ That gets spammed over and over in the output log during the loading of the game, slowing down load times.

Link to post
Share on other sites
  • 3 weeks later...
  • 2 weeks later...

What exactly are the limitations to INSTANTIATOR's config file? More specifically:

- Must it be placed in INSTANTIATOR or can it be placed in a different folder?

- Can it be altered by a Module Manager patch? (Like @Body in Kopernicus)

Link to post
Share on other sites
On 04/05/2017 at 4:33 PM, The White Guardian said:

What exactly are the limitations to INSTANTIATOR's config file? More specifically:

- Must it be placed in INSTANTIATOR or can it be placed in a different folder?

- Can it be altered by a Module Manager patch? (Like @Body in Kopernicus)

I checked the code when I first got it and Instantiator.DLL looks for the objects CFG in Instantiator/Objects.cfg. So I belive the file path can't be changed, but the textures can.

For MM patches (I think this is for compatibility reasons) I'm not sure.

Link to post
Share on other sites
  • 2 weeks later...
  • 3 weeks later...
On 09/06/2017 at 11:11 PM, Nailed it! said:

How can you make different kinds of acreetion disks? I'm trying to make a water one...

Draw it yourself!

Or apply rotation filters over textures and centre them. That's what I did for my gas giant.

 

Link to post
Share on other sites
  • 1 month later...

Could it be possible for you to increase the size limit on how large the objects can be? Because right now, if you make the object too large, it glitches out, the same way with large rings created in Kopernicus.

Also, could you add some sort of ability to change the orientation of the object? I am creating a 3D Helix Nebula for one of my mods and I want it to be properly pointed towards Earth.

Link to post
Share on other sites

Oh boy this is great! But as AndrewDrawsPrettyPictures said, the size limit needs to be bigger. I'm gonna use this to create a GALAXY. Also, can you update this to 1.3 pls?

Edited by GenesisPlayz
Link to post
Share on other sites

@AndrewDrawsPrettyPictures you could create a 'barycentre' for the nebula, and apply a type "sphere" around it to make it look 3d.

@GenesisPlayz it works on 1.3 but DO NOT apply it to stars. There's a bug where it causes lag and output log bloating. I've wittered on about this for a while now so I'll stop

Link to post
Share on other sites
This thread is quite old. Please consider starting a new thread rather than reviving this one.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...