add_nearly_equal_float_node
Add a NearlyEqual float node to a Blueprint to compare floats with a tolerance, preventing precision errors in equality checks.
Instructions
Add a NearlyEqual (float) node to compare floats with tolerance.
From Ch. 11: Used to check if PlayerHealth is approximately 0 (player dies). Float comparison with == can fail due to floating-point precision, so NearlyEqual checks if |A - B| < Tolerance instead.
Args: blueprint_name: Blueprint to add the node to tolerance: Maximum allowed difference for equality check node_position: [X, Y] graph position
KB: see knowledge_base/01_BLUEPRINT_FUNDAMENTALS.md#overview Example: add_nearly_equal_float_node(blueprint_name="/Game/MCP_Test/BP_Example")
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"blueprint_name": "<blueprint_name>"
},
"name": "add_nearly_equal_float_node"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| tolerance | No | ||
| node_position | No | ||
| blueprint_name | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |