Jump to content

JackTheRedCreeper

Forge Modder
  • Posts

    24
  • Joined

  • Last visited

Converted

  • Gender
    Undisclosed
  • Personal Text
    I am neeew

JackTheRedCreeper's Achievements

Tree Puncher

Tree Puncher (2/8)

0

Reputation

  1. 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!
  2. 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).
  3. 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.
  4. 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?
  5. Ok, my friend finally got online. He says that he had to do it his own way so the items wouldn't be destroyed by the explosions. Any ideas on how to prevent explosions from destroying drops?
  6. 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
  7. Yeah, explosion event. My friend hasn't gotten online yet. When he does and we test all of this, we'll tell you! Amusingly my custom explosions work in dev environment because it's not ofbuscated, but hopefully ExplosionEvent isn't affected.
  8. That's a good idea! So the thing now is to call the event cross-mods, huh..
  9. 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.
  10. 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...
  11. 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)
  12. Internet was down, so I couldn't login these two days >< Still, no other ideas? Maybe a way to replicate what blue skulls do?
  13. 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.
  14. 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..
  15. 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.
×
×
  • Create New...

Important Information

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