Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions .github/workflows/run_scripts.yml
Original file line number Diff line number Diff line change
Expand Up @@ -58,12 +58,15 @@ jobs:
python ./resources/ci/common/list_actions.py
# Run Strat ID validator
# Run Autoformatter
- name: Run Strat ID Generator & Autoformatter
- name: Run Strat ID Generator
working-directory: scripts
run: python populate_strat_ids.py
- name: Run Tech ID Generator & Autoformatter
- name: Run Tech ID Generator
working-directory: scripts
run: python populate_tech_ids.py
- name: Run Autoformatter
working-directory: scripts
run: python autoformat.py
- name: Create Pull Request
uses: peter-evans/create-pull-request@v6.1.0
with:
Expand Down
8 changes: 4 additions & 4 deletions schema/m3-room.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -1263,14 +1263,14 @@
"description": "Represents that Samus can leave through this door by jumping from a platform to the side, carrying upward momentum into the next room.",
"required": ["runway", "height", "obstruction"],
"properties": {
"runway": {
"$ref": "#/definitions/runway",
"description": "Runway available to jump through the door, including unusable parts of the runway near an obstruction."
},
"height": {
"type": "number",
"description": "The vertical position of the runway, measured in number of tiles below the doorway, at the location where Samus would jump."
},
"runway": {
"$ref": "#/definitions/runway",
"description": "Runway available to jump through the door, including unusable parts of the runway near an obstruction."
},
"obstruction": {
"type": "array",
"description": "Coordinates of the block that most restricts where Samus can jump, measured relative to the floor below the transition.",
Expand Down
4 changes: 2 additions & 2 deletions scripts/format_json.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,15 +25,15 @@ def is_one_liner_dict(obj, parent_keys, nesting_allowed=True):
return False
if any(not is_allowed_one_line_key(x, parent_keys) for x in obj.keys()):
return False
if len(obj) == 0:
if all(is_simple_value(x) for x in obj.values()):
return True
if len(obj) == 1:
key, value = next(iter(obj.items()))
if not is_allowed_one_line_key(key, parent_keys):
return False
return is_one_liner(value, parent_keys + [key], nesting_allowed=nesting_allowed)
else:
return all(is_simple_value(x) for x in obj.values())
return False


def is_one_liner_list(obj, parent_keys, nesting_allowed=True):
Expand Down