-------------------------------------------------------------------------------------------------
-- INITIALISE_Level. Standard level event
-------------------------------------------------------------------------------------------------
function EVENTINITIALISE_Level()
	-- load the building and business file

	C_RunScript("scripts\\maps\\jonmap012.lua");
	-- load the initialprefs file
	C_RunScript("scripts\\custom\\deepred\\Jon008\\initialpref.lua");
	Game.SetObjective(OBJECTIVE_WEAKEST_LINK, 3);
end;

-------------------------------------------------------------------------------------------------
-- Level. Standard level event.
-------------------------------------------------------------------------------------------------
function EVENT_Level()
end;

-------------------------------------------------------------------------------------------------
-- HourlyUpdate event. Called everytime the game calendar ticks another hour over.
-------------------------------------------------------------------------------------------------



function CATCHEVENT_HourlyUpdate(a) -- takes the current hour as an argument
	if People.NumberInCity() < 1000 then
		if a == 14 then
--						  No		AGE				Class			Prefs				
			People.Create(1, 	AGE_ADULT, 			CLASS_LOW,		-1);
			People.Create(0, 	AGE_PENSIONER,		CLASS_LOW,	 	-1);
			People.Create(1, 	AGE_CHILD, 			CLASS_LOW,	 	-1);
			People.Create(0, 	AGE_TOURIST,		CLASS_LOW,	 	-1);
			People.Create(1, 	AGE_TEENAGER,		CLASS_LOW,	 	-1);
			
			People.Create(1, 	AGE_ADULT, 			CLASS_MEDIUM,	-1);
			People.Create(1, 	AGE_PENSIONER,		CLASS_MEDIUM, 	-1);
			People.Create(0, 	AGE_CHILD, 			CLASS_MEDIUM, 	-1);
			People.Create(1, 	AGE_TOURIST,		CLASS_MEDIUM, 	-1);
			People.Create(0, 	AGE_TEENAGER,		CLASS_MEDIUM, 	-1);
			
			People.Create(1, 	AGE_ADULT, 			CLASS_HIGH,		-1);
			People.Create(0, 	AGE_PENSIONER,		CLASS_HIGH, 	-1);
			People.Create(1, 	AGE_CHILD, 			CLASS_HIGH, 	-1);
			People.Create(0, 	AGE_TOURIST,		CLASS_HIGH, 	-1);
			People.Create(1, 	AGE_TEENAGER,		CLASS_HIGH, 	-1);
		end;
	end

end;
