Get center point of each room's floor in a house

That’s right, I want to make a function or an event that takes each room and gets the center point of it then stores those points in an array.
I have over 1000 rooms
That’s why I need to make it