Exemplo n.º 1
0
        public void Divorce(string NPC)
        {
            bool swap = false;

            if (PrimarySpouse == NPC)
            {
                StorePrimarySpouse();
                swap = true;
            }
            Modworks.Player.SetFriendshipPoints(NPC, 0);
            Modworks.Player.SetFriendshipStatus(NPC, FriendshipStatus.Divorced);
            Dates.Remove(NPC);
            Engagements.Remove(NPC);
            Spouses.Remove(NPC);
            Divorces.Add(NPC);
            if (swap)
            {
                MakePrimarySpouse(GetNextPrimarySpouse());
            }
            //delete the NPC
            var npc = Game1.getCharacterFromName(NPC);

            npc.currentLocation.characters.Remove(npc);
            npc = null;
        }
Exemplo n.º 2
0
 public void Engage(string NPC, bwdyworks.GameDate weddingDay = null)
 {
     //var backup = Game1.player.spouse;
     //Game1.player.spouse = NPC;
     SetDateable(NPC, true);
     if (weddingDay == null)
     {
         weddingDay = bwdyworks.GameDate.CreateWeddingDate();
     }
     Modworks.Log.Info("Engaged to " + NPC + ", to be wed on " + weddingDay.GetSeasonString() + " " + weddingDay.Day);
     StorePrimarySpouse();
     if (Modworks.Player.GetFriendshipPoints(NPC) < 2500)
     {
         Modworks.Player.SetFriendshipPoints(NPC, 2500);
     }
     Modworks.Player.SetFriendshipStatus(NPC, FriendshipStatus.Engaged);
     //Game1.player.spouse = NPC;
     Game1.player.friendshipData[NPC].Proposer    = Game1.player.UniqueMultiplayerID;
     Game1.player.friendshipData[NPC].WeddingDate = new WorldDate(Game1.year, weddingDay.GetSeasonString().ToLower(), weddingDay.Day);
     Spouses.Remove(NPC);
     Dates.Remove(NPC);
     Divorces.Remove(NPC);
     Engagements.Add(NPC, weddingDay);
     //Game1.player.spouse = backup;
 }
Exemplo n.º 3
0
 public void Forget(string NPC, bool resetFriendship = true)
 {
     if (resetFriendship)
     {
         Modworks.Player.SetFriendshipPoints(NPC, 0);
     }
     Modworks.Player.SetFriendshipStatus(NPC, FriendshipStatus.Friendly);
     Spouses.Remove(NPC);
     Engagements.Remove(NPC);
     Divorces.Remove(NPC);
     Dates.Remove(NPC);
 }
Exemplo n.º 4
0
 public void Date(string NPC)
 {
     SetDateable(NPC, true);
     if (Modworks.Player.GetFriendshipPoints(NPC) < 2000)
     {
         Modworks.Player.SetFriendshipPoints(NPC, 2000);
     }
     Modworks.Player.SetFriendshipStatus(NPC, FriendshipStatus.Dating);
     Spouses.Remove(NPC);
     Engagements.Remove(NPC);
     Divorces.Remove(NPC);
     Dates.Add(NPC);
 }
Exemplo n.º 5
0
 public void MakePrimarySpouse(string NPC)
 {
     if (PrimarySpouse == NPC ^ VanillaSpouse == NPC)
     {
         StorePrimarySpouse();
     }
     if (!CheckMarriedProper(NPC))
     {
         Marry(NPC);
     }
     Spouses.Remove(NPC);
     PrimarySpouse = NPC;
     VanillaSpouse = NPC;
     RollSpouseRoom();
 }