forked from s425077/PotatoPlan
Last Images and at last fixed the Production System
This commit is contained in:
parent
095ccc0fc6
commit
4ab4abaa89
BIN
Game1/Content/BarleyIcon.png
Normal file
BIN
Game1/Content/BarleyIcon.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 2.1 KiB |
@ -13,6 +13,18 @@
|
|||||||
|
|
||||||
#---------------------------------- Content ---------------------------------#
|
#---------------------------------- Content ---------------------------------#
|
||||||
|
|
||||||
|
#begin BarleyIcon.png
|
||||||
|
/importer:TextureImporter
|
||||||
|
/processor:TextureProcessor
|
||||||
|
/processorParam:ColorKeyColor=255,0,255,255
|
||||||
|
/processorParam:ColorKeyEnabled=True
|
||||||
|
/processorParam:GenerateMipmaps=False
|
||||||
|
/processorParam:PremultiplyAlpha=True
|
||||||
|
/processorParam:ResizeToPowerOfTwo=False
|
||||||
|
/processorParam:MakeSquare=False
|
||||||
|
/processorParam:TextureFormat=Color
|
||||||
|
/build:BarleyIcon.png
|
||||||
|
|
||||||
#begin BerriesIcon.png
|
#begin BerriesIcon.png
|
||||||
/importer:TextureImporter
|
/importer:TextureImporter
|
||||||
/processor:TextureProcessor
|
/processor:TextureProcessor
|
||||||
@ -37,6 +49,18 @@
|
|||||||
/processorParam:TextureFormat=Color
|
/processorParam:TextureFormat=Color
|
||||||
/build:CarronIcon.png;CarrotIcon.png
|
/build:CarronIcon.png;CarrotIcon.png
|
||||||
|
|
||||||
|
#begin CottonIcon.png
|
||||||
|
/importer:TextureImporter
|
||||||
|
/processor:TextureProcessor
|
||||||
|
/processorParam:ColorKeyColor=255,0,255,255
|
||||||
|
/processorParam:ColorKeyEnabled=True
|
||||||
|
/processorParam:GenerateMipmaps=False
|
||||||
|
/processorParam:PremultiplyAlpha=True
|
||||||
|
/processorParam:ResizeToPowerOfTwo=False
|
||||||
|
/processorParam:MakeSquare=False
|
||||||
|
/processorParam:TextureFormat=Color
|
||||||
|
/build:CottonIcon.png
|
||||||
|
|
||||||
#begin Crop.png
|
#begin Crop.png
|
||||||
/importer:TextureImporter
|
/importer:TextureImporter
|
||||||
/processor:TextureProcessor
|
/processor:TextureProcessor
|
||||||
@ -56,6 +80,18 @@
|
|||||||
/processorParam:TextureFormat=Compressed
|
/processorParam:TextureFormat=Compressed
|
||||||
/build:Font.spritefont
|
/build:Font.spritefont
|
||||||
|
|
||||||
|
#begin GroundNutsIcon.png
|
||||||
|
/importer:TextureImporter
|
||||||
|
/processor:TextureProcessor
|
||||||
|
/processorParam:ColorKeyColor=255,0,255,255
|
||||||
|
/processorParam:ColorKeyEnabled=True
|
||||||
|
/processorParam:GenerateMipmaps=False
|
||||||
|
/processorParam:PremultiplyAlpha=True
|
||||||
|
/processorParam:ResizeToPowerOfTwo=False
|
||||||
|
/processorParam:MakeSquare=False
|
||||||
|
/processorParam:TextureFormat=Color
|
||||||
|
/build:GroundNutsIcon.png
|
||||||
|
|
||||||
#begin house.png
|
#begin house.png
|
||||||
/importer:TextureImporter
|
/importer:TextureImporter
|
||||||
/processor:TextureProcessor
|
/processor:TextureProcessor
|
||||||
|
BIN
Game1/Content/CottonIcon.png
Normal file
BIN
Game1/Content/CottonIcon.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 3.5 KiB |
BIN
Game1/Content/GroundNutsIcon.png
Normal file
BIN
Game1/Content/GroundNutsIcon.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 1.6 KiB |
@ -97,12 +97,14 @@ namespace Game1
|
|||||||
tile[2] = Content.Load<Texture2D>("Plantable");
|
tile[2] = Content.Load<Texture2D>("Plantable");
|
||||||
tile[3] = Content.Load<Texture2D>("Crop");
|
tile[3] = Content.Load<Texture2D>("Crop");
|
||||||
|
|
||||||
Crops[0] = Content.Load<Texture2D>("CarrotIcon");
|
|
||||||
Crops[1] = Content.Load<Texture2D>("WheatIcon");
|
|
||||||
Crops[2] = Content.Load<Texture2D>("BerriesIcon");
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
Crops[0] = Content.Load<Texture2D>("BarleyIcon");
|
||||||
|
Crops[1] = Content.Load<Texture2D>("CottonIcon");
|
||||||
|
Crops[2] = Content.Load<Texture2D>("GroundNutsIcon");
|
||||||
Crops[3] = Content.Load<Texture2D>("MaizeIcon");
|
Crops[3] = Content.Load<Texture2D>("MaizeIcon");
|
||||||
Crops[4] = Content.Load<Texture2D>("MilletsIcon");
|
Crops[4] = Content.Load<Texture2D>("MilletsIcon");
|
||||||
Crops[5] = Content.Load<Texture2D>("SeedOilIcon");
|
Crops[5] = Content.Load<Texture2D>("SeedOilIcon");
|
||||||
|
@ -28,7 +28,7 @@ class Crops
|
|||||||
getProductionRate();
|
getProductionRate();
|
||||||
if (Status == 3 && Timer != 1)
|
if (Status == 3 && Timer != 1)
|
||||||
{
|
{
|
||||||
Timer = Timer - 1 * ProductionRate;
|
Timer = Timer - 1f * ProductionRate;
|
||||||
}
|
}
|
||||||
Size = newSize;
|
Size = newSize;
|
||||||
UpdateCrop++;
|
UpdateCrop++;
|
||||||
@ -198,33 +198,31 @@ class Crops
|
|||||||
ProductionRate = 1;
|
ProductionRate = 1;
|
||||||
if (DataSet != null)
|
if (DataSet != null)
|
||||||
{
|
{
|
||||||
ProductionRate = (ProductionRate * compareToDatset(soilProperties.Temperature, DataSet.Temparature));
|
ProductionRate = ProductionRate + (ProductionRate * compareToDatset(soilProperties.Temperature, DataSet.Temparature));
|
||||||
ProductionRate = (ProductionRate * compareToDatset(soilProperties.Moisture, DataSet.Moisture));
|
ProductionRate = ProductionRate + (ProductionRate * compareToDatset(soilProperties.Moisture, DataSet.Moisture));
|
||||||
ProductionRate = (ProductionRate * compareToDatset(soilProperties.Humidity, DataSet.Humidity));
|
ProductionRate = ProductionRate + (ProductionRate * compareToDatset(soilProperties.Humidity, DataSet.Humidity));
|
||||||
ProductionRate = (ProductionRate * compareToDatset(soilProperties.Phosphorous, DataSet.Phosphorous));
|
ProductionRate = ProductionRate + (ProductionRate * compareToDatset(soilProperties.Phosphorous, DataSet.Phosphorous));
|
||||||
ProductionRate = (ProductionRate * compareToDatset(soilProperties.Potassium, DataSet.Potassium));
|
ProductionRate = ProductionRate + (ProductionRate * compareToDatset(soilProperties.Potassium, DataSet.Potassium));
|
||||||
ProductionRate = (ProductionRate * compareToDatset(soilProperties.Nitrogen, DataSet.Nitrogen));
|
ProductionRate = ProductionRate + (ProductionRate * compareToDatset(soilProperties.Nitrogen, DataSet.Nitrogen));
|
||||||
if (ProductionRate < 0)
|
if (ProductionRate < 0)
|
||||||
{
|
{
|
||||||
ProductionRate = 0;
|
ProductionRate = 0;
|
||||||
}
|
}
|
||||||
|
ProductionRate = ProductionRate / 20;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public float compareToDatset(float i, float j)
|
public float compareToDatset(float i, float j)
|
||||||
{
|
{
|
||||||
if (i > j)
|
if (i < j)
|
||||||
{
|
{
|
||||||
return (i / j) * 0.15f;
|
return (i / j);
|
||||||
}
|
|
||||||
else if (i < j / 2)
|
|
||||||
{
|
|
||||||
return (i / j) * 2f;
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
return i / j;
|
return (j / i);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -17,9 +17,9 @@ class SoilProperties
|
|||||||
public float Nitrogen;
|
public float Nitrogen;
|
||||||
public float Potassium;
|
public float Potassium;
|
||||||
public float Phosphorous;
|
public float Phosphorous;
|
||||||
public float NitrogenDegradeRate = 0.001f;
|
public float NitrogenDegradeRate = 0.01f;
|
||||||
public float PotassiumDegradeRate = 0.001f;
|
public float PotassiumDegradeRate = 0.01f;
|
||||||
public float PhosphorousDegradeRate = 0.001f;
|
public float PhosphorousDegradeRate = 0.01f;
|
||||||
|
|
||||||
public void setSoilProperties()
|
public void setSoilProperties()
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user