Ultimate space simulation software

 
User avatar
PlutonianEmpire
Explorer
Explorer
Posts: 261
Joined: 02 Nov 2016
Location: MinneSNOWta
Contact:

Help with creating Mods and Addons

26 Nov 2017 16:11

I read this a while ago: https://www.livescience.com/31109-plant ... ivers.html

And now I'm trying to make a mod where lifeless terras have the old ugly default rivers, while the lifeterras get the rivers designed by Rodrigo:

    // Pseudo rivers
    if (riversOctaves > 0)
    {
   
    if (life < 1)
    {
        noiseOctaves    = riversOctaves;
        noiseLacunarity = 2.218281828459;
        noiseH          = 0.5;
        noiseOffset     = 0.8;
        p = point * mainFreq + Randomize;
        distort = 0.350 * Fbm3D(p * riversSin) +
                  0.035 * Fbm3D(p * riversSin * 5.0) +
                  0.010 * Fbm3D(p * riversSin * 25.0);
        cell = Cell3Noise2(riversFreq * p + distort);
        float pseudoRivers = 1.0 - saturate(abs(cell.y - cell.x) * riversMagn);
        pseudoRivers = smoothstep(0.0, 1.0, pseudoRivers);
        pseudoRivers *= 1.0 - smoothstep(0.06, 0.10, global - seaLevel); // disable rivers inside continents
        pseudoRivers *= 1.0 - smoothstep(0.00, 0.01, seaLevel - height); // disable rivers inside oceans
        height = mix(height, seaLevel-0.02, pseudoRivers);
    }
   
    else
    {
     noiseOctaves = 14.0;
        noiseH       = 1.0;
        noiseLacunarity = 2.1;

       
        p = point * 2.0* mainFreq + Randomize;
        distort = 0.65 * Fbm3D(p * riversSin) +
                  0.03 * Fbm3D(p * riversSin * 5.0) + 0.01* RidgedMultifractalErodedDetail(point * 0.3* (canyonsFreq+1000)*(0.5*(inv2montesSpiky+1))  + Randomize, 2.0, erosion, montBiomeScale);
        cell = 2.5* Cell3Noise2(riversFreq * p + 0.5*distort);
       
float pseudoRivers2 = 1.0 - (saturate(0.36 * abs(cell.y - cell.x) * riversMagn));
        pseudoRivers2 = smoothstep(0.25, 0.99, pseudoRivers2);
        pseudoRivers2 *= 1.0 - smoothstep(0.055, 0.065, global - (0.000000008* (hillsFreq*hillsFreq+900000) * rocks)-seaLevel); // disable rivers inside continents
        pseudoRivers2 *= 1.0 - smoothstep(0.000, 0.0001, seaLevel - height); // disable rivers inside oceans
        height = mix(height, seaLevel+0.003, pseudoRivers2);


cell = 2.5* Cell3Noise2(riversFreq * p + 0.5*distort);
float pseudoRivers = 1.0 - (saturate(4.2 * abs(cell.y - cell.x) * riversMagn));
        pseudoRivers = smoothstep(0.0, 1.0, pseudoRivers);
        pseudoRivers *= 1.0 - smoothstep(0.055, 0.057, global - (0.000000008* (hillsFreq*hillsFreq+900000) * rocks)-seaLevel);
        pseudoRivers *= 1.0 - smoothstep(0.00, 0.005, seaLevel - height); // disable rivers inside oceans
        height = mix(height, seaLevel-0.0015, pseudoRivers);
   }
 }


However I get an error at startup and the SE.log says this:
[MT] Loading  shader "addons/shaders/tg_terra_height.glsl"
[MT] ERROR: Compiling shader "#/shaders/tg_terra_height.glsl":
ERROR: 0:3342: 'life' : undeclared identifier
[MT] ERROR: Linking shader "#/shaders/tg_terra_height.glsl":
Attached fragment shader is not compiled.
[MT] Procedural generator shaders loaded in 646.557 ms


How can I make my idea work?
Specs: Dell Inspiron 5547 (Laptop); 8 gigabytes of RAM; Processor: Intel® Core™ i5-4210U CPU @ 1.70GHz (4 CPUs), ~2.4GHz; Operating System: Windows 7 Home Premium 64-bit; Graphics: Intel® HD Graphics 4400 (That's all there is :( )
 
User avatar
ngx
Observer
Observer
Posts: 2
Joined: 12 Nov 2017

Help with creating Mods and Addons

09 Dec 2017 02:52

Hello people, please, i need help. I'm noob to blender and SE as well, so maybe there will be an easy answer.
I adjusted existing 3d model in blender, exported it to .obj and .mtl and successfuly built in SE. Everything goes ok, however, after the first build, console and log say that certain material already exists in this (?) library with different name and will be used instead. After restarting SE, console shows no errors, but ship is built with different materials than first time.
How does SE determine that certain materials are duplicates?
Thank you!

this is log extract:
[00] Replacing of duplicate materials ENABLED
[00] Material "material_1_gate_rear" already exist in this library with a name "material_1_gate_front". Using EXISTING material.
[00] Material "material_1_stove" already exist in this library with a name "material_1_glass". Using EXISTING material.
[00] Material "material_chair_polstr_NONE" already exist in this library with a name "material_chair_polstr". Using EXISTING material.
[00] Material "material_cpt_panel_l" already exist in this library with a name "material_cpt_gauge_r". Using EXISTING material.
 
User avatar
ngx
Observer
Observer
Posts: 2
Joined: 12 Nov 2017

Help with creating Mods and Addons

09 Dec 2017 03:08

[quote="ngx"]
How does SE determine that certain materials are duplicates?
[/quote]

forget it, i've already foud the answer, i missed it in manual somehow...

Who is online

Users browsing this forum: Google [Bot] and 1 guest