to go
5 e' W3 n0 F* Q( D prices1 [2 Y# E2 n2 M# Y6 i p% q
enlarge-market
2 R( X1 J* }0 \; W% b3 r supervision" |1 s; B5 S! Y1 m
move-turtles
, A/ L- M+ Z' ~ ^4 V& L2 F+ C new-producer
& W8 V: ~* g+ q check-death2 O9 Y) x3 @8 B9 ?+ u' ?
tick& X! m, B0 `* g& ~* v4 u. p
do-plots
# F2 P6 _1 U# t- H6 B2 Oend
) R& m$ t! Q: Y0 v" ?, @to move-turtles) H" I( g3 w; A
pcs[6 W( d0 [, i( f, m0 f1 Y4 F; w
ifelse counter > 0
( B2 J4 B, h( Y, `" D# F [ set counter counter - 1, O; D9 t) _. R- S4 }/ k0 j2 R
set money money - cost1]- [" V3 a; u: T% j
[ right random 360
; i) O4 v' v9 F3 J4 f5 e4 o: D @ repeat 1 [rt random 360) L1 I/ |% O9 x* c4 V+ |3 Y( l$ k ]
forward 1
% {0 @$ ]& A0 [' e* j& V if pcolor = grey [
0 _: V. B) N- b/ h* A2 e6 b set pcolor yellow - 2
6 a5 J# p6 ]8 @( N- g! L& E6 d set quantity(quantity + 1)]]
6 l- l( y; b4 p7 P' U) W set money(1 - exposure-rate / 100)*(money + jiage * quantity), ?4 X0 w4 ]; k; J) |
set money money - cost1]1 ?' Y' j/ |5 ~6 r- I" Z
]
* d* R/ b; \* n& f, Z ask pes) Z/ R! V6 }2 p8 _8 D6 X/ v
[right random 360
3 Y/ t" ~" K: n' V) O forward 1* p P; A8 q# t* I+ ]& ~
set money money + jiage * quantity5 D5 T, M3 }- s& G$ B) y, r
set money money - cost2]
+ N- i7 b- P% H- A: ]' bend |