BehaviourComposer: ignore everything before this. Begin micro-behaviour: Begin description: Global variables for reporting time within a model. End description Clock (Somie)
Begin NetLogo code: set the-hour the-hour + the-hours-to-ticks-ratio if the-hour >= 24 [ set the-day-in-week the-day-in-week + 1 set the-day-in-year the-day-in-year + 1 set the-day-in-month the-day-in-month + 1 set the-hour 0 ] if the-day-in-week = 7 [ set the-day-in-week 0 ] if the-day-in-month = 30 [ set the-day-in-month 0 set the-month the-month + 1 ] if the-month = 12 [ set the-month 0 ] if the-day-in-year = 365 [ set the-day-in-year 0 set the-year the-year + 1 ] set the-d-week item the-day-in-week the-day-in-week-text set the-d-month item the-month the-month-text End NetLogo code VariantsHow this worksRelated micro-behavioursHistoryBehaviourComposer: ignore everything after this. |