Skip to content

Scenario syntax for selectively removing entities and recipes #864

Open
@byorgey

Description

Currently, scenarios can define custom entities and recipes that should be available in addition to all the "standard" entities and recipes. However, it would be nice (and hopefully not too difficult) if scenarios could have even more control over what entities and recipes will be available. For example, what if you wanted to

  • Create a scenario where using a harvester is not allowed, so the player has to be very frugal/precise in their use of available resources?
  • Create a scenario with a completely different set of entities?

Concretely, I propose

  1. There should be a way to remove specific entities by name. e.g. perhaps within the entities list you can put something like no: harvester or delete: harvester instead of describing a custom entity. Like this:
    entities:
      - name: thing
        ...
      - no: harvester
    
    I guess we'd have to parse such a thing as a list of "entity map edits" instead of directly as a list of entities. Alternatively, we could just have a separate top-level list of entities to remove.
  2. There should also be a way to completely clear the list of standard entities, like a top level boolean field standard-entities.
    standard-entities: false
    entities:
      ...
    
    You could use this if you want to design a custom set of entities from scratch.
  3. Likewise, there should be a way to remove specific recipies. Since recipies aren't named you would just have to describe the recipe you want to remove.
  4. Also likewise, there should be a way to clear all standard recipes.

I think the above is a bare minimum, but we might also consider adding more nuanced ways to edit the available entities and recipes, such as allowing some sort of filtering or wilcard matching (e.g. "remove all entities with the substring drill in their name", "remove all recipes requiring iron gear as an input", etc.)

This idea originally came out of a discussion here: #831 (comment) .

Metadata

Assignees

No one assigned

    Labels

    C-Moderate EffortShould take a moderate amount of time to address.G-EntitiesAn issue having to do with game entities.G-RecipesAn issue having to do with recipes.G-ScenariosAn issue having to do with scenario design, the way scenarios are described and loaded, etc.S-Nice to haveThe bug fix or feature would be nice but doesn't currently have much negative impact.T-ChallengesInvolves the challenge scenarios - shorter games with objectives.Z-FeatureA new feature to be added to the game.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions