Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Stop listening for advancements when a fake player is unloaded #1746

Draft
wants to merge 1 commit into
base: 1.21.x
Choose a base branch
from

Conversation

Matyrobbrt
Copy link
Member

Advancement criteria hold players in a map key that's only cleared when PlayerAdvancements#stopListening is called. Fixes #1487

Advancement criteria hold players in a map key that's only cleared when `PlayerAdvancements#stopListening` is called.
Fixes neoforged#1487
@Matyrobbrt Matyrobbrt added bug A bug or error 1.21.4 Targeted at Minecraft 1.21.4 labels Dec 6, 2024
@neoforged-pr-publishing
Copy link

neoforged-pr-publishing bot commented Dec 6, 2024

  • Publish PR to GitHub Packages

Last commit published: e1247113ddb03d6f5e8c9250ad8895ef86262c9e.

PR Publishing

The artifacts published by this PR:

Repository Declaration

In order to use the artifacts published by the PR, add the following repository to your buildscript:

repositories {
    maven {
        name 'Maven for PR #1746' // https://github.com/neoforged/NeoForge/pull/1746
        url 'https://prmaven.neoforged.net/NeoForge/pr1746'
        content {
            includeModule('net.neoforged', 'neoforge')
            includeModule('net.neoforged', 'testframework')
        }
    }
}

MDK installation

In order to setup a MDK using the latest PR version, run the following commands in a terminal.
The script works on both *nix and Windows as long as you have the JDK bin folder on the path.
The script will clone the MDK in a folder named NeoForge-pr1746.
On Powershell you will need to remove the -L flag from the curl invocation.

mkdir NeoForge-pr1746
cd NeoForge-pr1746
curl -L https://prmaven.neoforged.net/NeoForge/pr1746/net/neoforged/neoforge/21.4.11-beta-pr-1746-gh-1487/mdk-pr1746.zip -o mdk.zip
jar xf mdk.zip
rm mdk.zip || del mdk.zip

To test a production environment, you can download the installer from here.

@Matyrobbrt Matyrobbrt marked this pull request as draft December 11, 2024 16:48
@pietro-lopes
Copy link

pietro-lopes commented Dec 25, 2024

Adding some more information, some mods doesn't use this Factory, for example, Create.

Maybe this factory is too restricted to what they need?

https://github.com/Creators-of-Create/Create/blob/d48a504486311f3175f4ebef3b0649140e728fbb/src/main/java/com/simibubi/create/content/kinetics/deployer/DeployerFakePlayer.java#L51

They extend FakePlayer, use their own Connection, and their own ServerGamePacketListenerImpl

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
1.21.4 Targeted at Minecraft 1.21.4 bug A bug or error
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Memory Leak of Server Player if any Fake Player is created with UUID that does not match any player
2 participants