File tree Expand file tree Collapse file tree
IABM Textbook/chapter 3/Fire Extensions Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -9,15 +9,15 @@ to setup
99 ;; make some green trees
1010 ask patches [
1111 if (random 100) < density [ set pcolor green ]
12- ]
13-
12+ ]
13+
1414 ;; Count initial trees before lighting trees on fire to get accurate calculation of percent burned
15- set initial-trees count patches with [pcolor = green]
16-
15+ set initial-trees count patches with [pcolor = green]
16+
1717 ask patches [
1818 ;; make a column of burning trees at the left-edge
1919 if pxcor = min-pxcor [ set pcolor red ]
20- ]
20+ ]
2121
2222 reset-ticks
2323end
Original file line number Diff line number Diff line change @@ -9,15 +9,15 @@ to setup
99 ;; make some green trees
1010 ask patches [
1111 if (random 100) < density [ set pcolor green ]
12- ]
13-
12+ ]
13+
1414 ;; Count initial trees before lighting trees on fire to get accurate calculation of percent burned
15- set initial-trees count patches with [pcolor = green]
16-
15+ set initial-trees count patches with [pcolor = green]
16+
1717 ask patches [
1818 ;; make a column of burning trees at the left-edge
1919 if pxcor = min-pxcor [ set pcolor red ]
20- ]
20+ ]
2121
2222 reset-ticks
2323end
Original file line number Diff line number Diff line change @@ -9,15 +9,15 @@ to setup
99 ;; make some green trees
1010 ask patches [
1111 if (random 100) < density [ set pcolor green ]
12- ]
13-
12+ ]
13+
1414 ;; Count initial trees before lighting trees on fire to get accurate calculation of percent burned
15- set initial-trees count patches with [pcolor = green]
16-
15+ set initial-trees count patches with [pcolor = green]
16+
1717 ask patches [
1818 ;; make a column of burning trees at the left-edge
1919 if pxcor = min-pxcor [ set pcolor red ]
20- ]
20+ ]
2121
2222 reset-ticks
2323end
Original file line number Diff line number Diff line change @@ -9,15 +9,15 @@ to setup
99 ;; make some green trees
1010 ask patches [
1111 if (random 100) < density [ set pcolor green ]
12- ]
13-
12+ ]
13+
1414 ;; Count initial trees before lighting trees on fire to get accurate calculation of percent burned
15- set initial-trees count patches with [pcolor = green]
16-
15+ set initial-trees count patches with [pcolor = green]
16+
1717 ask patches [
1818 ;; make a column of burning trees at the left-edge
1919 if pxcor = min-pxcor [ set pcolor red ]
20- ]
20+ ]
2121
2222 reset-ticks
2323end
You can’t perform that action at this time.
0 commit comments