# Set Cable Component Number of Segments from blueprint?

**URL:** <https://forums.unrealengine.com/t/set-cable-component-number-of-segments-from-blueprint/581887>\
**Category:** Blueprint\
**Tags:** unreal-engine, UE5-0, Components, question\
**Created:** [June 14, 2022, 5:40pm UTC](https://forums.unrealengine.com/t/set-cable-component-number-of-segments-from-blueprint/581887 "2022-06-14T17:40:01Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![BlazingLyric80](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@BlazingLyric80](https://forums.unrealengine.com/u/BlazingLyric80)\
**Post date:** [June 14, 2022, 5:40pm UTC](https://forums.unrealengine.com/t/set-cable-component-number-of-segments-from-blueprint/581887/1 "2022-06-14T17:40:01Z")

</div>

Hello everyone!

I’m working with a simulation that requires cable components to be dynamically created. One issue that I’m running into is that there does not seem to be a node that allows you to modify a cable component’s number of segments.

Ideally, I would like to modify the segment number based on the size of rope spawned (ex: # of segments is the length / 10). This only needs to occur during the initialization of a cable. Once the number of segments is set, that is the number until the cable is destroyed. Is this a missing feature, or am I going about this wrong?

Thanks!

---

<div class="post-metadata">

**Author:** ![Astrotronic](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/astrotronic/32/1194566_2.png) [@Astrotronic](https://forums.unrealengine.com/u/Astrotronic)\
**Post date:** [June 14, 2022, 6:09pm UTC](https://forums.unrealengine.com/t/set-cable-component-number-of-segments-from-blueprint/581887/2 "2022-06-14T18:09:20Z")

</div>

Hello Alex Fries,

Good question, I checked, and also found that this was absent:

 ![cableSET](https://d3kjluh73b9h9o.cloudfront.net/original/4X/c/1/2/c126ca2f0aa31db8bbeb3f2782166a692cac4633.png)

I checked the cable component code, and found that NumSegments is set to ‘BlueprintReadOnly’ (as opposed to BlueprintReadWrite)

```auto
	/** Rest length of the cable */
	UPROPERTY(EditAnywhere, BlueprintReadWrite, Category="Cable", meta=(ClampMin = "0.0", UIMin = "0.0", UIMax = "1000.0"))
	float CableLength;

	/** How many segments the cable has */
	UPROPERTY(EditAnywhere, BlueprintReadOnly, Category="Cable", meta=(ClampMin = "1", UIMin = "1", UIMax = "20"))
	int32 NumSegments;

```

So at this point you may be able to create your own CPP cable component with that change. (I don’t THINK you’d need to compile a custom version of the engine to change this) And then again, maybe there is a good reason why NumSegments is ReadOnly.

Cheers!

---

<div class="post-metadata">

**Author:** ![BlazingLyric80](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@BlazingLyric80](https://forums.unrealengine.com/u/BlazingLyric80)\
**Post date:** [June 16, 2022, 7:34pm UTC](https://forums.unrealengine.com/t/set-cable-component-number-of-segments-from-blueprint/581887/3 "2022-06-16T19:34:37Z")

</div>

Yep! That would do it!

I did, in fact, have to rebuild the engine from scratch. I’ve tested it very little, but it does work!

Thanks for pointing it out!

---

<div class="post-metadata">

**Author:** ![Perb10](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Perb10](https://forums.unrealengine.com/u/Perb10)\
**Post date:** [March 5, 2024, 10:21am UTC](https://forums.unrealengine.com/t/set-cable-component-number-of-segments-from-blueprint/581887/4 "2024-03-05T10:21:01Z")

</div>

I try it out and when I change the NumSegments at runtime it crashes. So for me it does not work.

---

<div class="post-metadata">

**Author:** ![bigbewky](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@bigbewky](https://forums.unrealengine.com/u/bigbewky)\
**Post date:** [September 2, 2025, 10:15pm UTC](https://forums.unrealengine.com/t/set-cable-component-number-of-segments-from-blueprint/581887/5 "2025-09-02T22:15:20Z")

</div>

can confirm it crashes when setting NumSegments
