Jump to content

[Solved] Import failed


Bedwa

Recommended Posts

trying to import net.minecraft.world.level.block.state.BlockBehavior

Won't let me import img so

https://ibb.co/wJB11Fh

Code:

package io.github.wallibed.magicalmod.core.init;

import io.github.wallibed.magicalmod.MagicalMod;
import net.minecraft.world.level.block.Block;
import net.minecraft.world.level.block.Blocks;
import net.minecraft.world.level.block.state.BlockBehavior;
import net.minecraft.world.level.material.Material;
import net.minecraft.world.level.material.MaterialColor;
import net.minecraftforge.fmllegacy.RegistryObject;
import net.minecraftforge.registries.DeferredRegister;
import net.minecraftforge.registries.ForgeRegistries;

public final class BlockInit {
    
    private BlockInit() {
        
    }
    
    public static final DeferredRegister<Block> BLOCKS = DeferredRegister.create(ForgeRegistries.BLOCKS, 
            MagicalMod.MODID);
    
    public static final RegistryObject<Block> SOUL_BLOCK = BLOCKS.register("soul_block",
            () -> new Block(BlockBehavior.Properties.of(Material.AIR, MaterialColor.COLOR_LIGHT_BLUE)));
}
 

 

Edited by Bedwa
Link to comment
Share on other sites

  • Bedwa changed the title to [Solved] Import failed

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.