Ejemplo n.º 1
0
        public Employee CreateEmployee(TimeSpan simulationBirthTime, DateTime worldDateTime, Vector position)
        {
            string      texturePath = contentManager.GetContentPath("MaleEmployee0001");
            TextureBook textureBook = textureStore.GetTextureBook(texturePath);

            int      employeeNumber = GetNextEmployeeNumber();
            string   firstName      = contentManager.GetRandomFirstName();
            string   lastName       = contentManager.GetRandomLastName();
            DateTime birthday       = GetRandomBirthday(worldDateTime);
            Skills   skills         = Skills.GetRandomSkills();
            Job      job            = jobFactory.CreateRandomJob();

            Employee employee = new Employee(simulationBirthTime, "Employee " + employeeNumber, textureBook, position, AgentOrientation.FacingLeft, firstName, lastName, birthday, skills, job);

            if (log.IsDebugEnabled)
            {
                log.Debug(String.Format("Employee has been created with name: {0}", employee.FullName));
            }

            return(employee);
        }