Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refactoring: Implement game module system more consistently #138

Merged
merged 44 commits into from
Dec 17, 2024

Conversation

RedstoneFuture
Copy link
Owner

@RedstoneFuture RedstoneFuture commented Dec 13, 2024

Overview

  • Misc code refactoring
  • Improving default settings for missiles.folder and shields.folder
  • Reworking plugin info message for startup
  • Refactoring Schematic-Paster initialization
  • Reworking default file (ZIP files) saving
  • Refactoring: Reworking config file management
    • Adding ConfigLoader.class, FileManager.class
    • Removing SetupUtil.class
  • Updating server version check
  • Improving game module system:
    • Updating config settings from [...]_lobby_[...] to [...]_games_[...]
    • Restructure and renaming classes, methods and fields
    • Renaming PAPI placeholders of MW from [...]_lobby_[...] to [...]_games_[...]
    • Renaming basic message placeholders from %lobby_name% to %game_name%
    • Restructuring the configs:
      • Renaming folder and file from MissileWars/lobbies/lobby0.yml to MissileWars/games/game0.yml
      • The game config includes now a lobby: ... part (see screenshot below)

Wiki-Update

  • First configuration with new Game config name (here)
  • Update of PAPI placeholders with new names (here)
  • [NEW] Description of the "Game Module System" with the config dependencies (here)

Change of the MW "Game Module System"

MissileWars has a kind of modular system internally:
One game has 1x lobby and several arenas in the form of one world each, whereby several lobbies can have the same arena.

With this PR I would like to make a structural change to the plugin and its components.

Despite this concept where we currently distinguish between the lobby and the arena, e.g. :

  • in the folder structure (/lobby and /arena)
  • in the PAPI placeholders (%missilewars_lobby_gamestate_<lobby-name>%)
  • in many places in the code internally

The "lobby" is meant once as a game object and once as a lobby region, which leads to this kind of inconsistent and confusing spellings.

With this PR a clear difference will be made between the game, its arena and the lobbies. However, this will mainly affect the names and the folder structure (see screenshot) and will therefore not have any major impact on functionality. It's just a formality! This is a more accurate realization of the actual module system of MissileWars.

grafik

@RedstoneFuture RedstoneFuture changed the title Refactoring/misc Refactoring: Implement game module system more consistently Dec 16, 2024
@RedstoneFuture RedstoneFuture marked this pull request as ready for review December 17, 2024 13:50
@RedstoneFuture RedstoneFuture merged commit 37f1559 into master Dec 17, 2024
0 of 2 checks passed
@RedstoneFuture RedstoneFuture deleted the refactoring/misc branch December 17, 2024 13:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant