Switch to edit mode.
Name(s): reset1: "Copyright (C) Olivier Beaton (aka Quadir), all rights reserved."
2: "Licensed under BSD, see http://www.opensource.org/licenses/bsd-license.php"
3: ""
4: "Syntax:"
5: " :reset()"
6: "--"
7: "Reset the board for play."
8: caller == this || (!this.restrict_calls && this:is_unlocked_for(caller_perms())) || raise(E_PERM)
9: this.generic == this && raise(E_PERM, "No play on generic!")
10: grid = {}
11: for h in [1..this.height]
12: grid = {@grid, {}}
13: for w in [1..this.width]
14: grid[$] = {@grid[$], 0}
15: endfor
16: endfor
17: this.grid = grid
18: this.running = 1
19: this.player = 1
20: "Last modified by Quadir (#9780) on Tue Sep 24 11:36:39 2002 MDT."