Poikilos / EnlivenMinetest

Minetest engine server management tools and ENLIVEN game installer/updater

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Once you click a game, you can never again see the worlds with their own games.

Poikilos opened this issue · comments

Tested in copy from build server 2023-08-05

A disadvantage of keeping the game in the world directory (as opposed to games) is that once a person ever clicks bucket_game or meselite_game in the main menu, they can never "un" set the last used game, and the worlds not using either of them are hidden forever.

There should be some way for the GUI to not only list worlds for the current game, but also worlds which have their own "game" subdirectory (must be called "game" not something else _game--see issue #602)...

  • Add an "all worlds" that lists all words in the GUI not filtered by game?
  • Add an "other worlds" button that resets (to nothing) or deletes the menu_last_game setting (and then refreshing the list like occurs when a game is clicked)? This would at least show the worlds with their own games.

Quick Fix--move games to games:
These steps respect the Minetest convention that "_game" (case-sensitive) is removed from the name of the game in memory.

  • Do not rename the directories as desribed above (keep full name of directory).
  • Move each game directory to the games directory (instead of in the world).
  • In bytesize/world.mt, change gameid = bytesize_game to gameid = bytesize
  • In bytesize/world.mt, change gameid = bucketcity_game to gameid = bucketcity

Workaround:

  • first fix #602:
    • rename bucketcity_game to game (must be in bucketcity dir for this to work)
    • rename bytesize_game to game (must be in bytesize dir for this to work)
  • then patch builtin/mainmenu/init.lua:
             core.settings:set("menu_last_game", default_game)
         end
+        if menustyle ~= "simple" then
+            -- if the game designer has *not* forced a particular game in Minetest
+            -- then show all of the worlds even those with builtin games:
+            core.settings:set("menu_last_game", "")
+        end
 
         mm_texture.init()
     end

closed in git 2023-08-14