Author Topic: Help a newbie!  (Read 6157 times)

0 Members and 1 Guest are viewing this topic.

Offline kid1293

  • Modders
  • Banished Expert
  • *****
  • Posts: 1843
  • Never confuse movement with progress
Re: Help a newbie!
« Reply #105 on: March 19, 2017, 01:16:10 PM »

@Necora - I model in scale 1 and I put the mesh 20 units away :)
So it is maybe something with Blender losing focus when I am struggling
to make everything right. We'll see. Right now I am mapping separate
and I have a lot of time, so...

Offline Discrepancy

  • Modders
  • Architect
  • *****
  • Posts: 591
Re: Help a newbie!
« Reply #106 on: March 19, 2017, 01:31:01 PM »
I also have learned much from Necora.

@Tom Sawyer , I have been painting my AO image whiter, particularly the roof, lowering brightness and increasing contrast slightly, This seems to give it a 'thicker' snow look.

Online RedKetchup

  • Champion
  • Banished Expert
  • *****
  • Posts: 7273
Re: Help a newbie!
« Reply #107 on: March 19, 2017, 01:32:20 PM »
I also have learned much from Necora.


we all do :)
> > > Support Mods Creation developments with Paypal Donations < < <
Click here to PayPal Donate.

Offline Necora

  • Modders
  • Trader
  • *****
  • Posts: 477
Re: Help a newbie!
« Reply #108 on: March 19, 2017, 02:14:45 PM »
@Tom Sawyer I have a theory about snow but have not tested yet. Have you made a road texture? I did my first one the other day. It was only 1 texture, and I was messing around with it. In game in winter it came out as completely whited out by snow. When I was building, I noticed the mod kit throw up a warning (not an error) saying that the alpha channel of the texture is all white. So I added the alpha channel in gimp and changed it to transparent and you can now see the texture through the snow. So I am wondering, is this the same as with AO? Can you manipulate the colour of the alpha channel to add more snow where you want it by adding a white area to the alpha channel? IDK much about this sort of thing, but it might be worth giving it a go.

Offline Tom Sawyer

  • Modders
  • Architect
  • *****
  • Posts: 807
Re: Help a newbie!
« Reply #109 on: March 19, 2017, 03:17:10 PM »
Yes @Necora, I know about removing snow from roads via alpha channel and it also works for models. But it does not help here. I want more snow where it is affected by AO. I have brighten my AO in Photoshop like @Discrepancy and it helps. The shading is lighter (not so dark as it comes from Blender) and I have a bit more snow but still not really good. And full white would take away he AO shading from this part of the model.

There is a step while rendering the snow texture and so I went into the material files. I changed row 229 in the snow section of the OpaqueMaterial.srsl to "color.xyz = lerp(color.xyz, sno, pc.userPosition.x * input.seasonData.z * color.w);" and voila... Full snow on my little chapel, just a bit darker on the beams and stairs because of AO. :)

From left to right: without AO - with AO but removed snow - AO with changed opaque material.

http://www.banishedventures.com/images/ao-snow.jpg
Help a newbie!

Offline Necora

  • Modders
  • Trader
  • *****
  • Posts: 477
Re: Help a newbie!
« Reply #110 on: March 19, 2017, 03:42:55 PM »
@Tom Sawyer firstly, that is a beautiful little chapel.

Secondly, that awesome! Is looks like the same amount of snow as the first, without loosing AO. I noticed also that even vanilla buildings don't have great snow covering on the roofs, but I have no idea why AO should change that and the pure white AO is better. I've been playing around with the texture for the best part of the last hour, but just could not change the snow covering. I had two buildings side by side, one left as is, one I was messing around with all sorts of things in Gimp with the AO. No matter how much I made it brighter or contrasted, I could not get the white section any brighter than it already was from blender. The only thing I could do was remove the snow, not add to it. It is a shame really because I would love to have snow pile up in the corners, but instead you get dark shading.

I'll try your change and see what it does.

Offline Necora

  • Modders
  • Trader
  • *****
  • Posts: 477
Re: Help a newbie!
« Reply #111 on: March 19, 2017, 03:59:11 PM »
@Tom Sawyer could you tell me what that line of code was before you changed it? I need to revert back but forgot to back it up :(

Offline Discrepancy

  • Modders
  • Architect
  • *****
  • Posts: 591
Re: Help a newbie!
« Reply #112 on: March 19, 2017, 04:13:05 PM »
Nice find @Tom Sawyer

@Necora

vanilla OpaqueMaterial.srsl - line 229 =
Code: [Select]
color.xyz = lerp(color.xyz, sno, pc.userPosition.x * input.seasonData.z * color.w * ao.x * ao.x);
as Tom had changed it for snow on roof:
Code: [Select]
color.xyz = lerp(color.xyz, sno, pc.userPosition.x * input.seasonData.z * color.w);

Offline Necora

  • Modders
  • Trader
  • *****
  • Posts: 477
Re: Help a newbie!
« Reply #113 on: March 19, 2017, 04:34:04 PM »
Great thanks @Discrepancy

I changed it, and I can't see the difference... screenshot40 has Tom's line, screenshot41 has the original line.

Offline Tom Sawyer

  • Modders
  • Architect
  • *****
  • Posts: 807
Re: Help a newbie!
« Reply #114 on: March 19, 2017, 05:35:09 PM »
Maybe your change was not compiled @Necora. I copied the whole material folder in my mod for a quick attempt... For a clean solution we should use a new material to not affect all other buildings. I made such a material. Just copy these files in the Material folder of your mod and link to it from .../MaterialInstance/YourModelMesh.rsc instead of OpaqueSnowMaterial like this:

Code: [Select]
MaterialInstance resource
{
Material _material = "Material\OpaqueMoreSnow\OpaqueMoreSnowMaterial.rsc";
        ...
}

You also can rename the material to have your own and to not conflict with other mods.


Offline jesta030

  • Newbie in despair
  • Vendor
  • ***
  • Posts: 55
Re: Help a newbie!
« Reply #115 on: March 21, 2017, 07:49:02 AM »
I suggest that all answers regarding AO and snow on models go into blackliquidsoftware.com/index.php?/topic/861-ambient-occlusion-ao/&page=3 to minimize confusion.


Offline jesta030

  • Newbie in despair
  • Vendor
  • ***
  • Posts: 55
Re: Help a newbie!
« Reply #116 on: July 01, 2017, 11:32:07 PM »
Rumors of my death have been greatly exaggerated. It's just Civilization 6...

Anyways, I'm fiddling around again and am currently trying to get the map generator to spawn wheat close to and in water to later replace the model with reeds since I don't like what's in CC currently. And for the life of me I can't figure out how to do it. I've tried adding the path "template/NaturalResourceReed.rsc" to the StartingConditions.rsc which seems to control the map generator but to no avail. Googling hasn't brought up anything to point me in the right direction so... Help please?

Offline Tom Sawyer

  • Modders
  • Architect
  • *****
  • Posts: 807
Re: Help a newbie!
« Reply #117 on: July 02, 2017, 01:04:45 AM »
Welcome back! I'm also playing a game for myself these days but always come back to my modding project. ;)

The natural resource has to be added to the start condition itself (Hard.rsc for example), not to the default in StartConditions.rsc. At least I do it this way. But natural growing reeds is not really possible as far as I know and the reason why CC reeds is as it is. We cannot let it grow in water because people cannot gather it there and we cannot make it reseeding because it would spread on ground level 0 which means away from waters over the whole map. Maybe Bartender/Despo found a solution. I did not test their new version yet.

Online RedKetchup

  • Champion
  • Banished Expert
  • *****
  • Posts: 7273
Re: Help a newbie!
« Reply #118 on: July 02, 2017, 01:31:04 AM »
so i guess you made your own template NaturalResourceReed.rsc ? because it doesnt exist in the game. it has been created by moddlers.
but yeah, citizens cannot harvest in water zones.

about the the ground level... yeah original wheat has been designed to be at 0 level. to have something that would spawn at -0,75 of a tile below the 0 level, it needs to be setup inside its graphic file .fbx, and only there.
> > > Support Mods Creation developments with Paypal Donations < < <
Click here to PayPal Donate.

Offline Tom Sawyer

  • Modders
  • Architect
  • *****
  • Posts: 807
Re: Help a newbie!
« Reply #119 on: July 02, 2017, 01:49:13 AM »
I did not mean z-position of the mesh. I mean spawning on tiles with ground level 0 (flat land). We cannot avoid this because the game ignores the spawn height value when reseeding. If reeds would be able to reseed it would spread over the whole map...