Update Docs Deps (#1020)

Upgrading to Astro 5
This commit is contained in:
xen-42 2025-01-06 16:52:57 -05:00 committed by GitHub
commit 1f44218e9c
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
14 changed files with 6275 additions and 6093 deletions

View File

@ -12,18 +12,18 @@
"format": "prettier --write ." "format": "prettier --write ."
}, },
"dependencies": { "dependencies": {
"@astrojs/starlight": "^0.24.2", "@astrojs/starlight": "^0.30.3",
"astro": "4.10.2", "astro": "5.1.3",
"rehype-external-links": "^3.0.0", "rehype-external-links": "^3.0.0",
"sharp": "^0.33.4" "sharp": "^0.33.5"
}, },
"devDependencies": { "devDependencies": {
"@apidevtools/json-schema-ref-parser": "^11.6.4", "@apidevtools/json-schema-ref-parser": "^11.7.3",
"eslint": "^8.56.0", "eslint": "^9.17.0",
"eslint-plugin-prettier": "^5.1.3", "eslint-plugin-prettier": "^5.2.1",
"fast-xml-parser": "^4.4.0", "fast-xml-parser": "^4.5.1",
"prettier": "^3.3.2", "prettier": "^3.4.2",
"prettier-plugin-astro": "^0.14.0", "prettier-plugin-astro": "^0.14.1",
"xml-js": "^1.6.11" "xml-js": "^1.6.11"
} }
} }

9757
docs/pnpm-lock.yaml generated

File diff suppressed because it is too large Load Diff

View File

@ -3,7 +3,7 @@ title: Update Existing Planets
description: A guide for updating base-game planets in New Horizons description: A guide for updating base-game planets in New Horizons
--- ---
Similar to above, make a config where "Name" is the name of the planet. The name should be able to just match their in-game english names, however if you encounter any issues with that here are the in-code names for planets that are guaranteed to work: Similar to above, make a config where "Name" is the name of the planet. The name should be able to just match their in-game english names, however if you encounter any issues with that here are the in-code names for planets that are guaranteed to work (case sensitive!):
- `SUN` - `SUN`
- `CAVE_TWIN` (Ember Twin) - `CAVE_TWIN` (Ember Twin)
@ -14,7 +14,7 @@ Similar to above, make a config where "Name" is the name of the planet. The name
- `DARK_BRAMBLE` - `DARK_BRAMBLE`
- `COMET` (Interloper) - `COMET` (Interloper)
- `WHITE_HOLE` - `WHITE_HOLE`
- `WHITE_HOLE_TARGET` (The Whitehole Station) - `WhiteholeStation`
- `QUANTUM_MOON` - `QUANTUM_MOON`
- `ORBITAL_PROBE_CANNON` - `ORBITAL_PROBE_CANNON`
- `TIMBER_MOON` (Attlerock) - `TIMBER_MOON` (Attlerock)

View File

@ -1,8 +1,8 @@
--- ---
title: Celestial Body Schema title: "Celestial Body Schema"
description: Describes a celestial body to generate description: "Describes a celestial body to generate"
editUrl: false editUrl: false
schemaFile: body_schema.json schemaFile: "body_schema.json"
--- ---
import Schema from "/src/components/Schemas/Schema.astro"; import Schema from "/src/components/Schemas/Schema.astro";

View File

@ -35,8 +35,7 @@ Once in VSCode, paste this code into the file:
"Base": { "Base": {
"groundSize": 100, "groundSize": 100,
"surfaceSize": 101, "surfaceSize": 101,
"surfaceGravity": 12, "surfaceGravity": 12
"hasMapMarker": true
}, },
"Orbit": { "Orbit": {
"semiMajorAxis": 1300, "semiMajorAxis": 1300,
@ -55,6 +54,9 @@ Once in VSCode, paste this code into the file:
"fogSize": 150, "fogSize": 150,
"fogDensity": 0.2, "fogDensity": 0.2,
"hasRain": true "hasRain": true
},
"MapMarker": {
"enabled": true
} }
} }
``` ```
@ -71,18 +73,19 @@ Alright so now that we understand how the file is structures, let's look into wh
- Base has a `groundSize` of 100, this generates a perfect sphere that is 100 units in radius as the ground of our planet - Base has a `groundSize` of 100, this generates a perfect sphere that is 100 units in radius as the ground of our planet
- It also has a `surfaceSize` of 101, surface size is used in many calculations, it's generally good to set it to a bit bigger than ground size. - It also has a `surfaceSize` of 101, surface size is used in many calculations, it's generally good to set it to a bit bigger than ground size.
- `surfaceGravity` describes the strength of gravity on this planet, in this case it's 12 which is the same as Timber Hearth - `surfaceGravity` describes the strength of gravity on this planet, in this case it's 12 which is the same as Timber Hearth
- `hasMapMarker` tells new horizons that we want this planet to have a marker on the map screen
- Next it has another object called `Orbit` - Next it has another object called `Orbit`
- `semiMajorAxis` specifies the radius of the orbit (how far away the body is from its parent) - `semiMajorAxis` specifies the radius of the orbit (how far away the body is from its parent)
- `primaryBody` is set to `TIMBER_HEARTH``, this makes our planet orbit timber hearth - `primaryBody` is set to `TIMBER_HEARTH``, this makes our planet orbit timber hearth
- `isMoon` simply tells the game how close you have to be to the planet in map mode before its name appears - `isMoon` simply tells the game how close you have to be to the planet in map mode before its name appears
- `isTidallyLocked` makes sure that one side of our planet is always facing timber hearth (the primary body) - `isTidallyLocked` makes sure that one side of our planet is always facing timber hearth (the primary body)
- Finally, we have `Atmosphere` - Next, we have `Atmosphere`
- Its `size` is 150, this simply sets how far away from the planet our atmosphere stretches - Its `size` is 150, this simply sets how far away from the planet our atmosphere stretches
- Its `fogTint` is set to a color which is an object with r, g, b, and a properties (properties is another word for keys) - Its `fogTint` is set to a color which is an object with r, g, b, and a properties (properties is another word for keys)
- `fogSize` determines how far away the fog stretches from the planet - `fogSize` determines how far away the fog stretches from the planet
- `fogDensity` is simply how dense the fog is - `fogDensity` is simply how dense the fog is
- `hasRain` makes rainfall on the planet - `hasRain` makes rainfall on the planet
- Finally, we have `MapMarker`
- `enabled` tells New Horizons that we want this planet to have a marker on the map screen
#### What's a Schema? #### What's a Schema?

View File

@ -5,7 +5,9 @@ const addFrontmatter = (
content: string, content: string,
frontmatter: Record<string, boolean | string | object> frontmatter: Record<string, boolean | string | object>
) => { ) => {
const entries = Object.entries(frontmatter).map(([key, value]) => `${key}: ${value}`); const entries = Object.entries(frontmatter).map(
([key, value]) => `${key}: ${JSON.stringify(value)}`
);
if (entries.length === 0) { if (entries.length === 0) {
return content; return content;