Having trouble understanding how to set rule machine for lights

Than read this it might explain a lot.

Creating Your First Rule