Jump to content
View in the app

A better way to browse. Learn more.

Forge Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Betterjakers

Members
  • Joined

  1. My last post was deleted and I am not sure why. Did I break the rules? Anyway, I'll post it here again in case it was an accident. I have my EventHandler and my WorldSavedData classes. Now, how do I save my variables from my class called Test.java? Thanks for any help given!
  2. Thanks you so much everyone, I got everything I wanted to done!
  3. Thanks! I did have the event bus in the wrong place. It now works. Now, how can I send a message to the killer?
  4. I changed it to EntityZombie but when a zombie dies, it does not say "Hello!" in console.
  5. What? In my main mod class, this is where I have it: public static void init1( FMLInitializationEvent event ) { MinecraftForge.EVENT_BUS.register(new SoundHandler()); MinecraftForge.EVENT_BUS.register(new Test()); }
  6. I did this, and it does not seem to work. I registered it to the event bus, so it should be working. Here is my class: package mymod.quests; import net.minecraft.entity.player.EntityPlayer; import net.minecraftforge.event.ForgeSubscribe; import net.minecraftforge.event.entity.living.LivingDeathEvent; public class Test { @ForgeSubscribe public void onEntityDeath(LivingDeathEvent event) { if(event.entityLiving instanceof EntityPlayer) { System.out.println("Hello!"); } } }
  7. I did not register it to the forge event bus. How can I do that?
  8. Alright, thanks! Would this work? @ForgeSubscribe public void onEntityDeath(LivingDeathEvent event) { if(event.entityLiving instanceof EntityZombie) { System.out.println("Hello!"); } }
  9. Hello! Does anyone know how to test for when a players kills a zombie? You're gonna hate me, I'm sorry, but I am on 1.6.4 :'(
  10. 1.6.4. I'll probably get no help
  11. Hello! I am trying to add a sound, but cannot seem to get it to work. I right click the iPod, but do not hear the "ipodsong" sound. The sound is at src/assets/mymod/sound. It is named "ipodsong.ogg". Here is my code:
  12. I found out how to add the message and send a random one. Thanks for your help.
  13. I found out how to add the message and send a random one. Thanks for your help.
  14. Alright, I found out how to add it. Now, is there a way I can say a random message instead of just that one? Ex: It will run only ONE of these messages: "Hi!", "Wow!", "Cool!", "Nice!", etc.

Important Information

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

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.