Changeset 502 for experiments/frams/foraminifera/data
- Timestamp:
- 05/04/16 23:51:02 (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
experiments/frams/foraminifera/data/scripts/foraminifera.expdef
r496 r502 155 155 phase = "low"; 156 156 nutrientSqrCm = 10; 157 ExpProperties.foodperiod = 25920;158 ExpProperties.foodPeriodChange = 6;157 ExpProperties.foodperiod = 19200; 158 ExpProperties.foodPeriodChange = 0; 159 159 ExpProperties.nutrientradius = micronsToFrams(10); 160 ExpProperties.energy_nut = energyFromVolume(ExpProperties.nutrientradius,1);160 ExpProperties.energy_nut = 150 * energyFromVolume(ExpProperties.nutrientradius,1); 161 161 ExpProperties.nutrient_pop = Math.pow(framsToMicrons(World.wrldsiz)*0.0001,2)/nutrientSqrCm; 162 162 ExpProperties.ingestion = 0.25; … … 365 365 if (ExpProperties.visualize == 1) 366 366 { 367 var ret = Populations[2].add("//0\np:sh= 3,sx=0.01,sy="+getZoneRange(cr,1)+",sz="+getZoneRange(cr,1)+",ry=1.57,vr="+curColor);367 var ret = Populations[2].add("//0\np:sh=1,sx=0.001,sy=0.001,sz=0.001\np:sh=3,sx=0.01,sy="+getZoneRange(cr,1)+",sz="+getZoneRange(cr,1)+",ry=1.57079633,vr="+curColor+"\nj:0, 1, sh=1"); 368 368 cr.data->reticulopodiacreature = ret; 369 ret.getMechPart(0).orient.set(o); 369 370 ret.moveAbs(cr.center_x-getZoneRange(cr,1), cr.center_y-getZoneRange(cr,1), cr.center_z-getZoneRange(cr,1)); 370 371 } … … 502 503 if (moved==1) 503 504 { 505 moveReticulopodia(cr); 504 506 return; 505 507 } … … 522 524 { 523 525 cr.localDrive = cr.data->lifeparams->dir; 526 } 527 moveReticulopodia(cr); 528 } 529 530 function moveReticulopodia(cr) 531 { 532 if (visualization(cr)) 533 { 534 cr.data->reticulopodiacreature.moveAbs(cr.center_x-getZoneRange(cr,1), cr.center_y-getZoneRange(cr,1), cr.center_z-getZoneRange(cr,1)); 535 cr.data->reticulopodiacreature.localDrive = cr.localDrive; 524 536 } 525 537 } … … 536 548 { 537 549 cr1.localDrive = XYZ.new(0,0,0); 538 var e = ExpProperties.feedtrans*cr1.energy;//ExpProperties.feedtrans*cr1.energy*ExpProperties.ingestion*ExpProperties.secPerStep; //TODO efficiency dependent on age 539 e = Math.min(cr2.energy, e); 540 e *= ExpProperties.secPerStep; 541 //Simulator.print("transferring "+e +"("+e*ExpProperties.ingestion+")"+" to "+cr1.name +" ("+ cr1.energy+") " +" from "+cr2.name+" ("+cr2.energy+") "+ e/ExpProperties.secPerStep+ " per sec"); 542 cr2.energy_m = cr2.energy_m + e + 0.0000001; 543 cr1.energy_p = cr1.energy_p + e*ExpProperties.ingestion; 550 var e = ExpProperties.feedtrans*cr1.energy; //TODO efficiency dependent on age 551 e = Math.min(cr2.energy, e*ExpProperties.secPerStep); 552 //Simulator.print("transferring "+e +"("+e*ExpProperties.ingestion+")"+" to "+cr1.name +" ("+ cr1.energy+") " +" from "+cr2.uid+" ("+cr2.energy+") "+ e/ExpProperties.secPerStep+ " per sec"); 553 cr2.energy -= (e + 0.0000001); 554 cr1.energy_p += e*ExpProperties.ingestion; 544 555 if (cr1.data->lifeparams->hibernated == 1) 545 556 { … … 628 639 foramMove(cr); 629 640 630 if (visualization(cr))631 632 {633 cr.data->reticulopodiacreature.moveAbs(cr.center_x-getZoneRange(cr,1), cr.center_y-getZoneRange(cr,1), cr.center_z-getZoneRange(cr,1));634 }635 636 641 var repro = foramReproduce(cr); 637 642 if (repro == 1) … … 683 688 function createNutrientGenotype(nutrientradius) 684 689 { 685 return "//0\np:sh=3,sx="+nutrientradius+",sy="+nutrientradius+",sz="+nutrientradius+",ry=1.5 ,vr=0.0,1.0,0.0";690 return "//0\np:sh=3,sx="+nutrientradius+",sy="+nutrientradius+",sz="+nutrientradius+",ry=1.57,vr=0.0,1.0,0.0"; 686 691 } 687 692
Note: See TracChangeset
for help on using the changeset viewer.