Jump to content

ItsAMysteriousYT

Members
  • Posts

    785
  • Joined

  • Last visited

Everything posted by ItsAMysteriousYT

  1. Is there a way to change the cameraposition in Minecraft?
  2. I have a problem. I coded a custom Entity, but the interactFirst method does not work. I tried everything and lookad at vanilla entities, but nothing Here is my code:
  3. I tried using ClientTickEvent, but it didn't work properly, maybe cuz i used it wrong, but I use PlayerLoggedInEvent now as you said earlier and it works i think Thnx
  4. Oh - yea didn't see the 1.8
  5. Î had a Post on that topic earlier and in the end you said: 'In this case, you can just use ClientTickEvent' so i did.
  6. What about removing that motionY=-0.5431232... Also in the second constructor, just make this(world) instead of writing all the stuff you do in the first constructor a second time.
  7. Its pretty easy. just try this: It will loop through the water texture and animate it. To use it, just do basic drawing of textured rectangle in your gui and do TextureMap.locationBlocksTexture(already in the correct location).
  8. I created a custom car entity, and added all methods that i needed in 1.7.10 to be able to rightclick it and then let the player sit on it. But somehow none of these methods works. like not even the interactFirst method is fired when i click on the entity. Can anybody help me? The entity class:
  9. you said it would be the right one for that use
  10. Directly when the player joines in the world
  11. It should open the gui in which the player chooses his name and surname+his gender. The gui for which i needed the PacketHandling stuff. So it checks wether the player has the RLMPlqayerProps and then it should look if the name is set or not. If not, the gui should be shown, else the game should go on as usual.
  12. okay, they are saving, but the gui opens up before they are loaded. is there a way i can optimize this method? private int tickrun = 0; private boolean countticks = true; @SubscribeEvent public void showTheGui(TickEvent event) { EntityPlayer player = Minecraft.getMinecraft().thePlayer; if (player!=null&&RLMPlayerProps.get(player).shownGui != true) { Minecraft.getMinecraft().displayGuiScreen(new GuiModInit()); RLMPlayerProps.get(player).shownGui=true; } }
  13. No, that is not good. You can use the entities ID instead of the GuiID. In you GuiHandler, do if(world.getEntityByID(ID) instanceof yourEntityClass.class){ open GUI in CLIENT and CONTAINER in SERVER here }
  14. Thanks diesieben07, my problem is, that i learned Java through minecraft coding and not started minecraft coding after i learned java, well now im quite good at java, but some basic things are missing. Im on the best way understanding how to use final, static etc now. So final is i think when it should never be changed and static means, that it is the same in all instances of the class right? So, i us the get() everywhere now and also i removed the clone method from my IEEP.
  15. I have a problem with my IEEP. I set them through a gui with PacketHandling and stuff, but the data is not stored through world save or death. Since coolAlias tutorial is really confusing(sorry coolAlias), i cant figure it out properly. Here is my IEEP class: in the commonHandler i have those two methods:
  16. I just added it to the COmmonEventHandler now. is that correct?
  17. Okay, solved but now i have the problem that when the player dies or world is closed, the data does not stay saved.
  18. I think i solved that, just had to create a new class instead of putting it into the packetclass.
  19. Okay, i created a PropertiesSetPackage now which is being send from the run() method in the packethandler. The message looks like this: I registered the message to the Client side.
  20. oh... ill try that also i fixed some stuff with saving the properties. i now save them like this: ANd not like this:
  21. There is no method sendToClient, its just a method sendToAll, sendTo and sendToServer. Do i just have to use Minecraft.getMinecraft for it? I would register a Packet to the ClientSide now and then try sending it with the PacketHandler after i set the props on server.
×
×
  • Create New...

Important Information

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