The idea of the Expert Advisor stems from the theory of rollbacks. We often find levels, from which the price rolls back. That trader finds such a point and places an order there. In order not to repeat the same procedures, use this Expert Advisor.
The Expert Advisor opens a limit order where another order has just closed with a profit. All parameters, lot, Stop Loss, Take Profit and the direction are the same as of the closed order.
A position is opened at 1,1234. After it closes, a limit order with the same parameters is placed at the level of 1,1234. If the position closes at a loss, the EA will not open any other orders. It will wait for the opening of a new order for this pair.
In the tester, the EA opens two orders - buy and sell, so that you can visually estimate its performance.
In order not to produce the illusion of super profits, I'll explain: It's just a tool like a trailing stop, but used for a different purpose. The trader decides when to turn the EA on or off. The system starts to work only based on the order opened by a trader or another EA. It only repeats the actions of the trader to help in everyday activities. The system stops working with the first stop, and then waits for a trader's command. That is, it's not a fully automated trading.