Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mixin failed when running lexforge in dev #105

Open
SettingDust opened this issue Oct 17, 2024 · 0 comments
Open

Mixin failed when running lexforge in dev #105

SettingDust opened this issue Oct 17, 2024 · 0 comments

Comments

@SettingDust
Copy link

SettingDust commented Oct 17, 2024

Not sure is it related to #72. Forgified fabric api is crashing in dev.

Caused by: org.spongepowered.asm.mixin.injection.throwables.InjectionError: Critical injection failure: Callback method onEntityKilledOther(Lnet/minecraft/world/entity/Entity;Lnet/minecraft/server/level/ServerLevel;Lnet/minecraft/world/entity/LivingEntity;Lcom/llamalad7/mixinextras/injector/wrapoperation/Operation;)Z in fabric-entity-events-v1.mixins.json:LivingEntityMixin from mod fabric_entity_events_v1 failed injection check, (0/1) succeeded. Scanned 1 target(s). Using refmap fabric-entity-events-v1-refmap.json

According to SpongePowered/Mixin#462 (comment). I guess I need to specify the mapping file. But I can't find it.

EDIT: Unimined is remapping the mixin. So, the remapping is bugged?

Errors related

[WARN]  [MIXIN] Failed to resolve @ModifyVariable m_260785_ ([null]) on (modifyBedForOccupiedState(Lnet/minecraft/world/level/block/state/BlockState;Lnet/minecraft/core/BlockPos;)Lnet/minecraft/world/level/block/state/BlockState;) null in net/fabricmc/fabric/mixin/entity/event/LivingEntityMixin
[ERROR] [MIXIN] Cannot resolve class net/minecraft/block/BlockState
[WARN]  [MIXIN] Failed to resolve @Redirect m_260785_ ([null]) on (setOccupiedState(Lnet/minecraft/world/level/block/state/BlockState;Lnet/minecraft/world/level/Level;Lnet/minecraft/core/BlockPos;Lnet/minecraft/world/entity/LivingEntity;Z)V) null in net/fabricmc/fabric/mixin/entity/event/LivingEntityMixin
[ERROR] [MIXIN] Cannot resolve class net/minecraft/block/BedBlock
[WARN]  [MIXIN] Failed to resolve At target contains in mixin net.fabricmc.fabric.mixin.resource.loader.MinecraftServerMixin
[WARN]  [MIXIN] Failed to resolve @Redirect m_260785_ ([null]) on (modifyWakeUpPosition(Lnet/minecraft/world/entity/EntityType;Lnet/minecraft/world/level/CollisionGetter;Lnet/minecraft/core/BlockPos;Lnet/minecraft/core/Direction;F)Ljava/util/Optional;) (Lnet/minecraft/world/entity/EntityType<*>;Lnet/minecraft/world/level/CollisionGetter;Lnet/minecraft/core/BlockPos;Lnet/minecraft/core/Direction;F)Ljava/util/Optional<Lnet/minecraft/world/phys/Vec3;>; in net/fabricmc/fabric/mixin/entity/event/LivingEntityMixin

The refmap isn't matching after remapped

Original:

    "net/fabricmc/fabric/mixin/entity/event/LivingEntityMixin": {
      "sleep": "Lnet/minecraft/world/entity/LivingEntity;m_5802_(Lnet/minecraft/core/BlockPos;)V",
      "damage": "Lnet/minecraft/world/entity/LivingEntity;m_6469_(Lnet/minecraft/world/damagesource/DamageSource;F)Z",
      "onDeath": "Lnet/minecraft/world/entity/LivingEntity;m_6667_(Lnet/minecraft/world/damagesource/DamageSource;)V",
      "Lnet/minecraft/world/World;getBlockState(Lnet/minecraft/util/math/BlockPos;)Lnet/minecraft/block/BlockState;": "Lnet/minecraft/world/level/Level;m_8055_(Lnet/minecraft/core/BlockPos;)Lnet/minecraft/world/level/block/state/BlockState;",
      "net/minecraft/world/World.sendEntityStatus(Lnet/minecraft/entity/Entity;B)V": "Lnet/minecraft/world/level/Level;m_7605_(Lnet/minecraft/world/entity/Entity;B)V",
      "wakeUp": "Lnet/minecraft/world/entity/LivingEntity;m_5796_()V",
      "Lnet/minecraft/entity/LivingEntity;isDead()Z": "Lnet/minecraft/world/entity/LivingEntity;m_21224_()Z",
      "Lnet/minecraft/entity/Entity;onKilledOther(Lnet/minecraft/server/world/ServerWorld;Lnet/minecraft/entity/LivingEntity;)Z": "Lnet/minecraft/world/entity/Entity;m_214076_(Lnet/minecraft/server/level/ServerLevel;Lnet/minecraft/world/entity/LivingEntity;)Z",
      "Lnet/minecraft/block/BedBlock;findWakeUpPosition(Lnet/minecraft/entity/EntityType;Lnet/minecraft/world/CollisionView;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/util/math/Direction;F)Ljava/util/Optional;": "Lnet/minecraft/world/level/block/BedBlock;m_260958_(Lnet/minecraft/world/entity/EntityType;Lnet/minecraft/world/level/CollisionGetter;Lnet/minecraft/core/BlockPos;Lnet/minecraft/core/Direction;F)Ljava/util/Optional;",
      "Lnet/minecraft/block/BlockState;setBedOccupied(Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/entity/LivingEntity;Z)V": "Lnet/minecraft/world/level/block/state/BlockState;setBedOccupied(Lnet/minecraft/world/level/Level;Lnet/minecraft/core/BlockPos;Lnet/minecraft/world/entity/LivingEntity;Z)V",
      "getSleepingDirection": "Lnet/minecraft/world/entity/LivingEntity;m_21259_()Lnet/minecraft/core/Direction;"
    },

Remapped:

    "net/fabricmc/fabric/mixin/entity/event/LivingEntityMixin": {
      "net/minecraft/world/World.sendEntityStatus(Lnet/minecraft/entity/Entity;B)V": "Lnet/minecraft/world/level/Level;broadcastEntityEvent(Lnet/minecraft/world/entity/Entity;B)V",
      "onDeath": "Lnet/minecraft/world/entity/LivingEntity;die(Lnet/minecraft/world/damagesource/DamageSource;)V",
      "Lnet/minecraft/entity/LivingEntity;isDead()Z": "Lnet/minecraft/world/entity/LivingEntity;isDeadOrDying()Z",
      "damage": "Lnet/minecraft/world/entity/LivingEntity;hurt(Lnet/minecraft/world/damagesource/DamageSource;F)Z",
      "sleep": "Lnet/minecraft/world/entity/LivingEntity;startSleeping(Lnet/minecraft/core/BlockPos;)V",
      "wakeUp": "Lnet/minecraft/world/entity/LivingEntity;stopSleeping()V",
      "getSleepingDirection": "Lnet/minecraft/world/entity/LivingEntity;getBedOrientation()Lnet/minecraft/core/Direction;",
      "Lnet/minecraft/world/World;getBlockState(Lnet/minecraft/util/math/BlockPos;)Lnet/minecraft/block/BlockState;": "Lnet/minecraft/world/level/Level;getBlockState(Lnet/minecraft/core/BlockPos;)Lnet/minecraft/world/level/block/state/BlockState;",
      "lambda$stopSleeping$11": "Lnet/minecraft/world/entity/LivingEntity;lambda$stopSleeping$11(Lnet/minecraft/core/BlockPos;)V",
      "Lnet/minecraft/block/BlockState;setBedOccupied(Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/entity/LivingEntity;Z)V": "Lnet/minecraft/world/level/block/state/BlockState;setBedOccupied(Lnet/minecraft/world/level/Level;Lnet/minecraft/core/BlockPos;Lnet/minecraft/world/entity/LivingEntity;Z)V",
      "Lnet/minecraft/block/BedBlock;findWakeUpPosition(Lnet/minecraft/entity/EntityType;Lnet/minecraft/world/CollisionView;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/util/math/Direction;F)Ljava/util/Optional;": "Lnet/minecraft/world/level/block/BedBlock;findStandUpPosition(Lnet/minecraft/world/entity/EntityType;Lnet/minecraft/world/level/CollisionGetter;Lnet/minecraft/core/BlockPos;Lnet/minecraft/core/Direction;F)Ljava/util/Optional;"
    },
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant