private void DontLoadRandoMaps(On.Celeste.MapData.orig_Load orig, MapData self)
 {
     if (self.Data?.GetSID()?.StartsWith("randomizer/") ?? false)
     {
         return;
     }
     orig(self);
 }
Example #2
0
        private static void onMapDataLoad(On.Celeste.MapData.orig_Load orig, MapData self)
        {
            orig(self);

            // if the map data processor detected secret berries that should count towards the total... add them to the total.
            if (MaxHelpingHandMapDataProcessor.DetectedSecretBerries > 0)
            {
                self.ModeData.TotalStrawberries += MaxHelpingHandMapDataProcessor.DetectedSecretBerries;
                MaxHelpingHandMapDataProcessor.DetectedSecretBerries = 0;
            }
        }
Example #3
0
        private static void ModMapDataLoad(On.Celeste.MapData.orig_Load orig, MapData self)
        {
            orig(self);

            // add the silver/rainbow berries as golden berries in map data. This is what will make the chapter card golden.
            foreach (LevelData level in self.Levels)
            {
                foreach (EntityData entity in level.Entities)
                {
                    if (entity.Name == "CollabUtils2/SilverBerry" || entity.Name == "CollabUtils2/RainbowBerry")
                    {
                        self.Goldenberries.Add(entity);
                    }
                }
            }
        }
Example #4
0
        private static void modMapDataLoad(On.Celeste.MapData.orig_Load orig, MapData self)
        {
            orig(self);

            // if the option is enabled, register golden berries with custom conditions as golden berries.
            foreach (LevelData level in self.Levels)
            {
                foreach (EntityData entity in level.Entities)
                {
                    if (entity.Name == "MaxHelpingHand/GoldenStrawberryCustomConditions" && entity.Bool("showGoldenChapterCard", true))
                    {
                        self.Goldenberries.Add(entity);
                    }
                }
            }
        }