Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public void PopulateFinderSlots()
- {
- List<GirlDefinition> allBySpecial = Game.Data.Girls.GetAllBySpecial(false);
- Dictionary<GirlDefinition, PlayerFileGirl> dictionary = new Dictionary<GirlDefinition, PlayerFileGirl>();
- for (int i = 0; i < allBySpecial.Count; i++)
- {
- dictionary.Add(allBySpecial[i], this.GetPlayerFileGirl(allBySpecial[i]));
- }
- List<GirlPairDefinition> allBySpecial2 = Game.Data.GirlPairs.GetAllBySpecial(false);
- List<PlayerFileGirlPair> list = new List<PlayerFileGirlPair>();
- for (int j = 0; j < allBySpecial2.Count; j++)
- {
- list.Add(this.GetPlayerFileGirlPair(allBySpecial2[j]));
- }
- ListUtils.ShuffleList<PlayerFileGirlPair>(list);
- if (this.girlPairDefinition != null)
- {
- this.AddToFinderLists(null, null, this.girlPairDefinition, null, list);
- }
- for (int k = 0; k < list.Count; k++)
- {
- if (!dictionary[list[k].girlPairDefinition.girlDefinitionOne].playerMet && !dictionary[list[k].girlPairDefinition.girlDefinitionTwo].playerMet)
- {
- list.RemoveAt(k);
- k--;
- }
- }
- List<GirlPairDefinition> list2 = new List<GirlPairDefinition>();
- List<LocationDefinition> list3 = new List<LocationDefinition>();
- for (int l = 0; l < list.Count; l++)
- {
- if (list[l].relationshipType == GirlPairRelationshipType.ATTRACTED && (this.daytimeElapsed + ClockDaytimeType.AFTERNOON) % (ClockDaytimeType)4 == list[l].girlPairDefinition.sexDaytime)
- {
- l = this.AddToFinderLists(list2, list3, list[l].girlPairDefinition, null, list);
- }
- }
- for (int m = 0; m < list.Count; m++)
- {
- if (list[m].relationshipType == GirlPairRelationshipType.UNKNOWN && list[m].girlPairDefinition.introductionPair && list[m].girlPairDefinition.meetingLocationDefinition != this.locationDefinition && !list3.Contains(list[m].girlPairDefinition.meetingLocationDefinition))
- {
- m = this.AddToFinderLists(list2, list3, list[m].girlPairDefinition, list[m].girlPairDefinition.meetingLocationDefinition, list);
- }
- }
- for (int n = 0; n < list.Count; n++)
- {
- if ((list[n].relationshipType == GirlPairRelationshipType.UNKNOWN && !list[n].girlPairDefinition.introductionPair && list[n].girlPairDefinition.meetingLocationDefinition != this.locationDefinition && !list3.Contains(list[n].girlPairDefinition.meetingLocationDefinition) && dictionary[list[n].girlPairDefinition.girlDefinitionOne].playerMet && dictionary[list[n].girlPairDefinition.girlDefinitionTwo].playerMet) || list[n].relationshipType == GirlPairRelationshipType.COMPATIBLE)
- {
- n = this.AddToFinderLists(list2, list3, list[n].girlPairDefinition, (list[n].relationshipType == GirlPairRelationshipType.UNKNOWN) ? list[n].girlPairDefinition.meetingLocationDefinition : null, list);
- }
- }
- for (int num = 0; num < list.Count; num++)
- {
- if (list[num].relationshipType == GirlPairRelationshipType.LOVERS)
- {
- num = this.AddToFinderLists(list2, list3, list[num].girlPairDefinition, null, list);
- }
- }
- if (list2.Count <= 0)
- {
- for (int num2 = 0; num2 < list.Count; num2++)
- {
- if (list[num2].relationshipType == GirlPairRelationshipType.ATTRACTED)
- {
- num2 = this.AddToFinderLists(list2, list3, list[num2].girlPairDefinition, null, list);
- }
- }
- }
- List<LocationDefinition> allByLocationType = Game.Data.Locations.GetAllByLocationType(LocationType.SIM);
- Dictionary<LocationDefinition, PlayerFileFinderSlot> dictionary2 = new Dictionary<LocationDefinition, PlayerFileFinderSlot>();
- for (int num3 = 0; num3 < allByLocationType.Count; num3++)
- {
- PlayerFileFinderSlot playerFileFinderSlot = this.GetPlayerFileFinderSlot(allByLocationType[num3]);
- playerFileFinderSlot.Clear();
- dictionary2.Add(allByLocationType[num3], playerFileFinderSlot);
- }
- if (allByLocationType.Contains(this.locationDefinition))
- {
- allByLocationType.Remove(this.locationDefinition);
- }
- ListUtils.RemoveRangeUnique<LocationDefinition>(allByLocationType, list3);
- for (int num4 = 0; num4 < list2.Count; num4++)
- {
- LocationDefinition locationDefinition = list3[num4];
- if (locationDefinition == null)
- {
- locationDefinition = allByLocationType[Random.Range(0, allByLocationType.Count)];
- allByLocationType.Remove(locationDefinition);
- }
- bool flipped = (!list2[num4].specialPair && list2[num4].introductionPair && this.GetPlayerFileGirlPair(list2[num4]).relationshipType == GirlPairRelationshipType.UNKNOWN) ? list2[num4].introSidesFlipped : MathUtils.RandomBool();
- dictionary2[locationDefinition].Populate(list2[num4], flipped);
- }
- }
- // Token: 0x06000375 RID: 885 RVA: 0x0001D3E0 File Offset: 0x0001B5E0
- private int AddToFinderLists(List<GirlPairDefinition> girlPairList, List<LocationDefinition> locationList, GirlPairDefinition girlPairDef, LocationDefinition locationDef, List<PlayerFileGirlPair> fileGirlPairs)
- {
- if (girlPairList != null && !girlPairList.Contains(girlPairDef))
- {
- girlPairList.Add(girlPairDef);
- if (locationList != null && (locationDef == null || !locationList.Contains(locationDef)))
- {
- locationList.Add(locationDef);
- }
- }
- for (int i = 0; i < fileGirlPairs.Count; i++)
- {
- if (fileGirlPairs[i].girlPairDefinition.girlDefinitionOne == girlPairDef.girlDefinitionOne || fileGirlPairs[i].girlPairDefinition.girlDefinitionTwo == girlPairDef.girlDefinitionOne || fileGirlPairs[i].girlPairDefinition.girlDefinitionOne == girlPairDef.girlDefinitionTwo || fileGirlPairs[i].girlPairDefinition.girlDefinitionTwo == girlPairDef.girlDefinitionTwo)
- {
- fileGirlPairs.RemoveAt(i);
- i--;
- }
- }
- return -1;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement