lib/codebreaker/codebreaker.rb in codebreaker-engine-0.1.3 vs lib/codebreaker/codebreaker.rb in codebreaker-engine-0.1.4

- old
+ new

@@ -31,13 +31,19 @@ raise CustomErrors::NameInvalidError unless validate_name(name) @name = name.capitalize end + + def check_code(code) @codemaker.verify(code) dicrement_attemts unless win? save_stats if game_end? + result_code + end + + def result_code @codemaker.verified_code end def hint return unless hint?