lib/Main.rb in rpsg-0.3.2 vs lib/Main.rb in rpsg-0.3.3

- old
+ new

@@ -3,11 +3,11 @@ require "rpsg/version.rb" require "Constants.rb" - protected_methods :Constants + # protected_methods :Constants class << self # add continue method for asking the user if they want to play rock paper scissors def continue(str1,str2,str3) puts str1 @@ -50,21 +50,22 @@ end puts "\nFinal score: player: #{@player_score}, " + "computer: #{@computer_score} (ties: #{@ties}).\n" case PrivateMethods.final_outcome(@player_score, @computer_score) when :WIN - puts "\nPlayer wins!" + puts "\nPlayer wins!\n" when :LOSE - puts "\nComputer wins!" + puts "\nComputer wins!\n" else - puts "\nIt's a tie!" + puts "\nIt's a tie!\n" end + print "\n[press any key to exit game]" gets end require "PrivateMethods.rb" - private_methods :PrivateMethods + # private_methods :PrivateMethods end RockPaperScissorsGame.new.play(2) # best out of 3 \ No newline at end of file