# How to Undo Collision Effects

**URL:** <https://forums.unrealengine.com/t/how-to-undo-collision-effects/273641>\
**Category:** Blueprint\
**Tags:** unreal-engine, question, UE4-27\
**Created:** [January 20, 2022, 3:48am UTC](https://forums.unrealengine.com/t/how-to-undo-collision-effects/273641 "2022-01-20T03:48:56Z")\
**Posts on this page:** 20\
**Page:** 4

<div class="post-metadata">

**Author:** ![CurleeD85](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@CurleeD85](https://forums.unrealengine.com/u/CurleeD85)\
**Post date:** [January 29, 2022, 8:23pm UTC](https://forums.unrealengine.com/t/how-to-undo-collision-effects/273641/65 "2022-01-29T20:23:56Z")

</div>

After doing some simulating, I found that the cubes don’t power the pipes or the water font or the goal cube when touching the half-pipe that connects to the rest. I tried setting the Lifetime number to a large number (500), and the program acts like those pipes are powered, even without any cubes touching the half-pipe.

---

<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:** [January 29, 2022, 9:18pm UTC](https://forums.unrealengine.com/t/how-to-undo-collision-effects/273641/66 "2022-01-29T21:18:18Z")

</div>

I’ll have a look at that tomorrow, but it’s probably because those other components are using the old system, no?

---

<div class="post-metadata">

**Author:** ![CurleeD85](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@CurleeD85](https://forums.unrealengine.com/u/CurleeD85)\
**Post date:** [January 29, 2022, 9:42pm UTC](https://forums.unrealengine.com/t/how-to-undo-collision-effects/273641/67 "2022-01-29T21:42:31Z")

</div>

Some were using the older system, so I got rid of the Boolean variables and the BP that used them. Then, I replaced those BPs with the newer ones that use the Lifetime integer. But okay. I appreciate the help, and sorry this has gone on for a long time.

---

<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:** [January 30, 2022, 8:44am UTC](https://forums.unrealengine.com/t/how-to-undo-collision-effects/273641/68 "2022-01-30T08:44:37Z")

</div>

Ok, you got it, good.

You’ll probably notice you have the same code in the pipe etc.

It doesn’t really matter, but the way around that is to use more blueprint inheritance.

You main cube parent would stay the same. Then you make a child of that called ‘conductor’, and put the code in there. But… no mesh.

Then inherit from that and make the cubes and pipes and put the meshes in. Like that.

Good luck ✌

---

<div class="post-metadata">

**Author:** ![CurleeD85](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@CurleeD85](https://forums.unrealengine.com/u/CurleeD85)\
**Post date:** [January 30, 2022, 6:01pm UTC](https://forums.unrealengine.com/t/how-to-undo-collision-effects/273641/69 "2022-01-30T18:01:12Z")

</div>

So, I would have to make a “conductor” child with the exact same BP as any objects that acquire power? What about objects that I want to be charged no matter what, such as the starting pipe and starting cube?

---

<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:** [January 30, 2022, 6:53pm UTC](https://forums.unrealengine.com/t/how-to-undo-collision-effects/273641/70 "2022-01-30T18:53:30Z")

</div>

I just thought of a much easier way.

For the main cube, just make the mesh set-able. So, the main parent doesn’t have a mesh set. Then you can set the mesh and in the children.

Cube mesh for the cubes, pipe for the pipes etc.

But don’t worry too much about it. If you want to try it out, make a copy of the project. If you can get it working there, then delete the first one and carry on with the new one.

---

<div class="post-metadata">

**Author:** ![CurleeD85](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@CurleeD85](https://forums.unrealengine.com/u/CurleeD85)\
**Post date:** [January 30, 2022, 11:57pm UTC](https://forums.unrealengine.com/t/how-to-undo-collision-effects/273641/71 "2022-01-30T23:57:34Z")

</div>

The reason I made pipes children to Cube\_BP was so that I could cast to any object that was a child to that shape. I tried making a base pipe entity and making pipe shapes as children, but I couldn’t get the program to cast to both Cube\_BP and pipe-related actors. So, I made the pipe actors related to Cube\_BP.

Also, are you basically saying I should recreate the newer BPs for the Cube\_BP actor so it is passed down to related actors?

---

<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:** [January 31, 2022, 7:56am UTC](https://forums.unrealengine.com/t/how-to-undo-collision-effects/273641/72 "2022-01-31T07:56:02Z")

</div>

You have the first part right. That fact that it’s called Cube… doesn’t matter, it’s the parent of everything, and you can always cast, correct.

All I’m saying is, the pipes and cubes can both be children without any duplication if you put the mesh in, one level later.

Also, it doesn’t really matter, it’s just to get rid of a double bit of code, I just thought you may have wondered about it 🙂

---

<div class="post-metadata">

**Author:** ![CurleeD85](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@CurleeD85](https://forums.unrealengine.com/u/CurleeD85)\
**Post date:** [January 31, 2022, 8:01am UTC](https://forums.unrealengine.com/t/how-to-undo-collision-effects/273641/73 "2022-01-31T08:01:12Z")

</div>

Alright. What about the start cube, which needs to be charged at all times? I could probably put in a Boolean condition to set it apart from the others.

---

<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:** [January 31, 2022, 8:03am UTC](https://forums.unrealengine.com/t/how-to-undo-collision-effects/273641/74 "2022-01-31T08:03:07Z")

</div>

No bools 🙂

There’s nothing wrong with the start cube. What sets it apart, is the fact that it’s the only one that contains the power generator code.

---

<div class="post-metadata">

**Author:** ![CurleeD85](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@CurleeD85](https://forums.unrealengine.com/u/CurleeD85)\
**Post date:** [January 31, 2022, 8:09am UTC](https://forums.unrealengine.com/t/how-to-undo-collision-effects/273641/75 "2022-01-31T08:09:52Z")

</div>

Oh, okay. So what I’ll probably do is recreate the Cube\_BP actor, create the children and put in the BPs from the latest screenshots. This is because none of the other cubes are powered when they touch the first metal cube. I think I did something wrong, so I will have to remake the BPs.

---

<div class="post-metadata">

**Author:** ![CurleeD85](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@CurleeD85](https://forums.unrealengine.com/u/CurleeD85)\
**Post date:** [February 1, 2022, 5:08am UTC](https://forums.unrealengine.com/t/how-to-undo-collision-effects/273641/76 "2022-02-01T05:08:53Z")

</div>

After recreating and comparing between the older and newer projects, I’ve started to wonder if an integer instead of a Boolean would really be helpful. The program still acts like metal cubes aren’t powered when they touch, and it acts like no pipes are powered, even if I put in the BPs using the Lifetime integer. Also, I put the Power Pulse event only in the Cube\_BP so that each actor would invoke Cube\_BP’s Power Pulse event. But nothing seems to work right. It’s like I always mess something up.

---

<div class="post-metadata">

**Author:** ![pezzott1](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/pezzott1/32/1215068_2.png) [@pezzott1](https://forums.unrealengine.com/u/pezzott1)\
**Post date:** [February 1, 2022, 2:45pm UTC](https://forums.unrealengine.com/t/how-to-undo-collision-effects/273641/77 "2022-02-01T14:45:17Z")

</div>

Hey, can’t really see the solution you guys are currently working on. Just wanted to pitch in with an idea in case it might help: how it works is binding the overlap event of each cube to an event that checks overlapping actors starting from power source. So on every begin / end overlap, they update in chain and those that are not found to be connected are automatically told to turn off.

[![](https://d3kjluh73b9h9o.cloudfront.net/original/4X/3/f/b/3fb77cf91f2f8acfee035f714ecf316ba1b5b166.jpeg "Overlapping Power Cubes") ](https://www.youtube.com/watch?v=ZiykF-9miTs)

* * *

> **[Nested Loops for chained overlaps posted by pezzott1 | blueprintUE | PasteBin...](https://blueprintue.com/render/_-5y1mbb/)**
>
> No description provided

Just keep note that the last 2 for each loops can be done in 1 loop without casting or the branch. I’ll update it later 😬.

---

<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:** [February 1, 2022, 6:57pm UTC](https://forums.unrealengine.com/t/how-to-undo-collision-effects/273641/78 "2022-02-01T18:57:11Z")

</div>

It works perfectly for me, but you guys seems to get different ideas that don’t pan out 😉

I can fix it one more time, but then that’s I’m afraid 🙂

And I won’t be able to do it until the weekend now.

Send me another link if you need it.

---

<div class="post-metadata">

**Author:** ![CurleeD85](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@CurleeD85](https://forums.unrealengine.com/u/CurleeD85)\
**Post date:** [February 1, 2022, 7:56pm UTC](https://forums.unrealengine.com/t/how-to-undo-collision-effects/273641/80 "2022-02-01T19:56:53Z")

</div>

I must have gotten some of the BP screenshots mixed up, too. Anyway, I’ll try sending the .zip file hopefully the last time.

Anyway, here is the link: [MyProject10.zip - Google Drive](https://drive.google.com/file/d/1BkbTmv4Hoxtp75wvuR5-g-cYEajzzEtx/view?usp=sharing)

---

<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:** [February 1, 2022, 8:31pm UTC](https://forums.unrealengine.com/t/how-to-undo-collision-effects/273641/81 "2022-02-01T20:31:32Z")

</div>

I will fix it and give you link, at the weekend… 👌

---

<div class="post-metadata">

**Author:** ![CurleeD85](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@CurleeD85](https://forums.unrealengine.com/u/CurleeD85)\
**Post date:** [February 1, 2022, 8:42pm UTC](https://forums.unrealengine.com/t/how-to-undo-collision-effects/273641/82 "2022-02-01T20:42:49Z")

</div>

Okay. I appreciate your help, and sorry this has gone on for a long time.

---

<div class="post-metadata">

**Author:** ![CurleeD85](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@CurleeD85](https://forums.unrealengine.com/u/CurleeD85)\
**Post date:** [February 1, 2022, 8:48pm UTC](https://forums.unrealengine.com/t/how-to-undo-collision-effects/273641/83 "2022-02-01T20:48:44Z")

</div>

In the meantime, I’ll see if I can figure anything out on my end.

---

<div class="post-metadata">

**Author:** ![CurleeD85](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@CurleeD85](https://forums.unrealengine.com/u/CurleeD85)\
**Post date:** [February 2, 2022, 3:37am UTC](https://forums.unrealengine.com/t/how-to-undo-collision-effects/273641/84 "2022-02-02T03:37:30Z")

</div>

I meant to say earlier that I wasn’t sure about using integer variables in this project because the Lifetime integer acted like a timer, meaning the power would be lost after the Lifetime number reaches 0. I figured this out after playtesting and examining the BP for each actor. I blame frustration and fatigue for not expressing myself better, last night. That was why I considered a Boolean variable, so I could set those variables to “true” or “false.” How would an integer variable work in the same scenario?

---

<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:** [February 2, 2022, 2:29pm UTC](https://forums.unrealengine.com/t/how-to-undo-collision-effects/273641/85 "2022-02-02T14:29:56Z")

</div>

The lifetime integer get refreshed 10 times a second, so it won’t run out 🙂

Bools won’t work, you will get loops, because a given cube can’t tell where the power came from.

[Previous page](https://forums.unrealengine.com/t/how-to-undo-collision-effects/273641.md?page=3)

[Next page](https://forums.unrealengine.com/t/how-to-undo-collision-effects/273641.md?page=5)
