JackTheRedCreeper
Forge Modder-
Posts
24 -
Joined
-
Last visited
Converted
-
Gender
Undisclosed
-
Personal Text
I am neeew
JackTheRedCreeper's Achievements
Tree Puncher (2/8)
0
Reputation
-
[1.10] ExplosionEvent filters?
JackTheRedCreeper replied to JackTheRedCreeper's topic in Modder Support
Well, I guess my friend and I will have to merge our mods, because I'm using a custom explosion and he has to change it's properties... Oh well, thanks for the help, and good night! -
[1.10] ExplosionEvent filters?
JackTheRedCreeper replied to JackTheRedCreeper's topic in Modder Support
Hmm, I see now, but what about editing custom explosions? The "cancel and make a new one" breaks them. I've also stumped onto the same wall as a friend, damn those private explosion properties! Why are they even private-final? Edit: I'll stay around for 15 more mins and then go to sleep (so you know that I'm not gonna reply later). -
[1.10] ExplosionEvent filters?
JackTheRedCreeper replied to JackTheRedCreeper's topic in Modder Support
Yeah, my bad, it's late night and I'm kinda dense. The filters are more of a test, I want to detect an explosion with X strenght and modify that strenght. -
Soo, I've managed to get a ExplosionHandler working where all slimes explode upon spawning. However, I can't seem to find any way to filter a explosion from ExplosionEvent. Any info/lists on what I can work with?
-
What? If your friend is dealing with obfuscated jars, he is doing it all wrong. When you build the jar, your code is obfuscated to be able to work properly with "real" (aka non-dev environment) Minecraft. When building (since 1.8and later, I believe), you should by default get 2 jars inside the build/libs folder, [name].jar, and [name]-sources.jar. The "sources" indicates a non-obfuscated version of your mod, which other devs can use for cross-mod/addon interaction, etcetera. Oh! That'd be more in my side. The problem he has is detecting a custom mod class, because of obfuscation. Huh, but thing is, even if someone used "CustomExplosion", supposedly the class and such is all obfuscated, which makes it impossible to find. I guess there's some method my friend doesn't know, hence this thread. Edit (11-11): Still no response from my friend
-
That would be a core mod. This forum does not support core mods. You shouldn't edit vanilla methods. If you ever seriously needed a vanilla method to change, then you would submit a "pull request" to the Forge developers. Likewise, you shouldn't edit the methods inside other mods (if that's even possible). Instead, comunicate with the mod's owner about supporting what you want to do. Learn how to integrate your mod with Forge so that your mod can "play nice" with other mods. If you talk about core-modding or hacking others' mods, then maybe the forum moderators will explain things better than I have. However, if all you want to do is to detect the existence of a method in a class, then use reflection. The post-init event handler is a good place to accomplish such inter-mod coordination. Once your code knows that a class and method exist, then you can (still using reflection) call the method to act on the class or objects thereof. Be careful with reflection; it's inefficient. I mean something like an EventHandler (those are the ones used to replace Tnt properties for example, no?). His mod works perfectly but it doesn't detect custom explosions, which makes it finnicky. We thought about "waht if I make CustomExplosion and you detect that?" but the problem is minecraft's ofbuscation. I guess reflection is what we need because what my friend does is check for explosion, and if that explosion is in the world class. However, after doing those checks, he needs to change the explosion's location. We'll try the ExplosionEvent first.
-
We could do that, but it's not that important and we want the most compatible method possible. He's moving the explosion to other coords. Don't think it's too major. I belive he can use this method because my custom explosion is just a few value changes (on radius and power) Now to wait for him to get online...
-
Kind of like when you edit a Minecraft vanilla method (such as explosions), but from another mod. Add some code or edit what's there. I'm more interested in if it's possible, as a friend is having problems with his mod (I made custom explosions in mine and his mod is not detecting them) and we're lost on what to do. If it's just necessary to have some code on the custom explosion side, that'd be good enough. However if it all can be done without extra explosion code, it would have more mod compatibility. The idea is: My projectile causes a explosion (CustomExp), my friend's mod detects CustomExp and modifies it. At the moment his mod only works with vanilla explosions because they're "pre-ofbuscated", to say so (you know where they are and what their name is already)
-
[1.10] Custom explosion radius and power?
JackTheRedCreeper replied to JackTheRedCreeper's topic in Modder Support
Internet was down, so I couldn't login these two days >< Still, no other ideas? Maybe a way to replicate what blue skulls do? -
The "blocks" and "items" folders in resources/models shouldn't have an s at the end They should be "block" and "item". Weird thing, I know. Also, change the item "parent": "builtin/generated" to "parent": "item/generated". MrCrayfish does this later in the video, and it looks a lot better.
-
[1.10] Custom explosion radius and power?
JackTheRedCreeper replied to JackTheRedCreeper's topic in Modder Support
True, I didn't think about that, thanks! I read that blue skulls break a lot of stuff. Edit: Nothing here. They're just an extension of EntityFireball and are weak. Can't seem to find Blue Wither Skulls anywhere too.. -
[1.10] Custom explosion radius and power?
JackTheRedCreeper replied to JackTheRedCreeper's topic in Modder Support
I know, and I've already said that. What I want is a explosion that destroys all (or most) blocks in it's radius, but the radius should stay small.