Merge pull request #708 from kdau/develop
Set daysPlayed in date console commands
This commit is contained in:
commit
6437b7fa50
|
@ -1,4 +1,5 @@
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
|
using StardewModdingAPI.Utilities;
|
||||||
using StardewValley;
|
using StardewValley;
|
||||||
|
|
||||||
namespace StardewModdingAPI.Mods.ConsoleCommands.Framework.Commands.World
|
namespace StardewModdingAPI.Mods.ConsoleCommands.Framework.Commands.World
|
||||||
|
@ -32,6 +33,7 @@ namespace StardewModdingAPI.Mods.ConsoleCommands.Framework.Commands.World
|
||||||
|
|
||||||
// handle
|
// handle
|
||||||
Game1.dayOfMonth = day;
|
Game1.dayOfMonth = day;
|
||||||
|
Game1.stats.DaysPlayed = (uint)SDate.Now().DaysSinceStart;
|
||||||
monitor.Log($"OK, the date is now {Game1.currentSeason} {Game1.dayOfMonth}.", LogLevel.Info);
|
monitor.Log($"OK, the date is now {Game1.currentSeason} {Game1.dayOfMonth}.", LogLevel.Info);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
|
using StardewModdingAPI.Utilities;
|
||||||
using StardewValley;
|
using StardewValley;
|
||||||
|
|
||||||
namespace StardewModdingAPI.Mods.ConsoleCommands.Framework.Commands.World
|
namespace StardewModdingAPI.Mods.ConsoleCommands.Framework.Commands.World
|
||||||
|
@ -40,6 +41,7 @@ namespace StardewModdingAPI.Mods.ConsoleCommands.Framework.Commands.World
|
||||||
// handle
|
// handle
|
||||||
Game1.currentSeason = season.ToLower();
|
Game1.currentSeason = season.ToLower();
|
||||||
Game1.setGraphicsForSeason();
|
Game1.setGraphicsForSeason();
|
||||||
|
Game1.stats.DaysPlayed = (uint)SDate.Now().DaysSinceStart;
|
||||||
monitor.Log($"OK, the date is now {Game1.currentSeason} {Game1.dayOfMonth}.", LogLevel.Info);
|
monitor.Log($"OK, the date is now {Game1.currentSeason} {Game1.dayOfMonth}.", LogLevel.Info);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
|
using StardewModdingAPI.Utilities;
|
||||||
using StardewValley;
|
using StardewValley;
|
||||||
|
|
||||||
namespace StardewModdingAPI.Mods.ConsoleCommands.Framework.Commands.World
|
namespace StardewModdingAPI.Mods.ConsoleCommands.Framework.Commands.World
|
||||||
|
@ -32,6 +33,7 @@ namespace StardewModdingAPI.Mods.ConsoleCommands.Framework.Commands.World
|
||||||
|
|
||||||
// handle
|
// handle
|
||||||
Game1.year = year;
|
Game1.year = year;
|
||||||
|
Game1.stats.DaysPlayed = (uint)SDate.Now().DaysSinceStart;
|
||||||
monitor.Log($"OK, the year is now {Game1.year}.", LogLevel.Info);
|
monitor.Log($"OK, the year is now {Game1.year}.", LogLevel.Info);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue