Jump to content

Part dont show up in KSP


Recommended Posts

Hello,

this is my first Part. I tried to Import it several times with several tutorials. the first tutorial i followed was outdated and from MCsheppard. so i watched the series from nifty255.

I tried to create a part some month ago with sketchup and it was showing up ingame but i dont know wich tutorial i was watching back then.

so i created my Object in Sketchup and exportet it to Blender via .obj. Created an Collision Mesh and named it node_collider. added a UV texture and exported it as .dae.

set up Unity with Part tools. Imported the Model. create a Empty gameobject. dragged my object into this set the UV maps as ksp/diffuse added a mesh collider component to the node_collider model set normals and tangends to calculate. so i set up everything like nifty255 in unity. then i exported. i have now my model.mu + texture.mbm and used a config file from an existing mod and changed the

// --- asset parameters ---

to

MODEL

{

model = model.mu

the part.cfg is a simple fuel tank one from an existing 0.90 Mod. with no fancy animations or other modules.

my folder layout:

Gamedata->

FirstObject->

Part->

Testobject->

model.mu

part.cfg

texture.mbm

I tried it like 10 times now and the object is nowhere. I even tried to change the categoriy in the .cfg file to utillity, sience, structural.

I followed every step in Niftys Tutorial and it is not working. i just cant find the object.

The last time some month ago i tried it worked on the first try.

I even tried to import straight from sketchup via.dae to unity but also this dont work.

Would be really nice if someone could help me out.

Link to comment
Share on other sites

i also tried this before and it doesnt show up. i mean the full path

but i will give it another try. just in case

Edit:

still not there. tried both variants...

i´have made a imgur album with my unity and .cfg settings

http://imgur.com/a/5rJt7

Kermany uh? :)

Edit2:

i used a stock Part.cfg and now it is appearing. but once placed i cant grab it...

i use the KSP Node Converter and set up the nodes in the .cfg file. (from an xenon gas tank) and just the bottom node is appearing.

Edited by Nupol
Link to comment
Share on other sites

You might want to check the log and see what error is being thrown. Lots of things can cause the part not to load.

But the "MODEL { mesh = something }" syntax always requires the full path. If you use just "mesh = something", the first ".mu" in the folder is used (actual file name is ignored), so it'll load even if you have a typo.

The #1 most common cause (IMHO) is not getting the full path right. But other weirdness can happen to. If you're going to use "MODEL", your "Scale" line needs to have a decimal (don't ask me why, no idea). That is, "Scale = 1.0", and not "Scale = 1".

EDIT: Oh, now I'm seeing your last edit. Yes, if you can't grab it, then the collider isn't set up right. Make sure you have a collider configured in Unity, whether it's a Unity collider, or a mesh collider. If it's a mesh that you've imported, it may help to check "convex".

Link to comment
Share on other sites

You have to use "mesh" without the MODEL{} brackets

MODEL

{

mesh = model.mu <--- just this

}

You cannot grab your part because your collider isn't set up right, you have to give it a mesh collider component, (Add component, Physics, Mesh collider) don't forget to tick 'convex'

Your attachnodes look correct to me, but concentrate on the more severe problems first and see if this persists.

Link to comment
Share on other sites

MODEL{} uses "model = " line. "mesh =" is if you are not using MODEL{}. don't mix the two.

add "mesh collider" component to your node_collider object (click on Add Component and start typing mesh); check "Convex"; make sure the mesh field in the collider component says "node_collider"; then remove the (Mesh Filter) component. you'll see a green outline of the collider if you have it set up correctly. all collider components are color coded with light green icons.

Link to comment
Share on other sites

oh was about to close this thread right now..

and opened another one. I hope the Admin dont hate me right now. :)

Thank you porkjet. the convex tick was it.

Blender:

top face:

X:0

Y:25cm

Z:0

KSP Node Converter output:

node_stack_top = 0, 0, 25, 0, 1, 0, 1

bottom face:

X:0

Y:0

Z:0

KSP Node Converter output:

node_stack_bottom = 0, 0, 0, 0, 1, 0, 1

and still just the bottom node appearing.

And thank you guys for the fast reply i really appreciate it. great community

Link to comment
Share on other sites

top face:

X:0

Y:25cm

Z:0

KSP Node Converter output:

node_stack_top = 0, 0, 25, 0, 1, 0, 1

bottom face:

X:0

Y:0

Z:0

KSP Node Converter output:

node_stack_bottom = 0, 0, 0, 0, 1, 0, 1

and still just the bottom node appearing.

The problem here is that Blender switches Z and Y compared to unity, plus your mesh has it's top face at 25cm, not 25m (which is what it is in the cfg). Your node should look something like this:

node_stack_top = 0, 0.25, 0, 0, 1, 0, 1

edit: oh, and you probably shouldn't have your bottom face at 0,0,0. That means that it is the center of the part, and can lead to some weird behaviors when spinning. If you just went into edit mode in Blender, selected the entire mesh, and set the Z value to zero that should center it. Of course you'd have to find the top/bottom coordinates again.

Edited by StarVision
Link to comment
Share on other sites

I modeled my Object in sketchup and imported it to Blender as .obj. The whole object in Blender is right. axis are in the middle and the coordinates are X:0 Y:12.5 Z:0. but in Sketchup i started modeling from the axis and upwards. maybe the bottom face still uses the axis from Sketchup?

Edit: node_stack_top = 0, 0.25, 0, 0, 1, 0, 1 moves the nodes to the side. (my fault just changed the number. Node calculator placed the value behind the first two zeros.)

Edit2: node_stack_top = 0, 0.5, 0, 0, 1, 0, 1 did the trick for me.

0.5 and 1m parts in KSP have all 24 sides is that right? so the chart from mcshepperd is also not right with the 18 faces for 0.5 eg?

I still dont get it why the KSP Node Calculator. that was oviously programmed for blender gives me

node_stack_top = 0, 0, 0.25, 0, 1, 0, 1

instead of

node_stack_top = 0, 0.25, 0, 0, 1, 0, 1

Edited by Nupol
Link to comment
Share on other sites

once you've imported in to Unity, don't worry about blender axis. set the markers to Pivot/Local; top left in this screen http://i.imgur.com/V0ylOJD.jpg. then look at the XYZ positions as guide to place your stack nodes.

based on that image, your top and bottom stack nodes should be around 0, 0.13, 0; and 0, -0.13, 0 respectively.

Link to comment
Share on other sites

Pivot / Center doenst change a thing inside the Coordinates (tried gameobject and model preferences) or i just dont get what you mean :)

node_stack_top = 0, 0.5, 0, 0, 1, 0, 1

node_stack_bottom = 0, 0, 0, 0, 1, 0, 1

thats how my .cfg looks now and the nodes perfect but i get what you mean that the center should be in the middle.

I will move the model in sketchup down so that the axis are in the middle. because in blender the axis is on the bottom face.

Edited by Nupol
Link to comment
Share on other sites

Pivot / Center doenst change a thing inside the Coordinates (tried gameobject and model preferences)

that just means your mesh is perfectly symmetrical, and the pivot from blender, or where ever else, was centered before you exported to Unity. that's good thing.

according to your node positions and screenshots: your part is 0.5m tall, and your part's CoM is at +0.134Y; about 1/4th way up from bottom. your nodes should be 0,0.25,0; and 0,-0.25,0 respectively, which is what you really want to have.

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