Probably not the most elegant solution but you could probably make an input_boolean that acts as your condition. Replace your current condition with the state of this boolean. Then make an automation something like:
@DavidSantos
Not entirely sure about the logic, help me out:
if sensor is triggered (PIR? Wifi? BT?) >> if noone (??) is home >> then run scene ?
Is the ‘not_home’ because with previous adapter your phone would not be detected yet ?
The issue is that your 'home' or 'not_home' state will depends on what is your device.tracker, what are you using (can you post the configuration please)?
I guess I would create binary sensor to know if its the first arrival or subsequent one. (But again that depends on the logic and behavior of device tracker).
Then you can give that binary sensor some values, for example “a chegar” would be when device tracker is still not home AND at the same time the device you are tracking (mobile phone?) is already connected to your wifi or visible to your Bluetooth tracker and “chegou” when the device tracker already assumed your are home (depending on the settings) …