Jump to content

Melonslise

Members
  • Posts

    183
  • Joined

  • Last visited

Everything posted by Melonslise

  1. I've been trying to animate a json gun item via forge's api. So far I can't seem to solve the following issues: 1. How do I play a clip automatically after another clip ends? For example, I want the gun to return back to its default state after a recoil animation plays. I have tried adding the following event to the armature file: "1.0": "!transition:default", but that didn't work. I also tried copying the ASM TriggerClip example from the docs unsuccessfully. 2. How do I play the animation only in a certain camera perspective? I only want to play the animation in first person. Thanks!
  2. For some reason the output disappears, is completely incorrect in the first case and doesn't copy the nbt correctly. This is most likely an issue with the serializer. https://pastebin.com/7d6URMVD thanks EDIT: Solved, I'm an idiot. I mixed up my own copyID method parameters smh ?‍♂️
  3. Ok, but is this feature planned at least?
  4. I used to have a IWorldEventListener for this, but I've been told it has been removed. This is absolutely necessary for my mod. Thanks
  5. Namely what are the replacements for world#getPerWorldStorage and MapStorage? Are there any other significant changes?
  6. Here are the relevant classes: https://pastebin.com/NVUhE7f9 https://pastebin.com/Dk3s3BzQ
  7. Let me say this again: some of those blocks you see behind the door are rendered on the TRANSLUCENT layer and their model elements are 2 identical cubes. Yet they do not have the same issue. How come my door model in particular has this issue? Vanilla grass does overlay in the same way: it has overlapping model elements.
  8. Chaning to either cutout layer made things even worse: But I do need translucency. It's clearly a different issue because you can see I used the same overlay technique on the translucent layer for those full cubes behind the door and it worked just fine.
  9. Fair enough. How do I fix this sorting issue though?
  10. I have an overlay model for my custom door which flickers like so: https://streamable.com/h99ck Here's how one of the (4) models looks like: and here is the blockstate: As you can see, I have defined the flickering parts before the outer layer meaning they should always appear on the bottom, but for some reason they keep flickering. I have a similar overlay model for a full cube and it works just fine. Thanks Relevant classes: https://pastebin.com/NVUhE7f9 https://pastebin.com/Dk3s3BzQ
  11. I want to be able to specify all the 47 possible textures in a blockstate and then let the baked model choose and apply the right textures to each face. I've been told I need a custom model loader that returns an IModel which then returns another IModel with all textures remapped. I'm already stuck and have no idea what to do. Thanks!
      • 1
      • Like
  12. What is the best way to do that? I found a tutorial that suggests replacing regular key binds with an instance of a key bind extension that runs interception logic. Would that be the best way? If so, how and when/where do I replace the regular key bindings?
  13. Fixed with OpenGlHelper.setLightmapTextureCoords(OpenGlHelper.lightmapTexUnit, 240, 240); Thank you @HenryLoenwind!
  14. I tried compiling my mod and testing it outdev. Lo and behold there are no problems. I guess [SOLVED] Nvm, still happening.
  15. I've finally got my particle to work like I want it to. However it seems to disappear sometimes when moving around it. Also, interestingly, when changing the blendfunc to ONE_MINUS_SRC_ALPHA I noticed that instead of disappearing the particle turns completely black. Here's an example. Here's the code. Thanks.
  16. I got it! Here's the code if anyone is interested:
  17. I'm trying to render beam with a start and end point that faces the player's look vector.
  18. I tried adding and playing around with the code from RenderSnowball, but it gave really weird results. I also feel like the rotation code from RenderSnowball won't work with a long beam of sorts that I'm trying to make. Here's my code:
  19. I'm trying to render a quad that always faces the player in the RenderWorldLastEvent. The code either fails to render completely or sometimes flickers in and out of view whenever the player moves. Can someone help?
  20. Yes, they are mostly only relevant while held. I thought about that, but I’m not sure if adding 3-4 caps to every single player for a few items is good practice.
  21. Issue not fixed. Using a serializable capability still causes the others to reset. I tried not updating the capability and it worked absolutely fine - just like without updating the nbt.
  22. Oh didn’t think of that. But what if some other mod modifies the stack’s nbt? Thanks
  23. Yeah, that’s what I wrote in my first post. But how do I fix that without syncing every tick? Is there any way I could copy the capabilities?
  24. Actually the action is started on the client whenever the player presses a key and finishes on the client whenever he releases the key. Thus sending a return packet to the client would be wasteful. Whenever I write to the stack’s compound tag, the capabilities seem to reset.
  25. Identical code runs on both sides. Currently it works perfectly without updating the nbt.
×
×
  • Create New...

Important Information

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