AFL code Help

#1
Hi friends,

i want help for one afl code. below are condition for code. Please try to do these

Rules.

1. if day first candle close in green and next candle break high of first candle so generate buy call.
stop loss below first candle day low and if second candle not hit stop loss and close and start third candle so stop loss trail from first candle low to second candle day low.
max profit 50 points book profit or exit call generate.

2. 1. if day first candle close in red and next candle break low of first candle so generate sell call.
stop loss above first candle day high and if second candle not hit stop loss and close and start third candle so stop loss trail from first candle high to second candle day high.
max profit 50 points book profit or exit call generate.

Thanks in advace