Nodes
Nodes
Nodes are the core of BeamNG physics. Everything revolves around these mass points. A node itself is a dimensionless (infinitely small) mass point in 3D space. Each node is a list of four values, corresponding to the header at the top of the nodes section. Nodes can have any string for their name, as long as the names do not conflict. A good naming scheme is some memorable/relevant letter, followed by a number, followed by a letter signifying which side of the vehicle it's on. For example, the 1st rightmost frame node would be called "f1rr" while the 3rd left frame node would be called "f3l". A node sitting in the middle (posX = 0) would have no letter suffix.
This is an example of a nodes section. Nodes also have many properties which can be set by placing dictionary lines above the nodes which are desired to be affected. Node weights are in kilograms, and coordinates are in meters. The "group" modifier is for assigning flexbodies. Node material only affects sound and particle properties, not physics.
Arguments
Name | Type | Optional | Default Value | Description |
---|---|---|---|---|
id | n/a | defines the node name | ||
posX | n/a | The X (left/right) position in 3D space | ||
posY | n/a | The Y (forward/back) position in 3D space | ||
posZ | n/a | The Z (up/down) position in 3D space | ||
nodeWeight | options.nodeWeight | The weight of the node in kg | ||
collision | true | If the node can collide with the world | ||
selfCollision | false | If the node can collide with the vehicle | ||
group | n/a | Groups a select set of nodes into a group | ||
frictionCoef | 1.0 | Friction of the node | ||
nodeMaterial | options.nodeMaterial | Material of the node, rubber, metal, etc. | ||
fixed | false | If the node is fixed (Can't move at all) | ||
surfaceCoef | 32px | 0.1 | Makes a node have more or less drag area in ground models with depth | |
volumeCoef | 32px | 0.1 | Makes a node more or less buoyant in ground models with depth | |
pairedNode | 32px | null | This can be used to i.e. link double tires together |
Generated Options
- cid
- creator
- name
- type
- pairedNode
Simple Example
"nodes" :[ ["id", "posX", "posY", "posZ"], ["n1rr", -0.90, -0.93, 0.23], ],
Advanced Example
"nodes" :[ ["id", "posX", "posY", "posZ"], {"group":"body"}, {"selfCollision":false} {"collision" :true} {"nodeMaterial":"|NM_METAL"}, {"frictionCoef":0.7}, {"nodeWeight":12.5}, //a comment ["n1rr", -0.90, -0.93, 0.23], ["n1r", -0.33, -0.95, 0.23], ["n1l", 0.33, -0.95, 0.23], ["n1ll", 0.90, -0.93, 0.23], {"group":""}, ],
Nodes can also be assigned to multiple groups on an individual basis, as per the following example:
["f6ll", 0.76, -0.72, 0.83{"group":["coupe_engine_bay","coupe_windshield"]}],
Vehicle Creation | ||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Get started: Introduction to Vehicle Creation | ||||||||||||||||
| ||||||||||||||||
See also: JBeam Examples • JBeam Physics Theory |