Merge pull request #750 from vishal332008/main

Removing the hard-coded lines.
This commit is contained in:
Eric Froemling 2025-01-17 11:16:19 -08:00 committed by GitHub
commit bc2d097c5b
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 25 additions and 21 deletions

View File

@ -178,27 +178,7 @@ class ClassicAppSubsystem(babase.AppSubsystem):
if not env.debug and not env.test and not plus.is_blessed():
babase.screenmessage('WARNING: NON-BLESSED BUILD', color=(1, 0, 0))
# FIXME: This should not be hard-coded.
for maptype in [
stdmaps.HockeyStadium,
stdmaps.FootballStadium,
stdmaps.Bridgit,
stdmaps.BigG,
stdmaps.Roundabout,
stdmaps.MonkeyFace,
stdmaps.ZigZag,
stdmaps.ThePad,
stdmaps.DoomShroom,
stdmaps.LakeFrigid,
stdmaps.TipTop,
stdmaps.CragCastle,
stdmaps.TowerD,
stdmaps.HappyThoughts,
stdmaps.StepRightUp,
stdmaps.Courtyard,
stdmaps.Rampage,
]:
bascenev1.register_map(maptype)
stdmaps.register_all_maps()
spazappearance.register_appearances()
bascenev1.init_campaigns()

View File

@ -15,6 +15,30 @@ if TYPE_CHECKING:
from typing import Any
def register_all_maps() -> None:
"""Registering all maps."""
for maptype in [
HockeyStadium,
FootballStadium,
Bridgit,
BigG,
Roundabout,
MonkeyFace,
ZigZag,
ThePad,
DoomShroom,
LakeFrigid,
TipTop,
CragCastle,
TowerD,
HappyThoughts,
StepRightUp,
Courtyard,
Rampage,
]:
bs.register_map(maptype)
class HockeyStadium(bs.Map):
"""Stadium map used for ice hockey games."""