Skip to content

Commit

Permalink
Initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
Rektroth committed Jul 11, 2023
0 parents commit 9676077
Show file tree
Hide file tree
Showing 18 changed files with 1,430 additions and 0 deletions.
40 changes: 40 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
# Automatically build the project and run any configured tests for every push
# and submitted pull request. This can help catch issues that only occur on
# certain platforms or Java versions, and provides a first line of defence
# against bad commits.

name: build
on: [pull_request, push]

jobs:
build:
strategy:
matrix:
# Use these Java versions
java: [
17, # Current Java LTS & minimum supported by Minecraft
]
# and run on both Linux and Windows
os: [ubuntu-22.04, windows-2022]
runs-on: ${{ matrix.os }}
steps:
- name: checkout repository
uses: actions/checkout@v3
- name: validate gradle wrapper
uses: gradle/wrapper-validation-action@v1
- name: setup jdk ${{ matrix.java }}
uses: actions/setup-java@v3
with:
java-version: ${{ matrix.java }}
distribution: 'microsoft'
- name: make gradle wrapper executable
if: ${{ runner.os != 'Windows' }}
run: chmod +x ./gradlew
- name: build
run: ./gradlew build
- name: capture build artifacts
if: ${{ runner.os == 'Linux' && matrix.java == '17' }} # Only upload artifacts built from latest java on one OS
uses: actions/upload-artifact@v3
with:
name: Artifacts
path: build/libs/
40 changes: 40 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
# gradle

.gradle/
build/
out/
classes/

# eclipse

*.launch

# idea

.idea/
*.iml
*.ipr
*.iws

# vscode

.settings/
.vscode/
bin/
.classpath
.project

# macos

*.DS_Store

# fabric

run/

# java

hs_err_*.log
replay_*.log
*.hprof
*.jfr
674 changes: 674 additions & 0 deletions LICENSE

Large diffs are not rendered by default.

62 changes: 62 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
# Whiteout

Whiteout is an attempt to implement the bug fixes offered by the [Paper](https://github.com/PaperMC) project in Fabric.

## Patches
### Present

| Bug | Lazy? | Name |
|-----------|-------|---------------------------------------------------------|
| MC-4 | Yes | Item drops sometimes appear at the wrong location |
| MC-158900 | No | "bad packet id 26" upon connecting after tempban expire |

Some of the patches are "lazy". This means that the Paper maintainers are not incredibly pleased with the manner in which the bug was patched, but the patch works nonetheless. These patches will be disabled by default when configurability is implemented.

### Planned

| Bug | Name |
|-----------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| MC-11193 | The order in which powerable blocks (e.g. redstone dust blocks) along a wire are powered or de-powered is not clearly defined and causes a non-deterministic behavior for redstone contraptions |
| MC-27056 | You can blow the extension off a piston |
| MC-33041 | Dedicated server logs "java.io.IOException: The handle is invalid" on startup |
| MC-50319 | Player owned projectiles lose their player ownership when exiting portals |
| MC-50647 | Slime mob spawners spawn slimes only in slime chunks |
| MC-81098 | Redstone dust updates cause lag |
| MC-99075 | Cancelled block place (spawn protection) causes inventory desync |
| MC-108513 | end crystal did not spawn/despawn correct after enderdragon respawned |
| MC-118857 | Effect amplifier is read/written as byte from NBT despite being stored as an integer |
| MC-123450 | Item frames play sounds when the item within them is read from NBT |
| MC-135506 | Experience saves as a short, used as integer |
| MC-142590 | StackOverflowError when using /stop with player logged in |
| MC-145260 | Whitelist on state inconsistency |
| MC-145656 | Attribute "follow_range" is not working to hostile mobs before they find the target |
| MC-147659 | Some witch huts spawn the incorrect cat |
| MC-157464 | Villagers move around in bed or even leave the bed when food is thrown at them |
| MC-159283 | The End terrain does not generate in multiple rings centered around the world center |
| MC-163962 | Villager demand values descrease indefinitely |
| MC-167279 | Bees get stuck in the void |
| MC-171420 | OP players get kicked for not being on the whitelist (enforce = on) |
| MC-179072 | Creepers do not defuse when switching from Survival to Creative/Spectator |
| MC-181190 | The discount for curing a villager is multiplied if the villager is reinfected and cured again |
| MC-188840 | |
| MC-191591 | Saddles lose their NBT data when equipped on horses, zombie horses, skeleton horses, mules or donkeys via right-clicking |
| MC-235045 | Entity type tags suggestions don't work in target selectors |
| MC-243057 | Furnace recipes don't consider alternatives when first option of recipe is used for fuel |
| MC-244739 | Goat eating sounds aren't played when feeding them the last item of wheat within a stack |
| MC-248588 | The "mobGriefing" gamerule doesn't prevent burning entities from being able to decrease the levels of water or powder snow cauldrons |
| MC-252817 | Placing a map into an item frame and removing it does not remove the green player marker |
| MC-253884 | Particles produced from the bad omen effect being consumed cannot be seen by other player |
| MC-253721 | Wrong logs when running /op @a |
| MC-257487 | The ender dragon's name is not reset when it is respawned in the end |

Also planned is Paper's general patches for permanent block breaking exploits, gravity block duplication, and piston-based duplication. (I can't find the Mojira tickets for these, if they exist.)

## Disclaimers

Whiteout is in no way associated with the Paper project. Please do not contact the maintainers of the Paper project about Whiteout.

### License

Since all bug fixes provided by this mod are ported from Paper, said fixes inherit their licensing from the Paper project, which is licensed under the [GPLv3](LICESE).

However, some contributors to the Paper project chose to release their code under the more permissive [MIT License](https://github.com/PaperMC/Paper/blob/master/licenses/MIT.md). While I would like to properly annotate which patches were originally authored by which person in the future, for now those wishing to fork or otherwise modify this project will have to cross-reference with the [Paper project's list of permissive contributors](https://github.com/PaperMC/Paper/blob/master/LICENSE.md).
91 changes: 91 additions & 0 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -0,0 +1,91 @@
plugins {
id 'fabric-loom' version '1.3-SNAPSHOT'
id 'maven-publish'
}

version = project.mod_version
group = project.maven_group

base {
archivesName = project.archives_base_name
}

repositories {
// Add repositories to retrieve artifacts from in here.
// You should only use this when depending on other mods because
// Loom adds the essential maven repositories to download Minecraft and libraries from automatically.
// See https://docs.gradle.org/current/userguide/declaring_repositories.html
// for more information about repositories.
}

loom {
splitEnvironmentSourceSets()

mods {
"modid" {
sourceSet sourceSets.main
sourceSet sourceSets.client
}
}

}

dependencies {
// To change the versions see the gradle.properties file
minecraft "com.mojang:minecraft:${project.minecraft_version}"
mappings "net.fabricmc:yarn:${project.yarn_mappings}:v2"
modImplementation "net.fabricmc:fabric-loader:${project.loader_version}"

// Fabric API. This is technically optional, but you probably want it anyway.
modImplementation "net.fabricmc.fabric-api:fabric-api:${project.fabric_version}"

// Uncomment the following line to enable the deprecated Fabric API modules.
// These are included in the Fabric API production distribution and allow you to update your mod to the latest modules at a later more convenient time.

// modImplementation "net.fabricmc.fabric-api:fabric-api-deprecated:${project.fabric_version}"
}

processResources {
inputs.property "version", project.version

filesMatching("fabric.mod.json") {
expand "version": project.version
}
}

tasks.withType(JavaCompile).configureEach {
it.options.release = 17
}

java {
// Loom will automatically attach sourcesJar to a RemapSourcesJar task and to the "build" task
// if it is present.
// If you remove this line, sources will not be generated.
withSourcesJar()

sourceCompatibility = JavaVersion.VERSION_17
targetCompatibility = JavaVersion.VERSION_17
}

jar {
from("LICENSE") {
rename { "${it}_${project.base.archivesName.get()}"}
}
}

// configure the maven publication
publishing {
publications {
mavenJava(MavenPublication) {
from components.java
}
}

// See https://docs.gradle.org/current/userguide/publishing_maven.html for information on how to set up publishing.
repositories {
// Add repositories to publish to here.
// Notice: This block does NOT have the same function as the block in the top level.
// The repositories here will be used for publishing your artifact, not for
// retrieving dependencies.
}
}
17 changes: 17 additions & 0 deletions gradle.properties
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# Done to increase the memory available to gradle.
org.gradle.jvmargs=-Xmx1G
org.gradle.parallel=true

# Fabric Properties
# check these on https://fabricmc.net/develop
minecraft_version=1.20.1
yarn_mappings=1.20.1+build.9
loader_version=0.14.21

# Mod Properties
mod_version=0.1.0
maven_group=io.github.rektroth
archives_base_name=whiteout

# Dependencies
fabric_version=0.85.0+1.20.1
Binary file added gradle/wrapper/gradle-wrapper.jar
Binary file not shown.
7 changes: 7 additions & 0 deletions gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-8.2-bin.zip
networkTimeout=10000
validateDistributionUrl=true
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
Loading

0 comments on commit 9676077

Please sign in to comment.