Skip to content

Commit 7f1c250

Browse files
committed
1.15.2 compiler errors fixed.
Signed-off-by: Pavel Erokhin (MairwunNx) <MairwunNx@gmail.com>
1 parent 56ee228 commit 7f1c250

3 files changed

Lines changed: 3 additions & 6 deletions

File tree

src/main/kotlin/com/mairwunnx/projectessentials/core/api/v1/commands/back/BackLocationData.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ data class BackLocationData(
2323
* @since 2.0.0-SNAPSHOT.1.
2424
*/
2525
val position: Position = Position(
26-
player.posX, player.posY, player.posZ
26+
player.positionVec.x, player.positionVec.y, player.positionVec.z
2727
),
2828
/**
2929
* Player camera head at the time of teleportation.

src/main/kotlin/com/mairwunnx/projectessentials/core/api/v1/extensions/Extensions.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ fun ServerPlayerEntity.playSound(
4848
val pos = player.positionVec
4949
DistExecutor.runWhenOn(Dist.CLIENT) {
5050
Runnable {
51-
Minecraft.getInstance().world.playSound(
51+
Minecraft.getInstance().world?.playSound(
5252
pos.x, pos.y + player.eyeHeight.toDouble(), pos.z,
5353
sound, category, volume, pitch, false
5454
)

src/main/kotlin/com/mairwunnx/projectessentials/core/impl/vanilla/commands/ScheduleCommand.kt

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -28,19 +28,16 @@ import net.minecraft.command.impl.FunctionCommand
2828
import net.minecraft.tags.Tag
2929
import net.minecraft.util.text.Style
3030
import net.minecraft.util.text.TranslationTextComponent
31-
import net.minecraft.util.text.event.HoverEvent
32-
import org.apache.logging.log4j.LogManager
3331
import java.util.function.Function
3432

3533
internal object ScheduleCommand : VanillaCommandBase() {
36-
private val logger = LogManager.getLogger()
37-
3834
private val field_218913_a =
3935
SimpleCommandExceptionType(TranslationTextComponent("commands.schedule.same_tick"))
4036
private val field_229811_b_ = DynamicCommandExceptionType(
4137
Function { p_229818_0_: Any? ->
4238
TranslationTextComponent("commands.schedule.cleared.failure", p_229818_0_)
4339
}
40+
)
4441
private val field_229812_c_ =
4542
SuggestionProvider { p_229814_0_: CommandContext<CommandSource>, p_229814_1_: SuggestionsBuilder ->
4643
ISuggestionProvider.suggest(

0 commit comments

Comments
 (0)