Error E355 relats to the published version of a game.
A published engine could not start. Possible reasons are modifications to the executable, resource, or script after publishing. This can also happen if the .CD folder contained old content. Delete the .CD folder and publish again.
What version of Gamestudio do you use? Are you aware file_asc_write does not return a value and hence the result of your condition is unspecified?