Jump to content
View in the app

A better way to browse. Learn more.

Forge Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

SomePerson

Members
  • Joined

  • Last visited

Everything posted by SomePerson

  1. I did not see this: public class Block extends BlockBehaviour So I did not know how I could use Properties.copy() which actually requires a BlockBehaviour object. Sorry for that.
  2. Also the player looking in different directions has no effect.
  3. Update: at around 0 0 0 it draws the model but it does not move.
  4. There is a function in LivingEntity called hasLineOfSight where you can specify another Entity
  5. Another question: considering my current way of doing this is stupid, how could I render a different model for the player, maybe even with geckolib?
  6. public static final Block SLIME_BLOCK = register("slime_block", new SlimeBlock(BlockBehaviour.Properties.of().mapColor(MapColor.GRASS).friction(0.8F).sound(SoundType.SLIME_BLOCK).noOcclusion())); That was in Blocks.java. Just do that.
  7. import net.minecraft.world.level.material.Material;
  8. You are not importing the Material class. Is that on purpose?
  9. if(transform.isActive()){ event.setCanceled(true); LayerDefinition def = Transformed.createBodyLayer(); Transformed<Player> model = new Transformed<>(def.bakeRoot()); PoseStack ps = new PoseStack(); ps.translate(player.getX(),player.getY(),player.getZ()); //ps.pushTransformation(new Transformation(null).applyOrigin(player.getPosition(1).toVector3f())); model.renderToBuffer(ps,Minecraft.getInstance().renderBuffers().bufferSource().getBuffer(RenderType.entitySolid(Transformed.LAYER_LOCATION.getModel())), 0, 0, 1, 1, 1, 1); } I have this but it does not work and its probably completely wrong but i could not find anything better (It is in the RenderPlayerEvent.Pre event)

Important Information

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

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.