News:

Welcome to World of Banished!

Main Menu

Texture Problem

Started by Maldrick, January 22, 2018, 02:54:02 PM

Previous topic - Next topic

0 Members and 2 Guests are viewing this topic.

Maldrick

Quote from: RedKetchup on January 23, 2018, 03:47:05 PM
yes the doors are just cosmetics. did you played my beta ? where you have 6 different models for each kind of housing ? and noticed the doors where everytime at a different place ? and you had citizen going for the same spot in front of the house ? and not in front of each door ?

yeah only 1 use_001 point is allowed.

if it is more important, then you need to seperate them and not make any "F" alternate and have each single house to have their own single icon on the toolbar :)

Awesome, thank you!  This was very confusing.  Couldn't figure out how modders had doors in different places but weren't able to set points for them.  But, no, I'd never noticed that bannies weren't necessarily accessing the doors in each one, either.  Never even occurred to me to look till I got into this over the past couple days.  As long as work gets done, I've long since stopped paying attention to what individual bannies actually do, lest I go completely insane. Kind of like real life work, actually :P  So as long as the use point is accessible, everything works....So for a bunch of different variants just put it in a general location and call it a day.

Excellent, thank you!
"We are the architects of our actions and we must live with their consequences, whether glorious or tragic."
― Ezio Auditore da Firenze

kid1293

Just a quick note on AO. RK's mention of an all-white AO is good and useful.
I have an all-white DummyAO.png and DummyAO.rsc which I bring along to all new mods.
I call it from buildstages. Why AO-map a buildstage which is visible only a couple of seconds?

edit - The game uses UV-map for AO if there is no specified AO-map. With an all-white is does
not matter.

RedKetchup

Quote from: Maldrick on January 23, 2018, 03:48:36 PM

Very cool...I use Gimp also and I'll plug in your brush for sure.  Thank you very much.

I'm still not entirely sure what they are used for. lol  The tutorial didn't go over that and it still works?

Also, question...After I create a footprint, where does the png go and which file calls it?  I'll have to set that.

did you found my brush i posted somewhere in another thread ? if not i can repost.

in your template you have this code
DecalDescription decal
{
MaterialInstance _materials
[
"Models\Buildings\WoodHouse\MaterialInstance\WoodHouseFootprintMaterial.rsc"
"Models\Buildings\WoodHouse\MaterialInstance\WoodHouseFootprintDamageMaterial.rsc"
]


you decide where you put those. the links need to reflect your folder structure where you want to put those. and inside each file, you put the good link structures relying to the next footprint file. they come in group of 4 files. (3.rsc 1.png)

the code below decide the size of your .png and where it need to start to read - to - where it finish for each footprint
bool _tiled = false;
float _initialAlpha = 0.5;
float _mapWidth = 1024.0;

DecalLocation _decalLocations
[
{
float _x0 = 0.0;
float _y0 = 0.0;
float _x1 = 256.0;
float _y1 = 256.0;
}
> > > Support Mods Creation developments with Donations by Paypal  < < <
Click here to Donate by PayPal .

Discrepancy

Quote from: Maldrick on January 23, 2018, 03:42:43 PM
So how do you accommodate different doors in different places?  Is the door sometimes just cosmetic and they are actually accessing the building through a wall?  Not sure I've ever noticed but was never looking for it, either.

Sometimes I do make them cosmetic and actually have the 'use_001' point just in front of the house - I think I did this for some of the jetty houses as well as the angled village housing. So they never actually enter the house to collect food or warm up.
You can of course just have them go through the wall.


Quote from: Maldrick on January 23, 2018, 03:42:43 PM
So if I'm reading correctly, you can have multiple sets of points if each model has it's own fbx...Just have them called individually in the coding?  Forgive me for not being more specific, I don't have it in front of me and I'm very fuzzy on which is which.  Or, no, only one set of points (besides smoke) regardless of approach?

Yes and no.

What I do is make my models, make a single dummy 'points' list, also make the build_001, use_001, create_001 points and attach to 'points'.
I include this point list with 1 of the variants .fbx file or you can make a .fbx with just these points.

Now with each variant building you have made - they are to each be compiled as separate .fbx's

on each building attach another dummy point called 'smoke' - just add it to the actual 'mesh' model in blender.

by not including the point list in the particle code call-up it, the template file for the building will instead search each model for a corresponding 'smoke' point.

I don't know if this actually works the same with the use_001, build_001 etc

Maldrick

Quote from: kid1293 on January 23, 2018, 03:55:17 PM
Just a quick note on AO. RK's mention of an all-white AO is good and useful.
I have an all-white DummyAO.png and DummyAO.rsc which I bring along to all new mods.
I call it from buildstages. Why AO-map a buildstage which is visible only a couple of seconds?

edit - The game uses UV-map for AO if there is no specified AO-map. With an all-white is does
not matter.

Very interesting.  I think I saw a post of yours where you mentioned this.  Makes sense.  But why do it if you are AO mapping the mesh anyway?  I'm guessing to save space on the map so you can spread everything out and get a better image?

@RedKetchup

Yes, I went through Triangle's tipi post earlier because he was doing a couple weeks ago what I'm doing now and thought there'd be relevant info there.  Think you posted it there.

Thank you for the clarification.  I'm kind of lost with the mod kit so any info about what is where goes a long way to getting me on track.

Thank you again. :)

Quote from: Discrepancy on January 23, 2018, 03:57:50 PM

What I do is make my models, make a single dummy 'points' list, also make the build_001, use_001, create_001 points and attach to 'points'.
I include this point list with 1 of the variants .fbx file or you can make a .fbx with just these points.

Now with each variant building you have made - they are to each be compiled as separate .fbx's

on each building attach another dummy point called 'smoke' - just add it to the actual 'mesh' model in blender.

by not including the point list in the particle code call-up it, the template file for the building will instead search each model for a corresponding 'smoke' point.

I don't know if this actually works the same with the use_001, build_001 etc

Just to make sure I have this straight...

Make a generic points fbx like we did for the tutorial, but leave out smoke.  Do a smoke point for each variant in its own separate fbx, and link it to the mesh in each one with the drag and drop functionality in blender.  Leave out the call for smoke in the template.  And the pointlist in the template rsc will do the rest?

I'm sure I'm going to screw this up and be back here asking more questions in a couple of days, but if I've got that straight I should be okay to get a good start on it.

Also, since you mention it, what is the create_001 point for?  That wasn't covered in the tutorial...I'm guessing that's for production buildings?  Here's where I probably need to go read the documentation again but thought I'd ask since it comes up.

Thanks again, everybody!  Totally got me back on track.  Enough to get started anyway.
"We are the architects of our actions and we must live with their consequences, whether glorious or tragic."
― Ezio Auditore da Firenze

Discrepancy

you got it :) correct.


create_001 point is only used in production and other buildings. not in house buildings.

It creates a spot for the resources to appear that have been made.

Discrepancy

#36
So the points are:

build_001, build_002, ...... etc. etc  - as many as you want- these dictate the spots where builders will construct the building. The more you have, the more builders can be employed to build.

use_001, use_001, ... etc - can be many also, these are spots that workers will work at in production buildings - so for a mine or quarry where you might have 10+ workers, you should have as many use points as maximum workers.
In a house, they will use the use_001 point only, this is where they collect food and get warm.

create_001, create_002 - like I said above, this is where resources will appear in production buildings - for example where firewood will appear at woodcutter.

*** create_002 is also the point that nomads will arrive at the townhall. *** ????? or is it 'nomad_001'... I just did a forum search and found that in RK's Choo Choo post... I'm unable to look at my own models right now, but I'm sure I used create_002....

*** boat_001 is the point that is used at trading posts for the boat to arrive at.

smoke points can be called anything as long as you refer correctly to them in the particle list in template file.


@RedKetchup & @kid1293 have I missed any?

RedKetchup

trading post i think it is "boat_001" although i always put a "boat" one to make sure
livestock bought is "create_002" but it needs also the "create_001" so the _002 can operate.


nomad is "create_002" i also do the same as the TP, i put also a "create_001" to make sure the _002 operates.


as you said, numbers of "build_00x" = the number of builders required to build the building.
the "create_00x" are where you want to new resources created to appear.
the "use_00x" is where you want to have the workers standing in order to work or use the building.

> > > Support Mods Creation developments with Donations by Paypal  < < <
Click here to Donate by PayPal .

Maldrick

Excellent. Thank you, guys.  This is great info.  Not anywhere close to this point, but I'll reference this in the future, for sure.

@Discrepancy

Thinking I might start a new project to try the f-variants with.  Question...In the tutorial we set the scale to meters (making a grid square in blender 1 meter) and then scaled the fbx down from there at the end.  Using that system, what do you guys generally consider "1 story" in terms of building height?  I would look in game, but we scaled the model down an additional 30% at the end.  Purely guessing, but I'm thinking a bannie is roughly 1 meter tall (in these terms) or just short of it?
"We are the architects of our actions and we must live with their consequences, whether glorious or tragic."
― Ezio Auditore da Firenze

Discrepancy

yeah about 1 meter is the height of them.

depending on the building my doors are from 1m to 1.5, most about 1.3m

1.5-1.8 or higher for start of second story.  I myself have no set dimensions.

Maldrick

"We are the architects of our actions and we must live with their consequences, whether glorious or tragic."
― Ezio Auditore da Firenze

RedKetchup

i usually have foundations of 0,3' high with 0,1' underground (so 0,2' outside) then the 1st floor wall has 1,4' and then the attic.
my door is 1,2' high per 0,66'
my windows have 0,4'x0'5' or 0,5'x0,6' depending what i want.
> > > Support Mods Creation developments with Donations by Paypal  < < <
Click here to Donate by PayPal .

Maldrick

Awesome, thank you, RK.  Helps a lot.
"We are the architects of our actions and we must live with their consequences, whether glorious or tragic."
― Ezio Auditore da Firenze

Maldrick

So I decided to follow through with the house I already have...Partly because I'm not entirely sure what I'm going to do next and partly because it gets me into the modkit faster.  Spent about an hour today browsing through it and have a lot better understanding of how everything works together.  For where I'm at now at least.  Plus, I already did this one, might as well finish it.

@kid1293

Thank you for the advice on AO mapping.  Before getting into Necora's post, I tried what you suggested...Made a separate AO channel and separated everything out so nothing is overlapping.  Was a bit tedious, but worked perfectly.  Thank you for the help with that.

@kid1293 @Discrepancy

Was sitting down to start putting some F-variants together.  Was about to do what you suggested but just out of curiosity I made some changes to the texture png and recompiled without making any changes in Blender.  The changes showed up just fine.  Is it possible to just use different texture files for each variant or is not assigning them in Blender asking for problems of some kind?  I was planning to make the changes in blender, but since I noticed that I just thought I would ask if that's an acceptable corner to cut.

Also, I was thinking I would skip making a footprint for this one.  The model gets resized as part of the tutorial and it doesn't cleanly fit the grid and not sure I want to deal with it.  I'll do one for the next one though.  Will that cause any kind of problem?   Still not entirely sure what they actually do besides build01 cosmetics.

Really appreciate all the help.  You guys got me back on track with your advice and it finally started to click today and having a great time with this.
"We are the architects of our actions and we must live with their consequences, whether glorious or tragic."
― Ezio Auditore da Firenze

Discrepancy

The footprints do finish off a model nicely, adding the dirt (or other) look to the ground below the model. It is not necessary, but also helps players know where the building is just after they've set the footprint down....
I also still have a lot of buildings that don't have one or are invisible.

If you are making an F-key variant, you will need to duplicate the model in the .fbx file and assign the 2nd texture to it - you need to do this as the game will look for the material name when it tries to compile.

So you have your first house: for example right now you would have the mesh within the .fbx calling up the material texture, names used for example 'MaldrickSmallHouse', the modkit links this to a MaterialInstance file of the same name: 'MaldrickSmallHouse.rsc', this calls up another file called 'MaldrickSmallHouseTexture.rsc', which calls up your ''MaldrickSmallHouse.png' texture file.

For you to add a 2nd textured home, you must make the same again but obviously named different.
So you will have copied the house model you made (you can do it in the export blender file, just select the house that you have already made in object mode and press Shift+D), name it something different, and attach the 2nd texture you have made, you will then need to do the same Models and MaterialInstance files to call up the texture.