And/or/where conditions for triggers

This is probably a newbie question, but i haven’be able to figure that out yet.

How can i create a action/trigger based on conditions? (More than one)

Example: i have married the Vehicle Tracking with Vera already via luup
Created a scene to turn on the light in front of the house, and open the garage door if i arrive.
This works perfectly so far.

But i want the lights to turn on only if its night time.

So in short : if (geofence trigger == true && daynight == night) { turn on the lights }

Well somethings like that.
Can anyone ‘hint me’ in the right direction ?

Search terms: luup.is_night; PLEG; Day Or Night plugin; Combination Switch.

is_night was the right pointer … thanks again …

just have somehow the issue the daynight module seems to ignore the sunset offset…
still playing with that