I am trying to write some logic to detect a proper portal gate frame. The rules are: 1. the frame must be made of one kind of block (from a list of blocks but that comes later) 2. the inside of the frame must be AIR or CAVE_AIR only. I am sort of ripping off DinnerBone's Stargates plugin so the starting point will be upon editing a sign up against the frame. It's easy enough to select a starting point, but if I want the shape of the gates to be completely up to the player creating them, I need some crazy logic to detect the outer bounds of the gate for validation, and then some more crazy logic to search only the inside of the gate for air. I am writing this in MethodScript for use with CommandHelper, I do have some understanding of Java though so I can probably translate ideas written with Java in mind.