Class: RpsYsc::Play

Inherits:
Object
  • Object
show all
Defined in:
lib/rps_ysc.rb

Instance Method Summary collapse

Instance Method Details

#startObject



61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
# File 'lib/rps_ysc.rb', line 61

def start
    puts"welcome to the game"
    
    loop do 
        user = Input.new
        user.init
        w1 = user.enter("user")
        pc = Input.new
        pc.init
        w2 = pc.ai
        vs = Score.new
        vs.judge(w1,w2)
        w1,w2 = 0, 0
        
    end
end