

def attach_physics_node(self, physics_node_name=DEFAULT_PHYSICS_NODE_NAME, physics_model=DEFAULT_PHYSICS_MODEL_NAME, node_name=DEFAULT_NODE_NAME, inline_parameters=None):
    'Attach a physics node to the JSON representation.'
    assert isinstance(node_name, NodeName)
    physics_node = {
        'body': physics_model,
        'target': str(node_name),
    }
    if (inline_parameters is not None):
        for (k, v) in inline_parameters.iteritems():
            physics_node[k] = v
    self.asset['physicsnodes'][physics_node_name] = physics_node

dataset/ETHPy150Open turbulenz/turbulenz_tools/turbulenz_tools/tools/asset2json.py JsonAsset.attach_physics_node/original