
Jongh
Members-
Posts
29 -
Joined
-
Last visited
Everything posted by Jongh
-
Hello, I am trying to setup a Forge dev environment for 1.8.9 but I am running into some problems. The old process was to use "gradlew setupDecompWorkspace" but apparently that has been deprecated. I tried just skipping that step and having IntelliJ run the gradlew.build file but that doesn't grab the required Minecraft source jar. So I tried using the newest version of gradlew.build from Forge 1.14 (replacing the proper 1.8.9 Forge version in the dependency) and now I'm getting this error: https://gist.github.com/hjongh/e8446387ae71e3e43030b1831f717874 . Not sure whether I screwed things up when I was messing with Gradle beforehand, or the gradle version is too old (2.7). So my question is, how can I do the setup for 1.8.9 now? Could I just copy a 1.8.9 Minecraft source jar I have from my old mods and use that?
-
Hi, so I'm looking through this mod's source code in github at the moment and I don't fully understand how the mod's xray is structured. https://github.com/MinecraftModdedClients/Resilience-Client-Source I can find some structural classes, like simple classes that add xray blocks to the 'xray list' and a little xray skeleton class just to save the block id, and then the actual xray module class: https://github.com/MinecraftModdedClients/Resilience-Client-Source/blob/master/com/krispdev/resilience/module/modules/world/ModuleXray.java that changes the boolean value in xrayutil to on and off, but I don't understand how, where, the actual xray part is executed, the part that decides what blocks to render or pass some sort of 'blocklist' to the renderer. Reason is because I'm trying to make a mod that has a similar functionality of being able to see through certain blocks, but I don't know how I can do it. I was thinking about just adding a renderevent somehow like most other mods but I think it would be really inefficient to calculate on each renderevent which blocks to render and which not to. Anyone know a good way to do this?
-
Hey, So when I play Minecraft on Hypixel, my memory always seems to fill up really fast. I was looking through my logs recently and I saw that they are filled with this error message, just constantly printing over and over again (this is just 1 iteration) : https://gist.github.com/anonymous/bbc13706a20b006d4d81c2acb1318565 After some searching it seems like this might be caused because of new way that server sends chunks to client in 1.9+, and as I'm using 1.8.9 on Hypixel, which supports 1.8 - 1.11, this would be causing me to constantly get this error and fill up my memory (maybe?) Does anyone know why this is happening and how I could fix this?
-
awwwwwwwwwwwwwwwwwwwwwwwwwww darn ok Any other way I can accomplish this then?
-
I did what something similar to what mcenderdragon suggested and the event doesn't seem to fire at all. Specifically when I'm on servers* Here's what my eventhandler: https://gist.github.com/hjongh/efe1e2c9bf82d14bb96b16e991f554c6 and main classes: https://gist.github.com/hjongh/52c4937088a466ac15ec7776a6553614 look like at the moment.
-
Ok so I tried hardcoding the player checking, just to test it, and it still doesn't work. https://gist.github.com/hjongh/b7139e7d016b3737a08effb810bc0e05 The mod functionality works when I'm in Singleplayer, so there isn't an issue with the player's name being returned in some weird format. It just doesn't work when I go on a server. Also I'm testing it by building it each time and running it with my actual Minecraft.
-
I now pass the eventhandler class a reference to Minecraft from the Main class in its Constructor. Also I should have said but this is a mod, not a plugin. I tested it and it still doesn't work. The functionality works in singleplayer. I also have other listeners that are functioning in both singleplayer and on a server. But just this listener's code doesn't work on a server.
-
So I'm trying to make a little stat indicator that shows kills and deaths stats in the corner. But it doesn't work on servers, only on singleplayer. I have some other listeners registered and they are all working on the server. Here is the eventhandler class, I have it subscribed to Forge event bus and everything: https://gist.github.com/hjongh/6271c57ad26a4940f92714f0ff51cb9c I was thinking that maybe this LivingDeathEvent is done only on server and client cannot access or something? For security/privacy reasons.
-
Woahhhhkayyyy I got it to build successfully and not crash my Minecraft! Thanks so much for the help man really appreciate it. Now to finish my mod haha Thanks again!
-
Ok so I wasn't entirely sure how it would work for jars, because your example code seems to be only including a single class dependency while I'm using a whole jar.. So I just added it in like this: https://gist.github.com/hjongh/f6f97391d2e150c4e3bfc9148a0592a8 But when I try to build, cmd shows "could not find method shadowJar()" which is not even a problem with how I included the jar dependency I think. EDIT: WAIT DERP IT LOOKS LIKE MY PLUGIN SECTION IS COMMENTED OUT LET ME TRY AGAIN BRB EDIT2: OK IT WORKS NOW BUT NOW THE WAY I USED THE JAR AS A DEPENDCY IS CAUSING A BUILD ERROR
-
Hey, I'm trying to figure out how to use this and I'm not finding much. Is there any tutorial for installing gradle plugins? I can't seem to find any. And just like in general I'm sort of lost how to use this shadow plugin... There's just so much information on the Shadow Plugin user guide and I'm having some difficulty filtering it. Any help would be much appreciated.
-
No, just my mod. But I'd rather prefer it if I didn't have to include other mods for mine to work... Is there any way I can bundle the hypixel api jar into my mod somehow? I'm pretty sure this is possible.
-
So I'm trying to make a mod that uses the Hypixel api. I have a libs folder in the same mod folder that contains the eclipse, gradle, src folders. In that libs folder I have the api jar that I've added to Build Path in eclipse, and I also included it as a dependency in the build.gradle file using: dependencies { compile files ("libs/hypixeldev-publicapi.jar") } Here's a snip of the class hierarchy and some imports: The mod runs fine in Eclipse, but when I build the mod and try running it with Minecraft the game crashes with a ton of ClassNotFoundExceptions, I think because it couldn't find any of the classes in the API. Does anyone know how I can fix this?
-
Thanks for help so far. I added the obfuscated/srg code name and now the mod is working fine. However, it's slightly choppy, especially in comparison to vanilla f3+b debug mode. Could anyone suggest how to make it smoother? I was thinking of using different event, as RenderWorldLastEvent runs the hitbox code after everything else so that might be the cause of lag. But when I use RenderWorldEvent pre/post no hitboxes ever render. Here's my code: Main: https://gist.github.com/hjongh/425840713795356c20195ea18a8a8025 Eventhandler class: https://gist.github.com/hjongh/41ab05b48920297ff5fcf97bf7badc53 Tesselator drawing class: https://gist.github.com/hjongh/14b53dd65425069731caed7d42531abe
-
Uh so update The mod works as intended when I run it from eclipse without crashing, but when I try to run the mod in with actual Minecraft I get nullPointerException, coming from the reflection code in my Main preinit method. Here's what class looks like at the moment: https://gist.github.com/hjongh/e323d4c22dde606f7aa6b24fb98612fb
-
Works great, thanks so much you guys. Just to confirm, in my Main preInit method I've created and setAccessible a new inGround field of EntityArrow class. Then in my eventHandler method I'll just use the Main.inGround field to use to access the private inGround field for each EntityArrow object I'm iterating through. Main.java : https://gist.github.com/hjongh/cfdb983dedc6aeadf50d35ebfdc08d4a Event handler class: https://gist.github.com/hjongh/fac887b399710994bcf81146fe5eac4f also if anything weird with my code or any way to improve..it'd be great if you guys pointed out! I'm sort of a newbie programmer haha
-
Hey Draco, I was actually thinking about how if I do the reflection process for each arrow each time I handle an event then it would probably be really inefficient. Here is what my event handler class looks like right now: https://gist.github.com/hjongh/4659b0cab7b377b6d5713560f1a1c174 So if I wanted to make the private variable accessible only once so that I wouldn't have to do it each event handle how would I do that? I was thinking make a constructor for the eventhandler and put it there, but then I'm not sure how the error handling is going to work and whether that would even work aside from the error handling.
-
Wow, thanks for such quick and knowledgeable reply. So I had to go search what it was, just added it in and it seems to work perfectly. One last thing, for the exception handling, I just added a "throws thisexception thatexception" to the method, do you think that should work fine? Or do I need to use try catch?
-
Hello friends, I'm trying to make a mod that draws hitboxes for arrows. Currently the hitboxes show for all arrows and I'm trying to only make it show for moving arrows. But I can't seem to find a way to check this properly, which is sort of ridiculous. Here's what I've tried so far: 1. Onground() doesn't work because I think it tests whether the item has been dropped, versus arrow being stuck in a block. 2. Comparing motionx,y,z to 0 doesn't work because I think the fields don't get updated after the arrow stops moving. 3. IsCollided() and insideOfBlock(air) don't work either. 4. InGround was what I was hoping I could use as it is a custom arrow field but looking through source code the field actually seems to be PRIVATE and theres no inGround() check method. 5. IsAirborne doesn't work either. Not sure but it always evaluates to false. Here's what my eventhandler method looks like, nothing special: https://gist.github.com/hjongh/933709502c29dba99135e054a00688b0 So if anyone can give me suggestions on how I can do this, or maybe can say that one of my ways I tried should work, it would be much appreciated.
-
Hey jeffryfisher, I see what you mean, but what I was trying to do was make the mod change the hotkeys to the Dvorak equivalents simply so that the user doesn't have to go in manually and change it themselves. And then if they use any non-default hotkey values then they will just go and change those once. I know it's not a very elegant idea and I'm not sure that I'm going to continue attempting to make this Dvorak chatting mod, but I'd still like to know why the keybindcode change is not registering in-game, if anybody can help with that. On the other hand if anybody knows how to change the keybinds only when the user is typing into chat, that would be what I was initially trying to do and would be quite helpful.
-
Uh well I was trying to make a mod so that when the user types in chat, they will type in dvorak keyboard layout. But after researching it doesn't really look like its possible to change what is input into the pending chat box, just what actually goes to the chat. But I was thinking that it was possible! Because that's what language mods have to do right. The ones that let you type in Chinese for example. But I tried looking at the code for one and it was so complicated, and not really a simple solution I was looking for. So for the sake of finishing my only option is to have the mod just set all the hotkeys to dvorak presets and have the user play with computer on a Dvorak keyboard layout... A bit crude but I'd at least like to have something and this is what I came up with.
-
Hey folks, So basic mod, it's showing up in-game when I run it in eclipse. I'm just trying to rewrite a vanilla hotkey to a different key. For example, I've put this line : Minecraft.getMinecraft().gameSettings.keyBindRight.setKeyCode(Keyboard.KEY_E); In the init() method of ClientProxy. But when I run the game, the hotkey is still set to the Vanilla one, 'D'. I tried putting a print message right after the line printing out the keyCode for keyBindRight, and it shows up as 18 which is KEY_E. So I think that Minecraft may initialize? the hotkey values after the mods are loaded or something so it overwrites my change. Any way I could get this to work? Thanks.
-
Not many tutorials?
-
Oh my god.... Thank you so much. Finally worked Thanks for your patience! Wondering if there are any resources with updated ways of doing things, like with ModelLoader as an example?
-
Here is the complete file hierarchy, sorry for not including: Items registered in these two classes : ModItems class: https://gist.github.com/hjongh/fc1ed702b773cedb57d8 BasicItem class: https://gist.github.com/hjongh/54f10ed6bce4e79364e3 I did see that the error did not match up with my code which is part of the reason why I am utterly confused right now. Here's the complete error: https://gist.github.com/hjongh/d0444ce6e1f8ccd1f82e I think that maybe eclipse is not running the current files and maybe files that I previously loaded and deleted from my workspace. That imgur snippet shows what is loaded in my eclipse right now.