Advertisement
Guest User

Untitled

a guest
Jan 25th, 2012
175
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. LOGame>>newCellAt:at:
  2.  
  3. newCellAt: i at: j
  4.     "Create one cell for position i@j, initialize it and display it on screen on right position. Answers cell itself."
  5.     | c origin |
  6.     c := LOCell new.
  7.     origin := self innerBounds origin.
  8.     self addMorph: c.
  9.     c position: ((i - 1)*c width)@((j - 1)*c height) + origin.
  10.     c mouseAction: [self toggleNeighboursOfCellAt: i at: j].
  11.     ^c.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement