Jump to content
  • Home
  • Files
  • Docs
Status Updates
  • All Content

  • Advanced Search
  • Existing user? Sign In  

    Sign In



    • Not recommended on shared computers


    • Forgot your password?

  • Sign Up
  • All Activity
  • Home
  • Kragast

Kragast

Members
 View Profile  See their activity
  • Content Count

    9
  • Joined

    November 16, 2020
  • Last visited

    November 17, 2020

Community Reputation

0 Neutral

About Kragast

  • Rank
    Tree Puncher
  1. Kragast

    [Solved] [1.16.4] KeyInputEvent is not listened

    Kragast replied to Kragast's topic in Modder Support

    Why? There is no server key-bindings
    • November 17, 2020
    • 5 replies
  2. Kragast

    [Solved] [1.16.4] KeyInputEvent is not listened

    Kragast replied to Kragast's topic in Modder Support

    Yes, thank you!
    • November 17, 2020
    • 5 replies
  3. Kragast

    [Solved] [1.16.4] KeyInputEvent is not listened

    Kragast posted a topic in Modder Support

    It does nothing. Why? @Mod.EventBusSubscriber(modid = Mod.MOD_ID, bus = Mod.EventBusSubscriber.Bus.FORGE, value = Dist.CLIENT) public class ClientEventsHandler { @OnlyIn(Dist.CLIENT) @SubscribeEvent public void onKeyInput(InputEvent.KeyInputEvent event) { System.out.println(event.getKey()); System.out.println("Key is down!"); Mod.LOGGER.info("Key is down!"); Mod.LOGGER.info(event.getKey()); } }
    • November 17, 2020
    • 5 replies
  4. Kragast

    [Solved] [1.16.4] How to spawn an entity?

    Kragast replied to Kragast's topic in Modder Support

    Thanks!
    • November 17, 2020
    • 10 replies
  5. Kragast

    [Solved] [1.16.4] How to spawn an entity?

    Kragast replied to Kragast's topic in Modder Support

    Yes, it is so. Now I don't understand, how then I can connect Client-Side-Keyboard-Input with server interactions. Should I send packages?
    • November 16, 2020
    • 10 replies
  6. Kragast

    [Solved] [1.16.4] How to spawn an entity?

    Kragast replied to Kragast's topic in Modder Support

    Because I want to setRenderViewEntity to my dummy entity. When I place the block in my world, it works. @Mod.EventBusSubscriber(modid = FreeCam.MOD_ID, bus = Mod.EventBusSubscriber.Bus.FORGE, value = Dist.CLIENT) public class ModClientEvents { @SubscribeEvent public static void onKeyPress(InputEvent.KeyInputEvent event) {} }
    • November 16, 2020
    • 10 replies
  7. Kragast

    [Solved] [1.16.4] How to spawn an entity?

    Kragast replied to Kragast's topic in Modder Support

    And another question. I'm writing one-side client mode, that changes camera position. And I'd like it to work on servers. This is why I think, I need to summon it in client side.
    • November 16, 2020
    • 10 replies
  8. Kragast

    [Solved] [1.16.4] How to spawn an entity?

    Kragast replied to Kragast's topic in Modder Support

    I've copied vanilla code and then my minecraft crashed How can I summon entity in specific coordinates? I could change this later, but addEntity returns boolean, not Entity.
    • November 16, 2020
    • 10 replies
  9. Kragast started following [Solved] [1.16.4] How to spawn an entity? November 16, 2020
  10. Kragast

    [Solved] [1.16.4] How to spawn an entity?

    Kragast posted a topic in Modder Support

    I need to spawn an entity in the world, but i can't found any information how to do this in 1.16.4. I tryed with a pig, but i couldn't :(( Tell me, please, how to do that @SubscribeEvent public static void onKeyPress(InputEvent.KeyInputEvent event) { int key = event.getKey(); int action = event.getAction(); if ((key == 93) && (action == 1)) { System.out.print("KEY IS DOWN!\n"); PlayerEntity player = Minecraft.getInstance().player; World world = player.getEntityWorld(); world.setBlockState(player.getPosition().add(0, -1, 0), Block.getStateById(1)) // spawn a mob here } }
    • November 16, 2020
    • 10 replies
  • All Activity
  • Home
  • Kragast
  • Theme

Copyright © 2019 ForgeDevelopment LLC · Ads by Longitude Ads LLC Powered by Invision Community