AFL requirement

Please help me code this strategy for Amibroker

Buy when EMA 15 is above EMA 30 irrelevant of the stock price BUT the important thing here is
William’s %R(3) < -80(oversold)

Sell when EMA 30 is above EMA 15 irrelevant of the stock price BUT the important thing here is
William’s %R(3) > -20(overbought)

Also, can you apply the ADX(14) strategy to it ie

A buy signal is generated when ADX is 25 and the +DI crosses over –DI
A sell signal is generated when ADX is 25 and the –DI crosses over +DI

This is not a cross over strategy.

I do not have an exit or a cover strategy as I want to use this for day trading.

Thanks