Simple lighting and door lock

Since you appear to be familiar with older versions of RM, I'd recommend reading the 4.0 docs for how you can convert older ways of thinking into 4.0 rules: [Released] Rule 4.0

You probably don't really want that many triggers. Triggers (and only triggers, or getting called by another rule) cause your rule actions to run. So you probably don't really want to trigger your rule at 4:00 but rather on the door lock changing or at least unlocking. In your actions, you can use IFs to do different things (including nothing) depending on the time. Also, triggers are events--momentary, durationless, and having no truth value. If you find yourself wanting something like that, you're probably looking to use a conditional (IF) somewhere in your actions instead.

Here's a simple example that will turn on the lights for 3 minutes after the door is unlocked between 4 PM and 5 AM (and reset that timer if it's locked and unlocked again during that countdown):

Trigger: Front Door lock unlocked

Actions:

Cancel Delayed Actions
IF (Time is between 4 PM and 5 AM) THEN
  On: Front Door Light
  Delay 0:03:00 (cancelable)
  Off: Front Door Light
END-IF