# From The Skies

`From The Skies` is a NeoForge mod project for Minecraft `1.21.1`. The codebase currently contains custom blocks, items, entities, worldgen content, data generators, and a takeover system centered on a persistent alien invasion event in the Overworld.

The project targets:

- Minecraft `1.21.1`
- NeoForge `21.1.218`
- Java `21`
- Mod ID `fromtheskiesmcmod`

## Directory Structure

At the repository level, the project deliverables are organized as follows:

```text
Code/
  Source code and all technical components of the mod.
  See the Installation Guide for setup instructions.

  README.md                Project overview and code structure.
  Installation Guide.txt   Step-by-step setup for developers and end users.
  User Manual.txt          How to play and interact with the mod.

Documents/
  Project documentation, scrum minutes, and supporting artifacts.

Posters/
  Team poster (36"x48" horizontal format).

Presentation Slides/
  Final team presentation PowerPoint.

Videos/
  index.html linking to all four required YouTube videos:
    - IntroVideo
    - UserGuide
    - InstallMaintenanceGuide
    - ShortcomingsWishlist
```

The repository is organized around the standard NeoForge/Gradle layout, with a few project-specific folders for takeover logic and generated data.

```text
FromTheSkies-1.21.X/
├── .github/workflows/          CI build pipeline
├── build.gradle                Gradle build, NeoForge runs, Java toolchain
├── gradle.properties           Minecraft/NeoForge versions and mod metadata
├── gradlew / gradlew.bat       Gradle wrapper for macOS/Linux and Windows
├── run/                        Local development run directory
├── src/
│   ├── generated/resources/    Data-generated assets and data files
│   └── main/
│       ├── java/net/jaftsun/fromtheskies/
│       │   ├── block/          Block registration and custom block classes
│       │   ├── datagen/        Data generation providers
│       │   ├── entity/         Entity types, renderers, models, animations
│       │   ├── item/           Items, creative tabs, tool tiers
│       │   ├── registry/       Item registration helpers
│       │   ├── takeover/       Takeover lifecycle, commands, saved data, services
│       │   ├── util/           Shared tags/utilities
│       │   ├── worldgen/       Configured features, placed features, biome modifiers
│       │   ├── Config.java     Common config definition
│       │   └── FromTheSkies.java  Main mod entrypoint
│       ├── resources/
│       │   ├── assets/fromtheskiesmcmod/  Textures, lang, blockstates, models, animations
│       │   └── data/fromtheskiesmcmod/    Worldgen and data pack resources
│       └── templates/META-INF/  `neoforge.mods.toml` template expanded at build time
├── takeover-code-overview.md   Supplemental takeover notes
└── takeover-confusing-parts.md Supplemental takeover notes
```

### Important Source Areas

- `src/main/java/net/jaftsun/fromtheskies/FromTheSkies.java` registers blocks, items, entities, config, game tests, and client hooks.
- `src/main/java/net/jaftsun/fromtheskies/Config.java` defines the common takeover configuration that becomes the TOML file used at runtime.
- `src/main/java/net/jaftsun/fromtheskies/takeover/command/TakeoverCommands.java` defines the `/fts takeover` command tree.
- `src/main/java/net/jaftsun/fromtheskies/takeover/event/TakeoverServerEvents.java` wires takeover ticking, chunk tracking, and command registration into NeoForge events.
- `src/generated/resources/` contains generated blockstates, models, tags, recipes, loot tables, and worldgen data. Regenerate these with the data run instead of hand-editing them unless you have a specific reason.

## Related Documents

- `Installation Guide.txt` contains the full setup flow for building and running the project.
- `User Manual.txt` contains gameplay instructions and the `/fts` command reference.

## Troubleshooting

- If dependencies are missing, run `./gradlew --refresh-dependencies`.
- If generated files appear stale, run `./gradlew clean runData`.
- If the client fails to launch, confirm the project is using Java `21`.
- If `/fts` commands do not work, verify cheats or operator permission level `2`.
- If takeover never starts naturally, inspect `run/config/fromtheskiesmcmod-common.toml` and confirm `enabled = true` and that the current dimension is listed in `allowedDimensions`.

## Mapping Names

By default, the MDK is configured to use the official mapping names from Mojang for methods and fields in the Minecraft codebase. These names are covered by a specific license. For the latest license text, refer to the mapping file itself, or the reference copy here:

https://github.com/NeoForged/NeoForm/blob/main/Mojang.md

## Additional Resources

- Community Documentation: https://docs.neoforged.net/
- NeoForged Discord: https://discord.neoforged.net/
