You can work with scripts to some extent, check out the "ScriptControl" category in your action list.
Back to doing it all in Playmaker though, as you've got a very specific building location with a finite grid area I'd consider getting creative with how you lay down sections.
I've attached an image to try to illustrate how I'd begin approaching this.
I'd begin by creating an empty game object (Foundation Marker) at the center of each grid square and another empty game object (Edge Marker) on each edge within the grid. I'd then create two FSM templates in Playmaker, one called "Foundation Data" (add an FSM with this template to each Foundation Marker) and another "Edge Data" (add an FSM with this template to each Edge Marker), inside these FSMs I'd create variables like a bool called "inUse", and maybe a string (objectType) for things like "wall" or "door" and various others as required to contain information on the building that has or hasn't been done there. I'd create a layer called something like "Edges", I'd then add all of the Edge Markers to this layer. I'd then add a collider to each "Edge" game object so that the raycasts in the next part have something to hit. I'd also create a global array (called foundationMarkerList) with all of the Foundation Markers added to it.
In the image you can see the cursor is hovering over a grid square, the "Snap Position" has been moved to the center of that square. From the snap object you can get all of the information you may need using two techniques, firstly I'd use the action "array get closest game object" and check the "foundationMarkerList" array, the result should be the Foundation Marker under the snap position, I'd then raycast out 4 directions (-x,+x,-z and +z) to find the adjacent Edge Markers (limit the raycasts to the Edge Markers layer using the layer mask on the action).
You now have the game object for your current foundation piece and it's adjacent potential wall parts, you can now access the variables you set up in the two templates made earlier by using actions like "get FSM variables". With the data you query you can enable/disable GUI elements etc to let the player know what options they have in that particular grid position. I'd be tempted to make it so they have to click on the square to lock the Snap Position in place and bring up a menu with options from there. When they choose something make sure to set the relevant variables ("inUse" = true, "objectType" = stoneFloor etc) on the marker object it's related to and the whole system should come together nicely.
Final note: make sure to disable collisions between the "Edge Markers" layer and things that shouldn't collide with it (player controller, enemies etc).
I hope this suggestion holds some use for you!