Add Campsite Editor (#707)

Add: Campsite Editor to Map tab.
Allows users to set whether there is or is not a villager visiting the campsite, allows selecting that visitor and to edit the visit timestamp (defaults to current timestamp override so visitor is there on same day load).
Back-tracked offsets from old Cylindircal Earth save schemas for old save revs.
If campsite is not unlocked on the save, the UI is locked out with a message.

Cleanup: Moved UpdateFruitsFlag to misc editor class over save class because that was bad form. Oops.
This commit is contained in:
Josh (vector_cmdr)
2026-01-21 23:36:12 +11:00
committed by GitHub
parent c3371475d4
commit 2c8de97ca1
22 changed files with 635 additions and 54 deletions

View File

@@ -62,6 +62,30 @@ private void B_Save_Click(object sender, EventArgs e)
Close();
}
public void UpdateFruitFlags(MainSave sav)
{
var fruit = new byte[] { 00, 00, 00, 00, 00 };
switch (sav.SpecialtyFruit)
{
case 2213: // Apple
fruit[0] = 01;
break;
case 2287: // Cherry
fruit[4] = 01;
break;
case 2214: // Orange
fruit[1] = 01;
break;
case 2286: // Peach
fruit[3] = 01;
break;
case 2285: // Pear
fruit[2] = 01;
break;
}
sav.FruitFlags = fruit;
}
private void SavePlayer()
{
var p = Player;
@@ -80,7 +104,8 @@ private void SavePlayer()
pers.ProfileFruit = RIS_ProfileFruit.Value;
sav.SpecialtyFruit = RIS_ProfileFruit.Value;
sav.SisterFruit = RIS_SisterFruit.Value;
sav.UpdateFruitFlags();
UpdateFruitFlags(sav);
sav.SpecialtyFlower = (IslandFlowers)CB_ProfileFlower.SelectedIndex;
sav.SisterFlower = (IslandFlowers)CB_SisterFlower.SelectedIndex;