Jump to content

Stock textures usage, hatch creation and some other questions about Blender and Unity


Recommended Posts

I've always been read-only on this forum, but working on mods had pushed me to creating the account here. I am quite a newbie to Blender, as i am only an engineer and the only 3D stuff i worked with was Siemens NX and ANSYS ICEM CFD, so please don't be so rude about my stupidity. So, i have at the moment questions (sorry for my English, I know it's bad):

1) As I was creating simple models, I faced the lack of free textures. AFAIK, Lack uses stock textures for his SXT, and I would like to know, what is the simplest way to incorporate them in the model (I only succeeded by converting them to .png and making another copy)?

2) In the manual on Kerbal Wiki i've seen the tutorial about making airlocks and ladders, i've got stuck on the moment where the child collision box object should be tagged as "airlock" and set to other layer. But my installation of Unity and Part Tools .23 doesn't have this option at all. How do i fix that?

3) What materials for parts should i use in Blender and Unity?

4) How do i assemble multiple models into one part?

Link to comment
Share on other sites

RE tags and layers. ignore the text note on the image and look toward the top , you see two tags marked Layer and Tag, if you click on them it gives you the option to create new tags or layers. The tags arrangement in the list is not important but the Layers is, if it's in the wrong layer it wont work, ladders and airlocks should be assigned to Part Triggers which is layer 21. Not sure which version of unity you use as layers and tags are part of the way the unity engine works and they are able to be set via the inspector in any version

unitymeshrenderdeletecomponent_zpsaa13ff3b.png

Materials I just use standard materials for my stuff and believe most others so as well, Unity call materials Shaders and they are selectable on material import and selection. try to use the KSP shaders as part tools can get grumpy if you dont,

I tjink lacks textures are stockalike rather than stock, just make your own..

Not sure what you mean by multiple models into one part perhaps an image of what you'd like to accomplish would help

Edited by SpannerMonkey(smce)
Link to comment
Share on other sites

RE tags and layers. ignore the text note on the image and look toward the top , you see two tags marked Layer and Tag, if you click on them it gives you the option to create new tags or layers. The tags arrangement in the list is not important but the Layers is, if it's in the wrong layer it wont work, ladders and airlocks should be assigned to Part Triggers which is layer 21. Not sure which version of unity you use as layers and tags are part of the way the unity engine works and they are able to be set via the inspector in any version

http://i1007.photobucket.com/albums/af199/V12Tony/Kerbal%20Space%20Program%20pics%20and%20model%20renders/unitymeshrenderdeletecomponent_zpsaa13ff3b.png

Materials I just use standard materials for my stuff and believe most others so as well, Unity call materials Shaders and they are selectable on material import and selection. try to use the KSP shaders as part tools can get grumpy if you dont,

I tjink lacks textures are stockalike rather than stock, just make your own..

Not sure what you mean by multiple models into one part perhaps an image of what you'd like to accomplish would help

Thanks, I think I've figured it out. And about the models, I meant combining different parts like engine nozzle and the base etc

Link to comment
Share on other sites

Hi you just make it as you want it in blender and export it , if you want different textures on each part , just make each part an object and assign a material and texture prior to export , engines usually have a normal, diffuse and emissive texture but can be all none or combinations of that arrangement

Link to comment
Share on other sites

Nope, I just straight up use the stock textures; the 'textures' in the SXT folder are just 1x1 placeholders and then are swapped out using the cfg. It makes SXT essentially 'free' when it comes to RAM usage, and I'm lazy.

From a modelling perspective, you're on the right track. Get one of Squad's texture that you think will be right, convert it the .png. I normally copy it over to where I'll have the blender file.

Make the model. Open the image up in the 'UV/Image Editor' window of blender. Now you can start UV wrapping directly over it (I'd google some tutorials for that; pressing 'u' while in edit mode should bring up the menu though, I tend to use a lot of project from view and cylinder unwrap). You can move the UV map around and just generally abuse it till you get something you're happy with it. Don't be afraid to fold things back over themselves and all that lark, there's an auto-update option that automatically updates the 3D view as you mess with the UV map.

WXFfPUP.png

Then throw it all into Unity and set it up there. Once you've export it, you can set up the .cfg to use Squad's textures, if you check some of the .cfgs in SXT you can see what I've done there.

Link to comment
Share on other sites

Nope, I just straight up use the stock textures; the 'textures' in the SXT folder are just 1x1 placeholders and then are swapped out using the cfg. It makes SXT essentially 'free' when it comes to RAM usage, and I'm lazy.

From a modelling perspective, you're on the right track. Get one of Squad's texture that you think will be right, convert it the .png. I normally copy it over to where I'll have the blender file.

Make the model. Open the image up in the 'UV/Image Editor' window of blender. Now you can start UV wrapping directly over it (I'd google some tutorials for that; pressing 'u' while in edit mode should bring up the menu though, I tend to use a lot of project from view and cylinder unwrap). You can move the UV map around and just generally abuse it till you get something you're happy with it. Don't be afraid to fold things back over themselves and all that lark, there's an auto-update option that automatically updates the 3D view as you mess with the UV map.

http://i.imgur.com/WXFfPUP.png

Then throw it all into Unity and set it up there. Once you've export it, you can set up the .cfg to use Squad's textures, if you check some of the .cfgs in SXT you can see what I've done there.

Thanks for the technology! I'll try it soon. But i noticed some of the parts (like Mk 3 Cockpit) have spaces in their texture names. Do they work fine with this method or require some modification?

Link to comment
Share on other sites

Thanks for the technology! I'll try it soon. But i noticed some of the parts (like Mk 3 Cockpit) have spaces in their texture names. Do they work fine with this method or require some modification?

Hmmm, I hadn't considered that. I would suggest just seeing if it works, I suspect that it'll ignore the spaces and will be alright.

If it doesn't, then you could just keep the texture in the same folder as the .mu when it's exported from Unity (instead of doing what SXT does), but I'm not really sure if redistributing one of Squad's textures with the part is allowed. EDIT: Looking at this, seems like that should okay as it's within the GameData folder.

Edited by Lack
Link to comment
Share on other sites

Thanks, I think I'll do my texturing a bit later. And then, sorry once again for my stupidity, I have another question. My service module seems to work quite good, but the effects are completely out of hand:

http://imgur.com/a/8MBz4#0

How do i fix that?

Config is:


PART
{

name = aeria_sm
module = Part
author = Niemand303

mesh = aeria_sm.mu
scale = 1

node_stack_bottom = 0.0, -0.6, 0.0, 0.0, 1.0, 0.0, 1
node_stack_top = 0.0, 0.135, 0.0, 0.0, 1.0, 0.0, 1

TechRequired = advRocketry
entryCost = 930
cost = 930

category = Propulsion
subcategory = 0
title = Aeria SM Mk 2
manufacturer = MOSOI Industries
description = Placeholder

attachRules = 1,0,1,1,0

EFFECTS
{
running_closed
{
AUDIO
{
channel = Ship
clip = sound_rocket_spurts
volume = 0.0 0.0
volume = 1.0 1.0
pitch = 0.0 0.2
pitch = 1.0 1.0
loop = true
}
PREFAB_PARTICLE
{
prefabName = fx_smokeTrail_aeroSpike
transformName = smokePoint
emission = 0.0 0.0
emission = 0.05 0.0
emission = 0.075 0.25
emission = 1.0 1.25
speed = 0.0 0.25
speed = 1.0 1.0
localOffset = 0, 0, 1
}
MODEL_MULTI_PARTICLE
{
modelName = Squad/FX/exhaustFlames_blue
transformName = thrustTransform
emission = 0.0 0.0
emission = 0.05 0.0
emission = 0.075 0.25
emission = 1.0 1.25
speed = 0.0 0.5
speed = 1.0 1.2
}
}
engage
{
AUDIO
{
channel = Ship
clip = sound_vent_soft
volume = 1.0
pitch = 2.0
loop = false
}
}
flameout
{
PREFAB_PARTICLE
{
prefabName = fx_exhaustSparks_flameout_2
transformName = smokePoint
oneShot = true
}
AUDIO
{
channel = Ship
clip = sound_explosion_low
volume = 1.0
pitch = 2.0
loop = false
}
}
}

MODULE
{
name = ModuleEnginesFX
engineID = Aeria_SM
runningEffectName = running_closed
thrustVectorTransformName = thrustTransform
exhaustDamage = True
ignitionThreshold = 0.1
minThrust = 0
maxThrust = 75
heatProduction = 400
fxOffset = 0, 0, 0
PROPELLANT
{
name = LiquidFuel
ratio = 0.9
DrawGauge = True
}
PROPELLANT
{
name = Oxidizer
ratio = 1.1
}
atmosphereCurve
{
key = 0 360
key = 1 320
}

}

RESOURCE
{
name = LiquidFuel
amount = 90
maxAmount = 90
}

RESOURCE
{
name = Oxidizer
amount = 110
maxAmount = 110
}

RESOURCE
{
name = MonoPropellant
amount = 100
maxAmount = 100
}



}

Link to comment
Share on other sites

stick with scale Factor of 1 for unity imports. There doesn't seem to be anything wrong with your config file.

You have 3 layers of scaling going from 3D app to Unity to KSP; the more you have at 1,1,1... the less chances of things going weird. I'd start with the Blender file, make sure all the objects are combined where possible, and all the scales reset to 1,1,1 or whatever blender equivalent is. check the model's size is correct, i.e. 2.5 blender units for 2.5m part; etc. Then export, and import to Unity at scale Factor 1. and go from there.

Link to comment
Share on other sites

stick with scale Factor of 1 for unity imports. There doesn't seem to be anything wrong with your config file.

You have 3 layers of scaling going from 3D app to Unity to KSP; the more you have at 1,1,1... the less chances of things going weird. I'd start with the Blender file, make sure all the objects are combined where possible, and all the scales reset to 1,1,1 or whatever blender equivalent is. check the model's size is correct, i.e. 2.5 blender units for 2.5m part; etc. Then export, and import to Unity at scale Factor 1. and go from there.

After testing I've found out the problem is not in the model, but in the particle effect, smoke fx works perfectly fine.

[EDIT] That's how it looks now:

QAkfP4e.jpg

Edited by Niemand303
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...