Skip to content

Commit

Permalink
1.0.3.6 (1.15.1) Update
Browse files Browse the repository at this point in the history
  • Loading branch information
Codename Revy committed Dec 22, 2019
1 parent 89b4f92 commit c5a89c6
Show file tree
Hide file tree
Showing 6 changed files with 35 additions and 57 deletions.
30 changes: 6 additions & 24 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -9,23 +9,18 @@ buildscript {
}
}
apply plugin: 'net.minecraftforge.gradle'
// Only edit below this line, the above code adds and enables the necessary things for Forge to be setup.
apply plugin: 'eclipse'
apply plugin: 'maven-publish'

version = '1.0.3.5'
group = 'com.codenamerevy.magicmirror' // http://maven.apache.org/guides/mini/guide-naming-conventions.html
version = '1.0.3.6'
group = 'com.codenamerevy.magicmirror'
archivesBaseName = 'magicmirror'

sourceCompatibility = targetCompatibility = compileJava.sourceCompatibility = compileJava.targetCompatibility = '1.8' // Need this here so eclipse task generates correctly.

minecraft {
// snapshot_YYYYMMDD Snapshot are built nightly.
// stable_# Stables are built at the discretion of the MCP team.
mappings channel: 'snapshot', version: '20191017-1.14.3'

// Default run configurations.
// These can be tweaked, removed, or duplicated as needed.
//Mappings Version
mappings channel: 'snapshot', version: '20191222-1.14.3'
runs {
client {
workingDirectory project.file('run')
Expand Down Expand Up @@ -81,20 +76,7 @@ minecraft {

dependencies {
// Forge version
minecraft 'net.minecraftforge:forge:1.14.4-28.1.56'

// You may put jars on which you depend on in ./libs or you may define them like so..
// compile "some.group:artifact:version:classifier"
// compile "some.group:artifact:version"

// Real examples
// compile 'com.mod-buildcraft:buildcraft:6.0.8:dev' // adds buildcraft to the dev env
// compile 'com.googlecode.efficient-java-matrix-library:ejml:0.24' // adds ejml to the dev env

// For more info...
// http://www.gradle.org/docs/current/userguide/artifact_dependencies_tutorial.html
// http://www.gradle.org/docs/current/userguide/dependency_management.html

minecraft 'net.minecraftforge:forge:1.15.1-30.0.15'
}

// Manifest for reading by the runtime..
Expand All @@ -103,7 +85,7 @@ jar {
attributes([
"Specification-Title": "MagicMirrors",
"Specification-Vendor": "CodenameRevy",
"Specification-Version": "1", // We are version 1 of ourselves
"Specification-Version": "1",
"Implementation-Title": project.name,
"Implementation-Version": "${version}",
"Implementation-Vendor" :"CodenameRevy",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ private void travelHomeFromNether(PlayerEntity player)
DimensionType prevDimension = player.dimension;
DimensionType transDimension = prevDimension == DimensionType.THE_NETHER ? DimensionType.OVERWORLD : DimensionType.THE_NETHER;

serverPlayer.teleport(player.getServer().getWorld(transDimension), serverPlayer.posX, serverPlayer.posY, serverPlayer.posZ, serverPlayer.rotationYaw, serverPlayer.rotationPitch);
serverPlayer.teleport(player.getServer().getWorld(transDimension), serverPlayer.serverPosX, serverPlayer.serverPosY, serverPlayer.serverPosZ, serverPlayer.rotationYaw, serverPlayer.rotationPitch);
}

private void travelHomeFromEnd(PlayerEntity player)
Expand All @@ -82,7 +82,7 @@ private void travelHomeFromEnd(PlayerEntity player)
DimensionType prevDimension = player.dimension;
DimensionType transDimension = prevDimension == DimensionType.THE_END ? DimensionType.OVERWORLD : DimensionType.THE_END;

serverPlayer.teleport(player.getServer().getWorld(transDimension), serverPlayer.posX, serverPlayer.posY, serverPlayer.posZ, serverPlayer.rotationYaw, serverPlayer.rotationPitch);
serverPlayer.teleport(player.getServer().getWorld(transDimension), serverPlayer.serverPosX, serverPlayer.serverPosY, serverPlayer.serverPosZ, serverPlayer.rotationYaw, serverPlayer.rotationPitch);
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ public void onUsingTick (ItemStack stack, LivingEntity entity,int count)
Random rand = entity.world.rand;
for (int i = 0; i < 45; i++)
{
entity.world.addParticle(ParticleTypes.DRAGON_BREATH, entity.posX + (rand.nextBoolean() ? -1 : 1) * Math.pow(rand.nextFloat(), 2) * 2, entity.posY + rand.nextFloat() * 3 - 2, entity.posZ + (rand.nextBoolean() ? -1 : 1) * Math.pow(rand.nextFloat(), 2) * 2, 0, 0.105D, 0);
entity.world.addParticle(ParticleTypes.DRAGON_BREATH, entity.serverPosX + (rand.nextBoolean() ? -1 : 1) * Math.pow(rand.nextFloat(), 2) * 2, entity.chunkCoordY + rand.nextFloat() * 3 - 2, entity.serverPosZ + (rand.nextBoolean() ? -1 : 1) * Math.pow(rand.nextFloat(), 2) * 2, 0, 0.105D, 0);
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ public class Reference
public static final String MODID = "magicmirror";
public static final String NAME = "Magic Mirror";
public static final String VERSION = "1.0.3.5";
public static final String MC_VERSION = "1.14.4";
public static final String MC_VERSION = "1.15.1";
public static final String CLIENT_PROXY = "com.codenamerevy.magicmirror.proxy.ClientProxy";
public static final String COMMON_PROXY = "com.codenamerevy.magicmirror.proxy.CommonProxy";
public static final Logger LOGGER = LogManager.getLogger();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -122,110 +122,110 @@ private static void addToTableMineshaft(LootTableLoadEvent event, int maxRolls)
if (hasLootPool(event.getTable(), event.getName().toString())) return;

Reference.LOGGER.info("Add mirrors to loot table {} ({} rolls)", event.getName(), maxRolls);
event.getTable().addPool((new LootPool.Builder()).name("mineshaft_added").rolls(new RandomValueRange(1, maxRolls)).addEntry(TableLootEntry.builder(MINESHAFT).weight(10).acceptFunction(SetCount.func_215932_a(new RandomValueRange(0, 1)))).build());
event.getTable().addPool((new LootPool.Builder()).name("mineshaft_added").rolls(new RandomValueRange(1, maxRolls)).addEntry(TableLootEntry.builder(MINESHAFT).weight(10).acceptFunction(SetCount.builder(new RandomValueRange(0, 1)))).build());
}

private static void addToTableBuried(LootTableLoadEvent event, int maxRolls)
{
if (hasLootPool(event.getTable(), event.getName().toString())) return;

Reference.LOGGER.info("Add mirrors to loot table {} ({} rolls)", event.getName(), maxRolls);
event.getTable().addPool((new LootPool.Builder()).name("buried_added").rolls(new RandomValueRange(1, maxRolls)).addEntry(TableLootEntry.builder(BURIED).weight(10).acceptFunction(SetCount.func_215932_a(new RandomValueRange(0, 1)))).build());
event.getTable().addPool((new LootPool.Builder()).name("buried_added").rolls(new RandomValueRange(1, maxRolls)).addEntry(TableLootEntry.builder(BURIED).weight(10).acceptFunction(SetCount.builder(new RandomValueRange(0, 1)))).build());
}
private static void addToTableDesert(LootTableLoadEvent event, int maxRolls)
{
if (hasLootPool(event.getTable(), event.getName().toString())) return;

Reference.LOGGER.info("Add mirrors to loot table {} ({} rolls)", event.getName(), maxRolls);
event.getTable().addPool((new LootPool.Builder()).name("desert_added").rolls(new RandomValueRange(1, maxRolls)).addEntry(TableLootEntry.builder(DESERT).weight(10).acceptFunction(SetCount.func_215932_a(new RandomValueRange(0, 1)))).build());
event.getTable().addPool((new LootPool.Builder()).name("desert_added").rolls(new RandomValueRange(1, maxRolls)).addEntry(TableLootEntry.builder(DESERT).weight(10).acceptFunction(SetCount.builder(new RandomValueRange(0, 1)))).build());

}
private static void addToTableEnd(LootTableLoadEvent event, int maxRolls)
{
if (hasLootPool(event.getTable(), event.getName().toString())) return;

Reference.LOGGER.info("Add mirrors to loot table {} ({} rolls)", event.getName(), maxRolls);
event.getTable().addPool((new LootPool.Builder()).name("end_added").rolls(new RandomValueRange(1, maxRolls)).addEntry(TableLootEntry.builder(END).weight(10).acceptFunction(SetCount.func_215932_a(new RandomValueRange(0, 1)))).build());
event.getTable().addPool((new LootPool.Builder()).name("end_added").rolls(new RandomValueRange(1, maxRolls)).addEntry(TableLootEntry.builder(END).weight(10).acceptFunction(SetCount.builder(new RandomValueRange(0, 1)))).build());

}
private static void addToTableIgloo(LootTableLoadEvent event, int maxRolls)
{
if (hasLootPool(event.getTable(), event.getName().toString())) return;

Reference.LOGGER.info("Add mirrors to loot table {} ({} rolls)", event.getName(), maxRolls);
event.getTable().addPool((new LootPool.Builder()).name("igloo_added").rolls(new RandomValueRange(1, maxRolls)).addEntry(TableLootEntry.builder(IGLOO).weight(10).acceptFunction(SetCount.func_215932_a(new RandomValueRange(0, 1)))).build());
event.getTable().addPool((new LootPool.Builder()).name("igloo_added").rolls(new RandomValueRange(1, maxRolls)).addEntry(TableLootEntry.builder(IGLOO).weight(10).acceptFunction(SetCount.builder(new RandomValueRange(0, 1)))).build());

}
private static void addToTableJungle(LootTableLoadEvent event, int maxRolls)
{
if (hasLootPool(event.getTable(), event.getName().toString())) return;

Reference.LOGGER.info("Add mirrors to loot table {} ({} rolls)", event.getName(), maxRolls);
event.getTable().addPool((new LootPool.Builder()).name("jungle_added").rolls(new RandomValueRange(1, maxRolls)).addEntry(TableLootEntry.builder(JUNGLE).weight(10).acceptFunction(SetCount.func_215932_a(new RandomValueRange(0, 1)))).build());
event.getTable().addPool((new LootPool.Builder()).name("jungle_added").rolls(new RandomValueRange(1, maxRolls)).addEntry(TableLootEntry.builder(JUNGLE).weight(10).acceptFunction(SetCount.builder(new RandomValueRange(0, 1)))).build());

}
private static void addToTableNether(LootTableLoadEvent event, int maxRolls)
{
if (hasLootPool(event.getTable(), event.getName().toString())) return;

Reference.LOGGER.info("Add mirrors to loot table {} ({} rolls)", event.getName(), maxRolls);
event.getTable().addPool((new LootPool.Builder()).name("nether_added").rolls(new RandomValueRange(1, maxRolls)).addEntry(TableLootEntry.builder(NETHER).weight(10).acceptFunction(SetCount.func_215932_a(new RandomValueRange(0, 1)))).build());
event.getTable().addPool((new LootPool.Builder()).name("nether_added").rolls(new RandomValueRange(1, maxRolls)).addEntry(TableLootEntry.builder(NETHER).weight(10).acceptFunction(SetCount.builder(new RandomValueRange(0, 1)))).build());

}
private static void addToTableShipwreck(LootTableLoadEvent event, int maxRolls)
{
if (hasLootPool(event.getTable(), event.getName().toString())) return;

Reference.LOGGER.info("Add mirrors to loot table {} ({} rolls)", event.getName(), maxRolls);
event.getTable().addPool((new LootPool.Builder()).name("shipwreck_added").rolls(new RandomValueRange(1, maxRolls)).addEntry(TableLootEntry.builder(SHIPWRECK).weight(10).acceptFunction(SetCount.func_215932_a(new RandomValueRange(0, 1)))).build());
event.getTable().addPool((new LootPool.Builder()).name("shipwreck_added").rolls(new RandomValueRange(1, maxRolls)).addEntry(TableLootEntry.builder(SHIPWRECK).weight(10).acceptFunction(SetCount.builder(new RandomValueRange(0, 1)))).build());

}
private static void addToTableStronghold(LootTableLoadEvent event, int maxRolls)
{
if (hasLootPool(event.getTable(), event.getName().toString())) return;

Reference.LOGGER.info("Add mirrors to loot table {} ({} rolls)", event.getName(), maxRolls);
event.getTable().addPool((new LootPool.Builder()).name("stronghold_added").rolls(new RandomValueRange(1, maxRolls)).addEntry(TableLootEntry.builder(STRONGHOLD).weight(10).acceptFunction(SetCount.func_215932_a(new RandomValueRange(0, 1)))).build());
event.getTable().addPool((new LootPool.Builder()).name("stronghold_added").rolls(new RandomValueRange(1, maxRolls)).addEntry(TableLootEntry.builder(STRONGHOLD).weight(10).acceptFunction(SetCount.builder(new RandomValueRange(0, 1)))).build());

}
private static void addToTableCrossing(LootTableLoadEvent event, int maxRolls)
{
if (hasLootPool(event.getTable(), event.getName().toString())) return;

Reference.LOGGER.info("Add mirrors to loot table {} ({} rolls)", event.getName(), maxRolls);
event.getTable().addPool((new LootPool.Builder()).name("crossing_added").rolls(new RandomValueRange(1, maxRolls)).addEntry(TableLootEntry.builder(CROSSING).weight(10).acceptFunction(SetCount.func_215932_a(new RandomValueRange(0, 1)))).build());
event.getTable().addPool((new LootPool.Builder()).name("crossing_added").rolls(new RandomValueRange(1, maxRolls)).addEntry(TableLootEntry.builder(CROSSING).weight(10).acceptFunction(SetCount.builder(new RandomValueRange(0, 1)))).build());

}
private static void addToTableLibrary(LootTableLoadEvent event, int maxRolls)
{
if (hasLootPool(event.getTable(), event.getName().toString())) return;

Reference.LOGGER.info("Add mirrors to loot table {} ({} rolls)", event.getName(), maxRolls);
event.getTable().addPool((new LootPool.Builder()).name("library_added").rolls(new RandomValueRange(1, maxRolls)).addEntry(TableLootEntry.builder(LIBRARY).weight(10).acceptFunction(SetCount.func_215932_a(new RandomValueRange(0, 1)))).build());
event.getTable().addPool((new LootPool.Builder()).name("library_added").rolls(new RandomValueRange(1, maxRolls)).addEntry(TableLootEntry.builder(LIBRARY).weight(10).acceptFunction(SetCount.builder(new RandomValueRange(0, 1)))).build());

}
private static void addToTableUnderwater(LootTableLoadEvent event, int maxRolls)
{
if (hasLootPool(event.getTable(), event.getName().toString())) return;

Reference.LOGGER.info("Add mirrors to loot table {} ({} rolls)", event.getName(), maxRolls);
event.getTable().addPool((new LootPool.Builder()).name("underwater_added").rolls(new RandomValueRange(1, maxRolls)).addEntry(TableLootEntry.builder(UNDERWATER).weight(10).acceptFunction(SetCount.func_215932_a(new RandomValueRange(0, 1)))).build());
event.getTable().addPool((new LootPool.Builder()).name("underwater_added").rolls(new RandomValueRange(1, maxRolls)).addEntry(TableLootEntry.builder(UNDERWATER).weight(10).acceptFunction(SetCount.builder(new RandomValueRange(0, 1)))).build());

}
private static void addToTableCartographer(LootTableLoadEvent event, int maxRolls)
{
if (hasLootPool(event.getTable(), event.getName().toString())) return;

Reference.LOGGER.info("Add mirrors to loot table {} ({} rolls)", event.getName(), maxRolls);
event.getTable().addPool((new LootPool.Builder()).name("cartographer_added").rolls(new RandomValueRange(1, maxRolls)).addEntry(TableLootEntry.builder(CARTOGRAPHER).weight(10).acceptFunction(SetCount.func_215932_a(new RandomValueRange(0, 1)))).build());
event.getTable().addPool((new LootPool.Builder()).name("cartographer_added").rolls(new RandomValueRange(1, maxRolls)).addEntry(TableLootEntry.builder(CARTOGRAPHER).weight(10).acceptFunction(SetCount.builder(new RandomValueRange(0, 1)))).build());

}
private static void addToTableSnowyHouse(LootTableLoadEvent event, int maxRolls)
{
if (hasLootPool(event.getTable(), event.getName().toString())) return;

Reference.LOGGER.info("Add mirrors to loot table {} ({} rolls)", event.getName(), maxRolls);
event.getTable().addPool((new LootPool.Builder()).name("snowy_house_added").rolls(new RandomValueRange(1, maxRolls)).addEntry(TableLootEntry.builder(SNOWY_HOUSE).weight(10).acceptFunction(SetCount.func_215932_a(new RandomValueRange(0, 1)))).build());
event.getTable().addPool((new LootPool.Builder()).name("snowy_house_added").rolls(new RandomValueRange(1, maxRolls)).addEntry(TableLootEntry.builder(SNOWY_HOUSE).weight(10).acceptFunction(SetCount.builder(new RandomValueRange(0, 1)))).build());

}

Expand Down
26 changes: 11 additions & 15 deletions src/main/resources/META-INF/mods.toml
Original file line number Diff line number Diff line change
@@ -1,41 +1,37 @@
modLoader="javafml"
loaderVersion="[28,)"
issueTrackerURL="https://github.com/CodenameRevy/-1.14.4-MagicMirror/issues"
loaderVersion="[30,)"
issueTrackerURL="https://github.com/CodenameRevy/MagicMirrors/issues"

[[mods]]
modId="magicmirror"
version="1.0.3.5"
version="1.0.3.6"
displayName="Magic Mirrors"
displayURL="https://github.com/CodenameRevy/-1.14.4-MagicMirror"
displayURL="https://github.com/CodenameRevy/MagicMirrors"
logoFile="logo.png"
credits="MichaelLimaRodrigues"
authors="CodenameRevy"
description='''
Magic Mirror mod adds several new items that are used to teleport you to your bed location almost instantly!
Update 1.0.3.5 changelog:
- Added Configuration file for Items and Recipes (magicmirror_items.toml)
- Reworked Loot Table Handler, Loot Tables should now generate in existing worlds
- Updated to Forge 28.1.56
- Updated Mappings to 20191017-1.14.3
Update 1.0.3.6 (1.15.1) changelog:
- Updated to Forge 30.0.15
- Updated Mappings to 20191222-1.14.3
[Internal Changes]
- Optimized Imports
- Removed unnecessary classes
- Optimized loot_tables data structure
- Optimized recipes data structure for configs
- Fixed some weird function names :P
'''

[[dependencies.magicmirror]]
modId="forge"
mandatory=true
versionRange="[28.1.0,)"
versionRange="[30,)"
ordering="NONE"
side="BOTH"

[[dependencies.magicmirror]]
modId="minecraft"
mandatory=true
versionRange="[1.14.4]"
versionRange="[1.15.1]"
ordering="NONE"
side="BOTH"

0 comments on commit c5a89c6

Please sign in to comment.