source: experiments/frams/foraminifera/data/scripts/foraminifera.show @ 423

Last change on this file since 423 was 423, checked in by oriona, 9 years ago

corrected properties definitions, added function for setting show parameters

File size: 1.7 KB
Line 
1show:
2name:Reproduction of benthic foraminifera
3info:~
4There are two species of Foraminiera: longitudal and coiled. First chamber of the longitudal species has
5orange marks. Haploid and diploid generations alternate in both species. All chambers of the haploid generation
6have the same size. In the diploid generation subsequent chambers are bigger than their predecessors.
7Nutrients are green disks. Foraminifers move towards nearest nutrients and try to accumulate a sufficient
8amount of energy to reproduce.
9
10More information at www.framsticks.com/foraminifera
11~
12expdef:foraminifera
13code:~
14
15global Params;
16
17function onLoad()
18{
19        Simulator.init();
20        GLDisplay.desiredsimspeed = 50;
21        GLDisplay.minfps = 10;
22
23        Params = {"nutrientPop" : [5,10,15], "feedrate" : [0.001,0.0025,0.004], "feedtrans" : [0.01,0.05,0.1],"energy_nut" :[0.5,1.5,3.0], "stress" : [0,1]};
24}
25
26function setShowParam(param_id)
27{
28        ExpParams.[param_id] = Params[param_id][ShowParams.[param_id]];
29}
30
31function ShowParams_nutrientPop_set()
32{
33        setShowParam("nutrientPop");
34}
35
36function ShowParams_feedrate_set()
37{
38        setShowParam("feedrate");
39}
40
41function ShowParams_feedtrans_set()
42{
43        setShowParam("feedtrans");
44}
45
46function ShowParams_energy_nut_set()
47{
48        setShowParam("energy_nut");
49}
50
51function ShowParams_stress_set()
52{
53        setShowParam("stress");
54}
55
56~
57
58prop:
59id:nutrientPop
60name:Nutrients amount
61type:d 0 2 1 ~5~10~15
62
63prop:
64id:feedrate
65name:Feeding rate
66type:d 0 2 1 ~Low~Medium~High
67
68prop:
69id:feedtrans
70name:Energy transfer
71type:d 0 2 1 ~0.01~0.05~0.1
72
73prop:
74id:energy_nut
75name:Nutrient energy
76type:d 0 2 1 ~0.5~1.5~3
77
78prop:
79id:stress
80name:Stress
81type:d 0 1 1
Note: See TracBrowser for help on using the repository browser.