ALMaSS Hare ODDox
1.1
The hare model description following ODdox protocol
|
Go to the documentation of this file.
28 #include "../../Landscape/ls.h"
29 #include "../../Landscape/cropprogs/PermanentGrassTussocky.h"
55 m_field->SetMDates(0,0,g_date->DayInYear(15,9));
57 m_field->SetMDates( 1, 0, g_date->DayInYear(1,10) );
70 g_msg->Warn( WARN_BUG,
"PermanentGrassTussocky::Do(): "
71 "Harvest too late for the next crop to start!!!",
"" );
75 for (
int i=0; i<noDates; i++) {
87 int today=g_date->Date();
92 g_msg->Warn( WARN_BUG,
" PermanentGrassTussocky::Do(): "
93 "Crop start attempt after last possible start date",
"" );
101 if ( g_date->Date() > d1 ) {
114 if (
m_field->GetMConstants(0)==0) {
116 g_msg->Warn( WARN_BUG,
"PermanentGrassTussocky::Do(): failure in 'CattleOutLowGrazing' execution",
"" );
131 if (
m_field->GetMConstants(0)==0) {
133 g_msg->Warn( WARN_BUG,
"PermanentGrassTussocky::Do(): failure in 'CattleOutLowGrazing' execution",
"" );
156 if (
m_field->GetMConstants(0)==0) {
159 if(g_date->Date() ==
m_field->GetMDates(1,0)){
160 g_msg->Warn( WARN_BUG,
"PermanentGrassTussocky::Do(): failure in 'CattleIsOutLow' execution",
"" );
172 if (g_date->DayInYear()<g_date->DayInYear(10,9))
182 g_msg->Warn( WARN_BUG,
"PermanantGrassTussocky::Do(): "
183 "Unknown event type! ",
"" );
A struct to hold the information required to trigger a farm event.
bool DoIt(double a_probability)
Return chance out of 0 to 100.
bool Do(Farm *a_farm, LE *a_field, FarmEvent *a_ev)
TTypesOfFarm GetType(void)
CfgFloat cfg_fungi_app_prop1
CfgFloat cfg_herbi_app_prop
virtual bool CattleIsOutLow(LE *a_field, double a_user, int a_days, int a_max)
Generate a 'cattle_out_low' event for every day the cattle are on a_field.
void SimpleEvent(long a_date, int a_todo, bool a_lock)
Adds an event to this crop management.
virtual bool CattleOutLowGrazing(LE *a_field, double a_user, int a_days)
Start a extensive grazing event on a_field today.
The base class for all farm types.
CfgFloat cfg_greg_app_prop
void ChooseNextCrop(int a_no_dates)
Chooses the next crop to grow in a field.
CfgFloat cfg_ins_app_prop1