Browse Source

Remove code that used unneeded `MapList_Feature`

pull/2/head
Anton Tarasenko 2 years ago
parent
commit
11610dc9d2
  1. 2
      sources/MapList/MapList.uc
  2. 3
      sources/StartUp.uc
  3. 6
      sources/VotingHandlerAdapter.uc

2
sources/MapList/MapList.uc

@ -1,5 +1,5 @@
/** /**
* Config for `MapList_Feature`. * Config class for storing map lists.
* Copyright 2023 Anton Tarasenko * Copyright 2023 Anton Tarasenko
* 2023 Shtoyan * 2023 Shtoyan
*------------------------------------------------------------------------------ *------------------------------------------------------------------------------

3
sources/StartUp.uc

@ -126,9 +126,6 @@ public function array<Packages.FeatureConfigPair> GetAutoConfigurationInfo()
local array<Packages.FeatureConfigPair> result; local array<Packages.FeatureConfigPair> result;
availableFeatures = _.environment.GetAvailableFeatures(); availableFeatures = _.environment.GetAvailableFeatures();
// We only have a single feature, so instead of adding our own manifest, simply add it here
class'MapList_Feature'.static.LoadConfigs();
availableFeatures[availableFeatures.length] = class'MapList_Feature';
for (i = 0; i < availableFeatures.length; i += 1) for (i = 0; i < availableFeatures.length; i += 1)
{ {
autoConfig = availableFeatures[i].static.GetAutoEnabledConfig(); autoConfig = availableFeatures[i].static.GetAutoEnabledConfig();

6
sources/VotingHandlerAdapter.uc

@ -141,15 +141,9 @@ public final function InjectIntoVotingHandler()
} }
public function TrySetupMapList() { public function TrySetupMapList() {
local MapList_Feature mapListFeature;
local Text currentConfigName; local Text currentConfigName;
local MapList currentConfig; local MapList currentConfig;
mapListFeature = MapList_Feature(class'MapList_Feature'.static.GetEnabledInstance());
if (mapListFeature == none) {
return;
}
currentConfigName = mapListFeature.GetCurrentConfig();
if (currentConfigName != none) { if (currentConfigName != none) {
currentConfig = MapList(class'MapList'.static.GetConfigInstance(currentConfigName)); currentConfig = MapList(class'MapList'.static.GetConfigInstance(currentConfigName));
} }

Loading…
Cancel
Save