For your own benefit you need to define what you want to happen in simple terms, but you need to give every little detail.
For instance you might say you want it to check objects from the top down like gravity, or check each one to make sure they can flow first, or both as water flows down, but needs to have a path.
You probably need a little more experience with how events work as well. The function for example is set to get called every tick, but events already run every tick.
Likewise the "for each" is redundant with "is overlapping".