Destroying the Component of an Actor

Hey! I’m trying to make it so I can destroy the cube and box in this blueprint when the player can turn. I want to make it so that once I add a second cube to the blueprint, it isn’t destroyed along with the green cube. I attempted two different methods but neither seem to work.

.

There is a strong misuse of reference pins here. You need to think of each event as its isolated block of knowledge. If you are dragging in a blue ref pin from another event that executes logic, that reference will be invalid.

In the cube bp, The “E” will not fire because that cube is not possessed by your player controller.

In your first photo, the W event is the closest to working. Get rid of the cast before the Get Actor of Class, this cast is where its failing to continue down execution, the cast always fails because your reference is from another piece of logic that isn’t executed in that chain of logic. When you Get Actor Of Class you are grabbing the first actor provided of that class, you are already in scope of the context of that actor so there is no need to cast afterwards.