Jump to content

Model Textured in Unity, not in KSP


Recommended Posts

Starting to lose my mind here. I can't seem to get a textured object into KSP

* I made an object in Blender, textured it. Then exported it as an .fbx file.

* Then made a new project in Unity, added the parttools.

* Imported the .fbx and the texture.

* Assigned the texture to a material

* assigned the material to the model.

* Added a collision mesh

* Exported the model/texture as .mu and .tga

* Wrote the config file, double check that the texture and the .mu are correctly referenced.

* Then I go to KSP, I can see the part, it's untextured.

I am at a loss. Been looking at tutorials all day, and I can't seem to solve this.

Screenshot in Unity:

YgR0eRm.png

Screenshot in KSP:

xj15RwG.png

Part config:


// Test part for KSP

PART
{
// Basic information
name = 1mAdapter
module = Part
author = Snarfster

mesh = 1mAdapter.mu
rescaleFactor = 100
PhysicsSignificance = 1
texture = 1mAdapter.tga

node_stack_top = 0.00, 0.00, 0.00, 0.0, 1.0, 0.0, 0
// node_stack_bottom01 = 0.00, 0.00, 0.25, 0.0, 1.0, 0.0, 0
// node_stack_bottom02 = 0.00, 0.05, -0.25, 0.0, 1.0, 0.0, 0

// attachment rules: stack, srfAttach, allowStack, allowSrfAttach, allowCollision
attachRules = 1,0,1,1,0

// --- editor parameters ---
cost = 500
category = Structural
subcategory = 0
title = 1m (2x0.5) Adapter
manufacturer = Snarfster's Test Agency
description = Connect two 0.5 metre modules to a 1 metre diameter stack.

// Standard part parameters
mass = 0.1
dragModelType = default
maximum_drag = 0.2
minimum_drag = 0.2
angularDrag = 1
crashTolerance = 12
maxTemp = 3300
}

Any help or suggestions would be highly appreciated as my caffeine level is starting to get unhealthy. ;)

Link to comment
Share on other sites

In addition to that your workflow doesn't look familiar at all, specifically how you're doing things in Unity.

1. You don't need to export fbx. If your model is unwrapped, and has a single material in Blender, you can just drag and drop fhe model from the Assets window, after expanding the blend file.

2. When you have your model in the scene, drag the texture onto it.

Link to comment
Share on other sites

The reason I export to fbx is that I had an issue importing blend files.

I use Linux and Unity via wine. Unity attempts to use blender to automatically convert the blend to fbx in the background. (it will actually complain about no (windows) blender being available to import.)

Going to give it another try with a new basic model.

Link to comment
Share on other sites

Small update

Made a new model and then checked the log.

[WRN 10:32:06.990] PartLoader: Cannot replace model texture with 'Snarfster/Parts/Crate/textures/Crate'

So it seems it's a path issue

- - - Updated - - -

Another update, the error above was because I didn't have enough coffee...

It works now. No clue what's wrong with the initial test though.

cqmIMrN.png

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...