Jump to content

Questions about .cfg


Recommended Posts

Question 1 : Where i find documentation on this : biomeMask = 3  ?

Answer : It uses the same bit mask pattern as SituationMask but determines where the result will vary by biome as well as situation. SrfLanded = 1 SrfSplashed = 2, FlyingLow = 4, FlyingHigh = 8, InSpaceLow = 16, InSpaceHigh = 32

In the example given  situationMask = 63 says the experiment will work everywhere (1 + 2 + 4 + 8 + 16 + 32 = 63) but biomeMask = 3 restricts biome specific results to just 1 (SrfLanded) + 2 (SrfSplashed)

 

Question 2 : How to add an ModuleColorChanger who change _EmissiveColor after a science experiment ?

Question 3 : How to add a second ModuleColorChange on the same part to change _Color ?

Question 4 : How we refresh scienceDefs.cfg ingame ?

Question 5 : How i can export my techtree, ressources, agencies, ores, scienceDefs without overwriting over Squad files ?
Edited by Warsoul
Link to comment
Share on other sites

It uses the same bit mask pattern as SituationMask but determines where the result will vary by biome as well as situation.

SrfLanded = 1 SrfSplashed = 2, FlyingLow = 4, FlyingHigh = 8, InSpaceLow = 16, InSpaceHigh = 32

In the example given  situationMask = 63 says the experiment will work everywhere (1 + 2 + 4 + 8 + 16 + 32 = 63) but biomeMask = 3 restricts biome specific results to just 1 (SrfLanded) + 2 (SrfSplashed)

Link to comment
Share on other sites

How to add an ModuleColorChanger who change emissive to a science experiment ?

I tried to insert them into the ModuleScienceExperiment but seems not working that way.

Spoiler

MODULE
    {
        name = ModuleColorChanger
        shaderProperty = _EmissiveColor
        animRate = 0.4
        animState = true
        useRate = true
        toggleInEditor = true
        toggleInFlight = true
        toggleInFlight = true
        unfocusedRange = 5
        toggleName = Toggle Lights
        eventOnName = Lights On
        eventOffName = Lights Off
        toggleAction = True
        defaultActionGroup = Custom1
        redCurve
        {
            key = 0 1
            key = 1 0
        }
        greenCurve
        {
            key = 0 1
            key = 1 0
        }
        blueCurve
        {
            key = 0 0
            key = 1 0
        }
        alphaCurve
        {
            key = 0 1
        }
    }

Spoiler

MODULE
    {
        name = ModuleScienceExperiment
        experimentID = SIS125
        experimentActionName = Observe Sonic Boom
        resetActionName = Reset SIS125
        useStaging = False
        useActionGroups = True
        hideUIwhenUnavailable = True
        xmitDataScalar = 0.3
        FxModules = 0
        dataIsCollectable = True
        collectActionName = Collect Data
        interactionRange = 2
        usageReqMaskInternal = 1
        usageReqMaskExternal = 8
                
    }

 

Link to comment
Share on other sites

3 hours ago, Warsoul said:

Question 5 : How i can export my techtree, ressources, agencies, ores, scienceDefs without overwriting over Squad files ?

Typically this is done using a ModuleManager patch file (or several)

7 hours ago, Warsoul said:

You can't call an ModuleColorChanger with an EventName = ? Or something like this ? You can animate but you can't animate _emissiceColor ?

The ModuleColorChanger module (AFAIK) is self contained. It allows a light to be turned on and off by the player. You define how the player will control it through the various properties hence these lines which affect the attached parts PAW menu:

		toggleName = Toggle Lights
		eventOnName = Lights On
		eventOffName = Lights Off

If you want the light to respond to some in game event then I believe it requires a custom module. I'm also not really sure how lighting animations are configured in KSP but I believe they require some prep work on the model in Unity.

Link to comment
Share on other sites

^This is correct about lighting. If you want an actual light coming from your part, you have to add a light object to your part, and animate the alpha channel. The animation can be named anything, just as long as the .cfg reference is identically named.

If you just want to pay with emissives, it may be easiest to use or build off of IndicatorLights (link is above).

If you can find (or write) a mod that can change the model color in-game, I would be very interested.

Link to comment
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...