I'm not sure I understand 100%, but i'm thinking that doing this with a function will do something?
* On function 'SetStateBasedOnNumber'
* Parameter 'number' (Number)
* Parameter 'x' (Number)
* Parameter 'y' (Number)
----+ System: number = 0
-----> Tilemap: Set tile (x, y) state normal
----+ System: Else
----+ System: number = 1
-----> Tilemap: Set tile (x, y) state rotated 90°
----+ System: Else
----+ System: number = 2
-----> Tilemap: Set tile (x, y) state rotated 180°
----+ System: Else
----+ System: number = 3
-----> Tilemap: Set tile (x, y) state rotated 270°
+ System: On start of layout
-> Functions: Call SetStateBasedOnNumber (number: floor(random(4)), x: 1, y: 1)
You can just make a loop through x and y?
Hope this helps