you have to add stochastic oscillator with all parameters and turn on and off function,(either rsi or stochastic have to work only at a time).
need 5 input parameters.
2)martingale step(if I mention 5, after 5 steps it has to open new order after given distance)
3)distance(pips distance after certain orders)
4)equity target and equity stop(in percentage)
5)Trailing stop loss with parameters.