Jump to content

[Partially Solved] New Node System - Unable to get it working


Recommended Posts

Hola folks~ Been cooking up some parts, and had, up until now, been using the tried and trusted method of defining attachment nodes, but with the release of the .20 PartTools, I figured I'd give the new system a shot. To no success.

As many of you may have seen, the new system apparently works by adding these lines to the configs:


ATTACH
{
name = top
transformName = myTopTransform
}
ATTACH
{
name = srfAttach
transformName = mySrfAttachmentTransform
}

And this provides no results at all. A user by the name of Razchek had apparently come across a solution:

To get the attachment nodes to work you must place them in your config like so:

NODE
{
name = top
transform = topTransform // Or whatever your transform name is.
size = 1.0 // Will always be 0 until fixed.
method = FIXED_JOINT // will always be FIXED_JOINT until fixed.
}

Original post suggests:

ATTACH
{
name = top
transformName = topTransform
}

Size and Method are not being respected, so they will just be place-holders until it's fixed in the AttachNode class.

Place the transform (empty game object) in unity so that the blue arrow is facing away from the point you want to attach to.

I.e. Have the blue arrow facing down if the node is at the top of your model so that you can stack objects on top of your object.

The key term in the statement above is how the node is instead defined as 'NODE' as opposed to 'ATTACH', so I gave that a whirl instead, and was thus met with KSP hanging on my part during loading. Replacing NODE with ATTACH loaded the part, but not the attachment points it would seem.

So my questions to you chaps are:

-Has anyone gotten this working yet?

-How did you go about doing so?

Thanks for your time, and any help would be greatly appreciated~ c:

Update: I've gotten Stack Nodes working, turns out I had the transforms in the wrong place in the hierarchy. NODE is in fact the correct statement to use, rather than ATTACH. The only thing I haven't gotten to work are Surface Attachment Nodes, even using what I assume is the correct syntax, and the correct hierarchy placement, it's not working.

http://forum.kerbalspaceprogram.com/showthread.php/34555-Anyone-got-the-new-0-20-attachment-nodes-working-yet

Going by this thread, I'm of the opinion that the new system is a little broken, thus I'm just gonna stick with the older system, which works without a hitch.

Edited by Pezzhippo
Partially Solved
Link to comment
Share on other sites

Aye, that's something I garnered from Razchek's post, but still no joy even with things properly oriented. My config itself looked like this (NODE and ATTACH are interchangeable, I tried both):


NODE/ATTACH
{
name = top
transform = Attach01
size = 1.0
method = FIXED_JOINT
}
NODE/ATTACH
{
name = bottom
transform = Attach02
size = 1.0
method = FIXED_JOINT
}
NODE/ATTACH
{
name = srfAttach
transform = SrfAttach
size = 1.0
method = FIXED_JOINT
}

I placed these snippets in the config where the old node system used to be located, I'm wondering if that's an issue.

Link to comment
Share on other sites

You can eliminate size and method for the time being as they won't do anything. try using my example below. Be sure to name your empty game object 'bottom' When I create mine I nest both the model and the empty game object under the same parent.

NODE

{

name = top

transform = bottom

}

Link to comment
Share on other sites

I should have elaborated a bit more on the new nodes. :)

Node rules (as of 0.20.2):

1. The node transform must be in the hierarchy of the PartTools object in Unity (just place it as the child of the part tools game object for simplicity and performance).

2. The Z axis (blue arrow) must point inwards to your part. (much better wording sirkut, thanks :D) I.e. away from the planned attach-part.

3. The size & method fields are not respected and will not be used in 0.20.2 (and size is a whole number (int32); so my bad on putting 1.0 in the post, i'll fix that lol, should be either 0, 1 or 2 in the future).

4. The 'node' section title must be "NODE" and not "ATTACH".

5. Surface attach nodes may not work (because the joints are forced as FIXED_JOINT when they should be HINGE_JOINT). They will break any existing attach nodes from actually setting the part connected.

I usually put the NODE{} just above my first MODULE{} or, if no modules, at the bottom of the part config when making config files. :)

Edited by Razchek
Link to comment
Share on other sites

  • 1 month later...

I'm doing this but when it is set to NODE the part and anything after it do not even load.

Here's the pertinant code...

NODE
{
name = top
transformName = nodeConnect
size = 3
}
NODE
{
name = left
transformName = nodeWheelLF
size = 1
}





NODE
{
name = left01
transformName = nodeWheelLR
size = 2
}

NODE
{
name = left02
transformName = nodeWinL
size = 2
}

NODE
{
name = right
transformName = nodeWheelRF
size = 1
}

NODE
{
name = right01
transformName = nodeWheelRR
size = 1
}

NODE
{
name = right02
transformName = nodeWingR
size = 2
}

ATTACH
{
name = srfAttach
transformName = nodeConnect2
size = 3
}

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