Document Your Mod Mod

Document Your Mod Mod

606k Downloads

Some documentation is added out of order

aaronhowser1 opened this issue · 4 comments

commented

rope__dispenser.json loads before rope.json, which means
image
this is the first page of the documentation, instead of
image

commented

image
because I keep forgetting to do this, putting a reminder here

commented

This time it loaded it correctly. Weird.

debug.log
latest.log

@TheSilkMiner

commented

The log doesn't give any clue here, it seems stuff is getting loaded correctly in alphabetical order. It is probably a one-off error, but relying on something that is as ephemeral as that is probably a Very-Bad-Idea™.

Proposed fix:
Add a dependencies optional section in the JSON file that acts similar to Forge's Mod#dependencies string.

Schema:
"requirements": [
  {
    "order": "before" | "after",
    "required": true | false (optional, assumed false),
    "registry_name": "modid:registry_name"
  }, (multiple supported)
]

Questions

  • Should cross-mod requirements be handled or ignored? (e.g. tconstruct:ladder that depends on quark:stairs)
  • In case a cyclic dependency is present, should it be undefined behavior (no particular loading order) or should it outright crash?
  • In case of multiple conflicting requirements (e.g. a before and after that match the same registry name for the same entry), should the loading crash or the entry be skipped with a warning?
  • Should not satisfied requirements cause a crash?
commented

Discord Integration

  • Handled
  • Crash
  • Crash
  • No