Added error handling for Init and Attack