When Mojang added 1.13.2-pre2 to their manifest page it exposed a flaw
in the way the script's regex was getting the version json manifest.
I've tweaked the regex such that it will always first get the version
entry and then use that entry to get the json url, rather than trying to
do the whole thing in one shot.
Fixes GH-1582
we've seen some index lines change in length in some PR's, though
this script was suppose to ignore those changes already.
The only way I can see that not working is if the color mode
of grep is breaking the pattern matching, as some people
default their grep to use color=always
this adds color=none to ensure colors are disabled, should ensure it.
Many times I've ran paper test trying to SHUTDOWN
the existing test server, only for it to see that my target folder
is missing (for whatever reason), and it try to build paper to make
the jar exists.
Well, the patch process will wipe out any uncommitted changes, causing
loss of work.
Now we will only build patches if your missing your entire Paper-Server
folder, and only trigger a mvn compile if the jar is missing.
Found some more unsafe operations in DataFixers.
Also replaced quite a few bad uses of Map.containsKey
containsKey is a common newbie mistake that "reads" cleaner, but
results in double the performance cost of all map operations as
containsKey in MOST cases where null values are not used is identical to get() == null
Considering how deep datafixers go in call stacks, with tons of map lookups,
this micro optimization could provide some gains.
Additionally, many of the containsKey/get/put style operations were
also a concurrency risk, resulting in multiple computation/insertions.
We are seeing issues with DataFixers being not thread safe in async chunks
and even in some spigot packet sending code.
There are a few more global objects that are mutated that need to
be synchronized to be safe for use over multiple threads.
There may be more cases, but these are extremely obvious ones.
the way I handled this on my fork was using the metadata in the
git "stats" output of patches, however we don't include stats in
the patch files for paper so the code didn't work.
Changed the code to detect our own file editions inside of NMS
to a method that works without stats.
So we no longer need to manually add files to this list
ForgeFlower is better than Spigots FernFlower at decompiling the source.
However, in order to maintain the CraftBukkit patches, we must keep
using spigots for the primary.
However, for any file that we import on top of Spigots imported files
there is nothing stopping us from using better decompiled files.
So these changes will use ForgeFlower to maintain a better set of
decomped files, so anything we add on top of Paper can start off
in a better spot.
This scenario occurs when Paper-API fails, we then rebuild the patches,
however Paper-Server was left un an outdated state since the most
recent patches did not get applied to it.
This results in us reverting Paper-Server to an older state.
If Paper-API fails to apply, then Paper-Server has to be considered dirty.
This should avoid us having accidental patch reversions
This ensures your local copy of this folder is up to date whenever
mcdev imports change on the project.
Before, as we/upstream add/remove's imports, your local folder could
be out of sync and you have to randomly check 'do i need to run this?'
This will just automate it. For those people who don't use this
folder (not sure why you don't!), it won't change anything.
Paper team can do paper upcommit when manual upstream updates are needed
this will generate a changelog of everything that has changed between then and now.
* master:
Duplicate UUID Resolve Option
Add more information to Entity.toString
change LAST_EDIT to PAPER_LAST_EDIT for edit commands
Add more information to Entity.toString()
Add Debug Entities option to debug dupe uuid issues
Guard the Entity.SHARED_RANDOM from seed changes
Create a symlink on not-windows to current minecraft decompile dir
This is useful for project developers switching back and forth between
1.12.2 and 1.13 so we can have our IDE automatically use the
current version we are working on for included mc-dev files.
This branch/commit is only useful to those who purely use a clean Bukkit/Spigot/Paper API
and does not use NMS/OBC references.
This will let you start updating your plugin to the latest 1.13 builds of Bukkit Preview (4 as of now)
Note that this release is not final!!! API breakages may occur!
It is up to you if you find use out of this work.
Allows you to increase how far to check for a safe place to respawn
a player near their bed, allowing a better chance to respawn the
player at their bed should it of became obstructed.
Defaults to vanilla 1.
Rewrites the Vanilla luck application formula so that luck can be
applied to items that do not have any quality defined.
See: https://luckformula.emc.gs for data and details
-----------
The rough summary is:
My goal was that in a pool, when luck was applied, the pool
rebalances so the percentages for bigger items is
lowered and smaller items is boosted.
Do this by boosting and then reducing the weight value,
so that larger numbers are penalized more than smaller numbers.
resulting in a larger reduction of entries for more common
items than the reduction on small weights,
giving smaller weights more of a chance
-----------
This work kind of obsoletes quality, but quality would be useful
for 2 items with same weight that you want luck to impact
in varying directions.
Fishing still falls into that as the weights are closer, so luck
will invalidate junk more.
This change will result in some major changes to fishing formulas.
-----------
I would love to see this change in Vanilla, so Mojang please pull :)
Instead of checking whether it was set previously, setting it to false,
then setting it back to true if it was true before, just use the
command-line argument in git to override the config for that command.
Using a variable makes it pretty painless to do.
This is not a perfect workaround but it seems to be the best solution
for the moment.
On Windows, this means that when a patch fails to apply, you would now
need to fix that patch, finish the apply (AM), then rebuild all patches,
and then finally re-run the patch apply procedure in order to continue.
This adds a small amount of overhead compared to the traditional method
(which will still work on *nix environments, including WSL). However, it
seems preferable to the build not working on Windows at all.
* Make the legacy ping handler more reliable
The Minecraft server often fails to respond to old ("legacy") pings
from old Minecraft versions using the protocol used before the switch
to Netty in Minecraft 1.7.
Due to packet fragmentation[1], we might not have all needed bytes
available when the LegacyPingHandler is called. In this case, it will
run into an error, remove the handler and continue using the modern
protocol.
This is unlikely to happen for the first two revisions of the legacy
ping protocol (used in Minecraft 1.5.x and older) since the request
consists of only one or two bytes, but happens frequently for the
last/third revision introduced in Minecraft 1.6.
It has much larger, variable packet sizes due to the inclusion of
the virtual host (the hostname/port used to connect to the server).
The solution[2] is simple: If we find more than two matching bytes,
we buffer the remaining bytes until we have enough to fully read and
respond to the request.
[1]: https://netty.io/wiki/user-guide-for-4.x.html#wiki-h3-11
[2]: https://netty.io/wiki/user-guide-for-4.x.html#wiki-h4-13
* Add legacy ping support to PaperServerListPingEvent
Add a new method to StatusClient check if the client is a legacy
client that does not support all of the features provided in the
event.
* Drop original implementation for old player sample API
* Add extended PaperServerListPingEvent
Add a new event that extends the original ServerListPingEvent
and allows full control of the response sent to the client.
* Implement deprecated player sample API
Rather than checking the platform or operating system, simply check if
the command exists. If the check fails, check if the md5 command exists.
If that fails as well, cancel the build script. Otherwise, assign the
alias as before.
This allows plugins that give players the ability to apply the experience
points to the Item Mending formula, which will repair an item instead
of giving the player experience points.
Both an API To standalone mend, and apply mending logic to .giveExp has been added.