don't use reserved keywords
add BATTLECLOSED and fix #3