RobinCirex
Members-
Posts
115 -
Joined
-
Last visited
Everything posted by RobinCirex
-
Okay and how do they work?
-
Because I have to copy and paste the model file 15 times and rename it
-
Okay. I have an item that does the same every time but in like 10 different colors and it' s kinda dumb to add each as a single item
-
Hey, there used to be the method #setHasSubtypes in the Item class. Does anyone know how this works in the latest forge version?
-
[1.16.4] Use textures from outside for items
RobinCirex replied to RobinCirex's topic in Modder Support
uh, basically, but without a resource pack. Someone requested from me to make a mod where he can change the textures of the mod in a config file? -
Hey, is it possible to use textures that are in e.g. the .minecraft folder for items? So that I could change the textures without having to change the code?
-
Hey, I want to make monsters be able to break blocks that are in the way of their path. How would I detect those blocks? I've looked through all the AIs but didn't really find much. How would you guys recommend me to do it?
-
Okay, thank you
-
Hey, I'm trying to make an animated player model using GeckoLib. For that, the player has to implement the interface "IAnimatable". How do I overwrite the player class so I can implement it? This is what I've tried package me.cirex.titans.entity; import com.mojang.authlib.GameProfile; import net.minecraft.entity.player.PlayerEntity; import net.minecraft.util.math.BlockPos; import net.minecraft.world.World; import software.bernie.geckolib3.core.IAnimatable; import software.bernie.geckolib3.core.manager.AnimationData; import software.bernie.geckolib3.core.manager.AnimationFactory; public class CustomPlayerEntity extends PlayerEntity implements IAnimatable { public CustomPlayerEntity(World p_i241920_1_, BlockPos p_i241920_2_, float p_i241920_3_, GameProfile p_i241920_4_) { super(p_i241920_1_, p_i241920_2_, p_i241920_3_, p_i241920_4_); System.out.println("Player was created"); } @Override public boolean isSpectator() { return false; } @Override public boolean isCreative() { return false; } @Override public void tick() { System.out.println("test"); super.tick(); } @Override public void registerControllers(AnimationData data) { } @Override public AnimationFactory getFactory() { return null; } } package me.cirex.titans.registry; import me.cirex.titans.entity.CustomPlayerEntity; import net.minecraft.entity.EntityClassification; import net.minecraft.entity.EntityType; import net.minecraftforge.event.RegistryEvent; import net.minecraftforge.eventbus.api.SubscribeEvent; public class TitanRegistry { public static final EntityType<?> playerType = EntityType.Builder .<CustomPlayerEntity>create(EntityClassification.MISC).disableSerialization().disableSummoning() .size(0.6F, 1.8F).trackingRange(32).func_233608_b_(2).build("minecraft:player").setRegistryName("minecraft:player"); @SubscribeEvent public void onRegisterEntity(RegistryEvent.Register<EntityType<?>> event) { if(event.getName().getPath().equalsIgnoreCase("player")) { event.setCanceled(true); } event.getRegistry().register(playerType); } }
-
Hey, I want to make a mod where the player transforms into a monster that has special abilities. I have the model, textures and animations (using geckolib) made and I wanted to ask you guys for an opinion: How would I go on about this? I'm thinking of 2 options: Either override the PlayerRenderer and add the special abilities to the player or make the player invisible and kind of make the monster follow him around constantly. What do you guys think?
-
[1.16.5] Set custom model resourcelocation for item
RobinCirex replied to RobinCirex's topic in Modder Support
So, if I have spawneggs that are all supposed to use the same model, I have to copy it like 20 times? -
Hey, I'm trying to assign a custom model. I've looked at the documentary and it says that I have to use ModelLoader.setCustomModelResourceLocation, though that doesn't exist. Can anyone help?
-
okay thanks
-
okay, how would I be doing it then? Just using a rect?
-
Hey, I want to make a laser and I'm rendering a 3D line. However, I want to add a texture to it but I'm not quite sure how to do it. Can someone tell me what I have to put in the tex method? This is my code public void fillTex(Matrix4f matrix, Matrix4f matrix2) { BufferBuilder bufferbuilder = Tessellator.getInstance().getBuffer(); RenderSystem.enableBlend(); RenderSystem.enableTexture(); RenderSystem.defaultBlendFunc(); GL11.glLineWidth(5); Minecraft.getInstance().getTextureManager().bindTexture(laserTexture); bufferbuilder.begin(2, DefaultVertexFormats.POSITION_TEX); bufferbuilder.pos(matrix, (float) 0, (float) 0, (float) 0).tex(0, 0).endVertex(); bufferbuilder.pos(matrix2, (float) 0, (float) 0, (float) 0).tex(100, 100).endVertex(); bufferbuilder.finishDrawing(); WorldVertexBufferUploader.draw(bufferbuilder); RenderSystem.disableTexture(); RenderSystem.disableBlend(); }
-
thank you very much
-
Hey, I want to remove the particles that are displayed below a player when running. Does someone have an idea on how to do that?
-
Thank you very much
-
well, still doesn't work
-
oh, that was dumb
-
Hey, I'm trying to make a command using this code public static void register(CommandDispatcher<CommandSource> dispatcher) { dispatcher.register(Commands.literal("picture").executes(source -> { return command(source.getSource(), source.getSource().asPlayer()); }).then(Commands.argument("link", StringArgumentType.string()).argument("width", IntegerArgumentType.integer()) .argument("height", IntegerArgumentType.integer())).executes(source -> { return command(source.getSource(), source.getSource().asPlayer(), StringArgumentType.getString(source, "controlled"), IntegerArgumentType.getInteger(source, "width"), IntegerArgumentType.getInteger(source, "height")); })); } private static int command(CommandSource source, PlayerEntity player) { return 1; } private static int command(CommandSource source, PlayerEntity player, String controlled, int width, int height) { return 1; } However, everytime I try to use it, I get the error "An unexpected error occurred trying to execute that command" and nothing happens. Can someone tell me what I'm doing wrong?
-
Hey, I'm implementing SimpleImpl atm and when I tried to send a message, I got the error "Caused by: java.lang.IllegalArgumentException: Invalid message" Can somebody tell me what's wrong? public class SimpleMessage { public String message; public SimpleMessage(String message) { this.message = message; } public SimpleMessage() { } public static SimpleMessage read(PacketBuffer buf) { return new SimpleMessage(buf.readString()); } public static void write(SimpleMessage message, PacketBuffer buf) { buf.writeString(message.message); } public static class Handler { public static void handle(SimpleMessage message, Supplier<NetworkEvent.Context> context) { ((NetworkEvent.Context) context.get()).setPacketHandled(true); System.out.println(message.message); } } } This is the message class itself And this is the method I'm using to send it public <MSG> void sendToServer(MSG message) { channel.sendToServer(message); } Thanks in advance
-
Hey, is there a way to get a resource location from a picture from e.g. imgur or prntscr? Or at least a way to get one from a picture that is not in your assets?
-
Okay, could you maybe explain how I would do that?
-
well, I wanna render rects though, textured rects too. This was just an example fo what I mean by "2D Rect in 3D"