> For the complete documentation index, see [llms.txt](https://scripting.breeze.rip/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://scripting.breeze.rip/api/namespaces/math.md).

# math

The math namespace, the same helpers breeze uses internally for tick interpolation, clamping and visibility checks.

### Remarks

Entity positions only move once per tick. Anything you draw in a render event should use the interpolated variants here, otherwise it will visibly stutter.

### Example

```ts
script.addListener("Render3DEvent", (event) => {
  if (mc.pointedEntity === null) return;
  const box = math.interpolateEntityBB(mc.pointedEntity, event.getPartialTicks());
  renderer.boundingESPBox(box, new Color(255, 0, 0), 2, false);
});
```

### Functions

* [clamp](/api/functions/math.clamp.md)
* [findBestVisiblePoint](/api/functions/math.findbestvisiblepoint.md)
* [getCenter](/api/functions/math.getcenter.md)
* [interpolateEntityBB](/api/functions/math.interpolateentitybb.md)
* [interpolateEntityPosition](/api/functions/math.interpolateentityposition.md)
* [interpolateLastTickPos](/api/functions/math.interpolatelasttickpos.md)
