Write variable value in simulation.log

Hello
I want to print an variable value in the below format in gatling simulation.log file if the same is possible please help

Modified format of simulation.log

REQUEST 1       account_movement_post   1553663401413   1553663404218   KO  status.find.in(200,201,202,203,204,205,206,207,208,209,303), found 500 <Variable Value>

Actual format of simulation.log

REQUEST 1       account_movement_post   1553663401413   1553663404218   KO  status.find.in(200,201,202,203,204,205,206,207,208,209,303), found 500

The simulation.log file is an internal and is only meant to be parsed by the module that generates the HTML reports.
Format is subject to changes without further notice.

So it means that we cannot modify the format of the simulation.log file.
In that case please help me how I can write the variable value in a text file.

Use below code for writing your customized data into output steam.

val writer = {
val fos = new java.io.FileOutputStream("/gatling/bin/ErrorOutput.txt")
new java.io.PrintWriter(fos,true)
}