Script for price movement based on previous candle

Assume, I have a market watch with 10 stocks. I would like my strategy script to check all of them and alert/highlight me when my criteria/condition is met.

  1. Alert/Notify me for BUY when CMP crosses above HIGH of 12 PM 15 MIN GREEN CANDLE
    (The current 15 MIN candle could be any candle greater than 12PM 15 MIN CANDLE)

  2. Alert/Notify me for SELL when CMP crosses below LOW of 12PM 15 MIN RED CANDLE
    (The current 15 MIN candle could be any candle greater than 12PM 15 MIN CANDLE)

I’m not sure if it should be a scanner script or trade script to implement my strategy that checks for specific time like 12PM or 12:30PM candle for a set of stocks. It would be extremely helpful if you could assist me with it. Thanks in advance.

As per the above condition it is not possible to code in tradesript as specific time can not be defined