# Getting angles and direction on a spline?

**URL:** <https://forums.unrealengine.com/t/getting-angles-and-direction-on-a-spline/489728>\
**Category:** Rendering\
**Tags:** tangents, unreal-engine, Spline, question, Blueprint\
**Created:** [October 10, 2021, 6:05pm UTC](https://forums.unrealengine.com/t/getting-angles-and-direction-on-a-spline/489728 "2021-10-10T18:05:46Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Abraxas86](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Abraxas86](https://forums.unrealengine.com/u/Abraxas86)\
**Post date:** [October 10, 2021, 6:05pm UTC](https://forums.unrealengine.com/t/getting-angles-and-direction-on-a-spline/489728/1 "2021-10-10T18:05:46Z")

</div>

Hello Answer Hub!

I’m trying to build a procedural pipe system by using a Spline in a Blueprint actor. The pipes should not deform though, and I’d like to use Instanced Static Meshes to build the pipe. On the corners I’d like to add a bending (90 degrees) piece, and they need the correct rotation on them, obviously.

And for some reason I’ve hit the limits of my brain. because the pieces marked with squares (in the screenshot) have a **different angle setup between each other, but Blueprint is thinking they’re the same setup.**

- Leave: This is the Leave tangent on this spline point
- Direction: This is the direction the  
spline continues from

You can see more issues along the spline, but the problem seems to be the same.

Any ideas how I could solve this?

Thanks in advance!

 ![350143-spline-angles.jpg](https://d3kjluh73b9h9o.cloudfront.net/original/4X/a/c/5/ac52d84bdc3e6181e951ca71d2b0bdbe530b45c5.jpeg)

 ![350144-spline-setup.jpg](https://d3kjluh73b9h9o.cloudfront.net/original/4X/5/3/d/53d83982887af314902c940bc74c6f56f840a5c9.jpeg)

---

<div class="post-metadata">

**Author:** ![Abraxas86](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Abraxas86](https://forums.unrealengine.com/u/Abraxas86)\
**Post date:** [October 10, 2021, 6:14pm UTC](https://forums.unrealengine.com/t/getting-angles-and-direction-on-a-spline/489728/2 "2021-10-10T18:14:55Z")

</div>

Noticed I didn’t hook up the Directions correctly for the debug text. Fixed in the screenshot below.

 ![350147-spline-correction.jpg](https://d3kjluh73b9h9o.cloudfront.net/original/4X/e/2/5/e257260e901edb267d8638be6430597b69d9b2b5.jpeg)

---

<div class="post-metadata">

**Author:** ![ClockworkOcean](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/clockworkocean/32/1169999_2.png) [@ClockworkOcean](https://forums.unrealengine.com/u/ClockworkOcean)\
**Post date:** [October 10, 2021, 7:30pm UTC](https://forums.unrealengine.com/t/getting-angles-and-direction-on-a-spline/489728/3 "2021-10-10T19:30:21Z")

</div>

I think it’s probably because the engine arbitrarily decides to turn -180 into +180 and vice versa.

The usual solution ( I don’t know if you can get that to work here ), is to only work with relative differences. In your case that’s only 90.

---

<div class="post-metadata">

**Author:** ![HexLord2389534941](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@HexLord2389534941](https://forums.unrealengine.com/u/HexLord2389534941)\
**Post date:** [September 6, 2023, 5:58pm UTC](https://forums.unrealengine.com/t/getting-angles-and-direction-on-a-spline/489728/4 "2023-09-06T17:58:43Z")

</div>

@Abraxas86 did you ever figure this out, I’m having the same sort of issues
