I got everything working so far. The first Panel (1x1) switches the material according to what owner it has (0 = none, 1 = Circle, 2 = X) so generally my Blueprint is working.
What I wanted to do know is put that functionality on every single panel in the blueprint. So I took my existing Blueprint and converted it to a macro so I can reuse it for every panel. The important parts of the macro look like this:
The yellow line represents what connection I need. It basically checks what value the panel variable (for example 1x1) has and changes the material accordingly on the panels specific mesh (in this case of course 1x1).
So the main Blueprint looks like this:
Now, all I want to do is input the Static Mesh Component into each Macro so I can use it like I showed in the second picture. The problem is that the two types seem to be incompatible. Depending on what I set the macro input to I can either not input it into the macro at all or I can input it into the macro but the “Set Material” nodes inside the macros cannot use it.
So, how do I solve that? I’m sure it’s pretty easy but I cannot get behind it…
I removed the panels from the playfield Blueprint. They are now seperate, own Blueprints that will be referenced via object variable in the playfield Blueprint. It works as intended now! Now I just have to find a way to make the rules actually apply on the panels. Right now I have no idea how to solve it
That is the simplest way to do it sure, but you should have been able to do it within the 1 blueprint pretty easily.
Figuring out the actual “win/lose conditions” is a bit of a trickier 1. You will want to do a few loops checking what their partner is in each direction and if you get 3 in the 1 direction than you win. Which is why having them in a single blueprint would actually be easier for this but you could just pass the variables over to the level or gamemode blueprint