コード例 #1
0
ファイル: AddGroupMenu.cs プロジェクト: bionick7/4040Machines
 public void Finish()
 {
     if (Edit)
     {
         for (int i = 0; i < group.Count; i++)
         {
             group.TurretArray[i].Group = TurretGroup.Trashbin;
         }
         foreach (Turret turr in selected_turrets)
         {
             turr.Group = group;
         }
         group.name = name_input.text;
     }
     else
     {
         group = new TurretGroup(Target.None, selected_turrets.ToArray(), name_input.text)
         {
             own_ship = SceneGlobals.Player
         };
         gui_script.AddTurretGroup(group);
     }
     Enabled = false;
 }