Changeset 18746 for lang/ruby

Show
Ignore:
Timestamp:
09/03/08 19:59:57 (3 months ago)
Author:
hajimehoshi
Message:

Added website

Location:
lang/ruby/bokeshi/trunk
Files:
12 added
2 modified

Legend:

Unmodified
Added
Removed
  • lang/ruby/bokeshi/trunk/bokeshi/stage.rb

    r18694 r18746  
    5151    end 
    5252 
     53    def []=(row, col, value) 
     54      raise IndexError unless check_row_col(row, col) 
     55      @sticks[row][col] = value 
     56    end 
     57 
    5358    def removable?(removing) 
    5459      row, col, length = removing.row, removing.col, removing.length 
  • lang/ruby/bokeshi/trunk/bokeshi/test_stage.rb

    r18571 r18746  
    235235    end 
    236236 
     237    def test_set 
     238      stage = Stage.new 
     239      stage[0, 0] = :player 
     240      assert_equal :player, stage[0, 0] 
     241      stage[2, 1] = :cpu 
     242      assert_equal :cpu, stage[2, 1] 
     243    end 
     244 
    237245  end 
    238246