forked from Mirrors/openclonk
fixed cloud movement in ironpeak(#1149)
parent
1d34c12431
commit
83930ee27f
|
@ -231,8 +231,8 @@ private func RainDrop(string mat)
|
|||
// Check if liquid is maybe in frozen form.
|
||||
var temp = GetTemperature();
|
||||
var melt_temp = GetMaterialVal("BelowTempConvert", "Material", Material(mat));
|
||||
if (temp < melt_temp)
|
||||
mat = GetMaterialVal("BelowTempConvertTo", "Material", Material(mat));
|
||||
if (melt_temp != nil && temp < melt_temp)
|
||||
mat = GetMaterialVal("BelowTempConvertTo", "Material", Material(mat));
|
||||
// Create rain drop.
|
||||
CastPXS(mat, 1, 1, x, y);
|
||||
return true;
|
||||
|
@ -290,7 +290,7 @@ protected func Evaporation()
|
|||
y += prec;
|
||||
|
||||
// Try to extract the specified material.
|
||||
if(GetMaterial(evap_x, y) == Material(rain_mat))
|
||||
if (GetMaterial(evap_x, y) == Material(rain_mat))
|
||||
{
|
||||
ExtractMaterialAmount(evap_x, y, Material("Water"), 3);
|
||||
rain += 3;
|
||||
|
|
|
@ -106,6 +106,11 @@ private func InitEnvironment(int difficulty)
|
|||
|
||||
// Set time of day to evening and create some clouds and celestials.
|
||||
Cloud->Place(20);
|
||||
Cloud->SetPrecipitation("Snow", 20 + 5 * difficulty);
|
||||
for (var cloud in FindObjects(Find_ID(Cloud)))
|
||||
while (cloud->RemoveVertex())
|
||||
/* Empty */;
|
||||
|
||||
CreateObject(Environment_Celestial);
|
||||
var time = CreateObject(Environment_Time);
|
||||
time->SetTime(60 * 22);
|
||||
|
|
Loading…
Reference in New Issue