private void PopulateAgentTab(ScenarioAgent agent) { AgentXUpDown.Value = (decimal)(agent.Position.X); AgentYUpDown.Value = (decimal)(agent.Position.Y); AgentStartXUpDown.Value = (decimal)(agent.StartPosition.X); AgentStartYUpDown.Value = (decimal)(agent.StartPosition.Y); AgentRadiusUpDown.Value = (decimal)(agent.Radius); AgentArchetypeComboBox.SelectedItem = agent.AgentArchetype; if (agent.StartProperties == null) { agent.GenerateStartProperties(EditProject.KB); } AgentProperties.SelectedObject = new AgentPropertyAdapter(agent.StartProperties); }
private void PopulateAgentTab(ScenarioAgent agent) { AgentXUpDown.Value = (decimal)(agent.Position.X); AgentYUpDown.Value = (decimal)(agent.Position.Y); AgentStartXUpDown.Value = (decimal)(agent.StartPosition.X); AgentStartYUpDown.Value = (decimal)(agent.StartPosition.Y); AgentRadiusUpDown.Value = (decimal)(agent.Radius); AgentArchetypeComboBox.SelectedItem = agent.AgentArchetype; ColorSwatch.BackColor = agent.Color; AgentRandomStartPositionCheckBox.Checked = agent.StartFuzzed; AgentStartLocationCombo.SelectedItem = agent.StartLocation; if (AgentStartLocationCombo.SelectedIndex < 0) { AgentStartLocationCombo.SelectedIndex = 0; } agent.GenerateStartProperties(EditingProject.KB); AgentProperties.SelectedObject = new AgentPropertyAdapter(agent.StartProperties); }