コード例 #1
0
        public ShowWorkbenchPreset(Genus2D.GameData.EventCommand command)
        {
            InitializeComponent();
            _command = command;

            for (int i = 0; i < CraftableData.GetWorkbenchDataCount(); i++)
            {
                WorkbenchSelectionBox.Items.Add(CraftableData.GetWorkbench(i));
            }

            int workbenchID = (int)command.GetParameter("WorkbenchID");

            if (workbenchID < WorkbenchSelectionBox.Items.Count)
            {
                WorkbenchSelectionBox.SelectedIndex = workbenchID;
            }
        }
コード例 #2
0
 public void AddEventCommand(EventCommand command)
 {
     EventCommands.Add(command);
 }