예제 #1
0
        public FieldBuilding(Vector3Int position, int constructionPoints, FieldSim field)
            : base(position, constructionPoints, BuildingType.FieldBuilding)
        {
            SetDimentions(new Vector3Int(1, 1, 1));

            _field = field;

            NeededConstructionPoints = 100;

            NeededForConstruction = new Dictionary<MapElementType, int>();
            NeededForConstruction.Add(MapElementType.Lumber, 2);
            NeededForConstruction.Add(MapElementType.Stone, 2);

            _texture = WorldMap.Instance.GetContent().Load<Texture2D>("transparent");
        }
예제 #2
0
        public FieldWindow(FieldSim field, Vector2 position)
            : base("Field", true)
        {
            List<string> options = new List<string>();

            options.Add("Wheat");
            options.Add("Cannabis");
            options.Add("Cabage");

            Position = position;
            _field = field;

            Dimention = new Vector2(400, 200);

            _cropChooser = new DropDown(new Vector2(195, 30), options, "None");
            _lastSelected = _cropChooser.Selected;

            AddGuiComponent(_cropChooser);
            AddGuiComponent(new Label("Crop type:", new Vector2(20, 37)));
            //Components.Add(new SquareDropdown(new Vector2(10, 30), options, "None"));
        }
예제 #3
0
 public void AddFieldSim(FieldSim field)
 {
     _fieldSims.Add(field);
 }
예제 #4
0
        private void PlaceField()
        {
            _crops.Clear();
            _fences.Clear();
            // Places fences
            //PlaceFences();

            // Places crops
            PlaceCrops();

            FieldSim fs = new FieldSim(_crops);

            WorldMap.Instance.AddBuilding(new FieldBuilding(_clickedMapElement, 0, fs));

            SimulationWorld.Instance.AddFieldSim(fs);
        }
예제 #5
0
 public PlantFieldTask(FieldSim fieldSim)
 {
     Field = fieldSim;
     TaskType = TaskType.PlantCrop;
 }
예제 #6
0
파일: Dwarf.cs 프로젝트: steffan88/Bevelle
 public void SetActionField(FieldSim field)
 {
     _actionField = field;
 }