fix sub state system