code deduplicate, add out_FAILED && FORCECLIENTBATTLE