mirror of
https://github.com/PaperMC/Paper.git
synced 2025-08-01 12:42:05 -07:00
[ci skip] Add more patch identifying comments
This commit is contained in:
@@ -16,7 +16,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
|
||||
Set<CriterionTrigger.Listener<T>> set = (Set) playerAdvancements.criterionData.get(this); // Paper - fix AdvancementDataPlayer leak
|
||||
if (set != null && !set.isEmpty()) {
|
||||
- LootContext lootContext = EntityPredicate.createContext(player, player);
|
||||
+ LootContext lootContext = null; // EntityPredicate.createContext(player, player); // Paper - lazily create LootContext for criterions
|
||||
+ LootContext lootContext = null; // EntityPredicate.createContext(player, player); // Paper - Perf: lazily create LootContext for criterions
|
||||
List<CriterionTrigger.Listener<T>> list = null;
|
||||
|
||||
for(CriterionTrigger.Listener<T> listener : set) {
|
||||
@@ -24,7 +24,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
|
||||
if (predicate.test(simpleInstance)) {
|
||||
Optional<ContextAwarePredicate> optional = simpleInstance.player();
|
||||
- if (optional.isEmpty() || optional.get().matches(lootContext)) {
|
||||
+ if (optional.isEmpty() || optional.get().matches(lootContext = (lootContext == null ? EntityPredicate.createContext(player, player) : lootContext))) { // Paper - lazily create LootContext for criterions
|
||||
+ if (optional.isEmpty() || optional.get().matches(lootContext = (lootContext == null ? EntityPredicate.createContext(player, player) : lootContext))) { // Paper - Perf: lazily create LootContext for criterions
|
||||
if (list == null) {
|
||||
list = Lists.newArrayList();
|
||||
}
|
||||
|
Reference in New Issue
Block a user