File tree Expand file tree Collapse file tree 3 files changed +1
-4
lines changed
Common/src/main/java/at/petrak/hexcasting
Forge/src/main/java/at/petrak/hexcasting/forge Expand file tree Collapse file tree 3 files changed +1
-4
lines changed Original file line number Diff line number Diff line change 77import net .minecraft .world .item .Tier ;
88import net .minecraft .world .item .Tiers ;
99import net .minecraft .world .level .Level ;
10- import net .minecraft .util .RandomSource ;
1110
1211import java .util .List ;
1312
Original file line number Diff line number Diff line change @@ -40,9 +40,8 @@ public AddHexToAncientCypherFunc(LootItemCondition[] lootItemConditions) {
4040 * This doesn't actually have any params so extract behaviour out for the benefit of forge
4141 */
4242 public static ItemStack doStatic (ItemStack stack , RandomSource rand ) {
43- var hex = LOOT_HEXES .get (rand .nextInt (16 ));
43+ var hex = LOOT_HEXES .get (rand .nextInt (LOOT_HEXES . size () ));
4444 var patsTag = new ListTag ();
45- // skip first element since it's the name, not a pattern
4645 for (var patString : hex .getSecond ()){
4746 var pieces = patString .split (" " );
4847 var pat = HexPattern .fromAngles (pieces [1 ],HexDir .fromString (pieces [0 ]));
Original file line number Diff line number Diff line change 11package at .petrak .hexcasting .forge ;
22
33import at .petrak .hexcasting .api .mod .HexConfig ;
4- import at .petrak .hexcasting .common .loot .HexLootHandler ;
54import net .minecraft .resources .ResourceKey ;
65import net .minecraft .resources .ResourceLocation ;
76import net .minecraft .world .level .Level ;
You can’t perform that action at this time.
0 commit comments