Skip to content

Commit

Permalink
update to 1.15.2
Browse files Browse the repository at this point in the history
  • Loading branch information
ManApart committed May 10, 2020
1 parent cc1c5e1 commit eaca291
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 15 deletions.
18 changes: 13 additions & 5 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -19,22 +19,30 @@ archivesBaseName = 'enderports'
sourceCompatibility = targetCompatibility = compileJava.sourceCompatibility = compileJava.targetCompatibility = '1.8'

minecraft {
mappings channel: 'snapshot', version: '20191215-1.14.3'
mappings channel: 'snapshot', version: '20200225-1.15.1'
runs {
client {
workingDirectory = project.file('run').canonicalPath
source sourceSets.main
mods {
enderports {
source sourceSets.main
}
}
}

server {
workingDirectory = project.file('run').canonicalPath
source sourceSets.main
mods {
enderports {
source sourceSets.main
}
}
}
}
}

dependencies {
minecraft 'net.minecraftforge:forge:1.14.4-28.1.0'
minecraft 'net.minecraftforge:forge:1.15.2-31.1.77'
}

jar {
Expand All @@ -44,7 +52,7 @@ jar {
"Specification-Vendor": "ManApart",
"Specification-Version": "1", // We are version 1 of ourselves
"Implementation-Title": project.name,
"Implementation-Version": "${version}",
"Implementation-Version": "1.0",
"Implementation-Vendor" :"ManApart",
"Implementation-Timestamp": new Date().format("yyyy-MM-dd'T'HH:mm:ssZ")
])
Expand Down
11 changes: 3 additions & 8 deletions src/main/java/org/manapart/enderports/Teleporter.java
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,7 @@
import net.minecraft.entity.player.PlayerEntity;
import net.minecraft.entity.player.ServerPlayerEntity;
import net.minecraft.item.ItemStack;
import net.minecraft.util.Hand;
import net.minecraft.util.ResourceLocation;
import net.minecraft.util.SoundCategory;
import net.minecraft.util.SoundEvents;
import net.minecraft.util.*;
import net.minecraft.util.math.BlockPos;
import net.minecraft.util.math.BlockRayTraceResult;
import net.minecraft.world.World;
Expand Down Expand Up @@ -45,9 +42,7 @@ public ResourceLocation getLootTable() {
}

@Override
public boolean onBlockActivated(BlockState state, World world, BlockPos pos, PlayerEntity player, Hand hand, BlockRayTraceResult rayTraceResult) {
boolean result = super.onBlockActivated(state, world, pos, player, hand, rayTraceResult);
// System.out.println("On block clicked");
public ActionResultType onBlockActivated(BlockState state, World world, BlockPos pos, PlayerEntity player, Hand hand, BlockRayTraceResult rayTraceResult) {
if (world instanceof ServerWorld) {
ServerWorld serverWorld = (ServerWorld) world;
BlockPos nextPos = TeleporterNetwork.getNetwork(serverWorld).getNextTeleporter(pos);
Expand All @@ -58,7 +53,7 @@ public boolean onBlockActivated(BlockState state, World world, BlockPos pos, Pla
}
}

return result;
return ActionResultType.PASS;
}

@Override
Expand Down
4 changes: 2 additions & 2 deletions src/main/resources/META-INF/mods.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ issueTrackerURL="http://my.issue.tracker/" #optional
# The modid of the mod
modId="enderports" #mandatory
# The version number of the mod - there's a few well known ${} variables useable here or just hardcode it
version="${file.jarVersion}" #mandatory
version="1.0" #mandatory
# A display name for the mod
displayName="Enderports" #mandatory
# A URL to query for updates for this mod. See the JSON update specification <here>
Expand All @@ -29,7 +29,7 @@ credits="Simple teleporter mods" #optional
authors="ManApart" #optional
# The description text for the mod (multi line!) (#mandatory)
description='''
Simple teleporter mods
Simple teleporters
'''
# A dependency - use the . to indicate dependency for a specific modid. Dependencies are optional.
[[dependencies.examplemod]] #optional
Expand Down

0 comments on commit eaca291

Please sign in to comment.