Jeff Nyman has written an excellent guide on how rules are used within Inform 7.  You can view it here.