[Begginer Question] Two blueprints decompile each other

I’m trying to create a map where I will randomly generate a course on which my character will go on, something like an endless runner. However my game mode and my main floor tile decompile each other and therefore the game isn’t playable. On the main floor tile I attached an arrow which is called AttachPoint and my idea was to have a function which will tell the engine where the arrow was at every moment so that it knows where to put the next tile.
I did a little research and I believe that an infinite loop is created in either game mode or in the floor tile blueprint and therefore an error pops up every time I try to play the game.
As the title says, I’m new to all this and could really use some help.Do you have any idea what the problem is and how to solve it? Thanks in advance!

I had that problem too. I got around it by changing direct casts to using interfaces instead. If everything implements the interface you can call it directly without casting. My problem was so bad (UE4.6) that it would crash while starting the editor. Fortunately after using interfaces I haven’t had any problems.

Oh and by the way if you’re going to have 100 types of floor tiles interfaces remove the requirement of casting to each and every single one of them.

Thank you so much for the answer however, could you be more specific on what to do exactly. As I said, I’m new with this and don’t really understand what you meant by interfaces instead of direct cast. Thank you!!

An interface is a common function between classes. You may want to check out EPIC’s channel and look for their blueprint tutorials.

To make one click
add new->blueprints->blueprint interface

At this point you will be able to make a collection of empty functions. Make the functions with the appropriate inputs but don’t worry about them being essentially blank. Go ahead and hit compile. You can even close it if you want.

Open one of the classes. Be careful about having functions with the same name as the functions in the interface. It can get complicated if you do. Go to class settings and look for the interfaces section. Click add and select your new interface. Its probably a good idea to compile as sometimes its hard to continue unless you do.

For any function that returns a value, it should appear as a function and you can set it up to return the proper value. For everything else, you will create a new event if you start typing the name of the function. It should appear as an event. Connect the event to whatever you need.

Once you need to call something else you’ll use a function call. You’ll want to drag off the actor you need to call this function on. Start typing the name of the function and you should see a call for that function. The target will be the other actor.

You can make this call on any actor that uses the interface. If it supports the interface it will work as long as the event/function is hooked up. If it doesn’t support the interface then it will simply ignore it.

Check this out. It includes some screenshots that show interfaces in use.

Thank you so much!!