mirror of
https://github.com/MinecraftForge/MinecraftForge.git
synced 2026-11-18 11:29:15 +00:00
Regenerate patches with relative headers. This should lower conflicts in future PRs.
Convert Forge to use Official mappings. Mojang released their obfuscation mappings but we have not used them up until now due to wanting to get their license to be more explicitly permissive. It is clear that their intent is to allow us to use their names for developing mods like this. See the full wording, and our interpretation here: https://github.com/MinecraftForge/MCPConfig/blob/master/Mojang.md
This commit is contained in:
1 parent
802298d99d
commit
a95b968c13
832 files changed
+4464
-4373
No files matched your search
@@ -43,13 +43,13 @@ public class VillagerTradingManager
|
||||
|
||||
static
|
||||
{
|
||||
VillagerTrades.VILLAGER_DEFAULT_TRADES.entrySet().forEach(e ->
|
||||
VillagerTrades.TRADES.entrySet().forEach(e ->
|
||||
{
|
||||
Int2ObjectMap<ITrade[]> copy = new Int2ObjectOpenHashMap<>();
|
||||
e.getValue().int2ObjectEntrySet().forEach(ent -> copy.put(ent.getIntKey(), Arrays.copyOf(ent.getValue(), ent.getValue().length)));
|
||||
VANILLA_TRADES.put(e.getKey(), copy);
|
||||
});
|
||||
VillagerTrades.field_221240_b.int2ObjectEntrySet().forEach(e -> WANDERER_TRADES.put(e.getIntKey(), Arrays.copyOf(e.getValue(), e.getValue().length)));
|
||||
VillagerTrades.WANDERING_TRADER_TRADES.int2ObjectEntrySet().forEach(e -> WANDERER_TRADES.put(e.getIntKey(), Arrays.copyOf(e.getValue(), e.getValue().length)));
|
||||
}
|
||||
|
||||
static void loadTrades(FMLServerAboutToStartEvent e)
|
||||
@@ -68,8 +68,8 @@ public class VillagerTradingManager
|
||||
Arrays.stream(WANDERER_TRADES.get(1)).forEach(generic::add);
|
||||
Arrays.stream(WANDERER_TRADES.get(2)).forEach(rare::add);
|
||||
MinecraftForge.EVENT_BUS.post(new WandererTradesEvent(generic, rare));
|
||||
VillagerTrades.field_221240_b.put(1, generic.toArray(new ITrade[0]));
|
||||
VillagerTrades.field_221240_b.put(2, rare.toArray(new ITrade[0]));
|
||||
VillagerTrades.WANDERING_TRADER_TRADES.put(1, generic.toArray(new ITrade[0]));
|
||||
VillagerTrades.WANDERING_TRADER_TRADES.put(2, rare.toArray(new ITrade[0]));
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -92,7 +92,7 @@ public class VillagerTradingManager
|
||||
MinecraftForge.EVENT_BUS.post(new VillagerTradesEvent(mutableTrades, prof));
|
||||
Int2ObjectMap<ITrade[]> newTrades = new Int2ObjectOpenHashMap<>();
|
||||
mutableTrades.int2ObjectEntrySet().forEach(e -> newTrades.put(e.getIntKey(), e.getValue().toArray(new ITrade[0])));
|
||||
VillagerTrades.VILLAGER_DEFAULT_TRADES.put(prof, newTrades);
|
||||
VillagerTrades.TRADES.put(prof, newTrades);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user