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.

MinecraftMart

Members
  • Joined

  • Last visited

Everything posted by MinecraftMart

  1. O wauw. Well i need some time to figure this out. Its really hard
  2. Okay all errors gone! But now on thing.. if you click in the air without trowing a ball it also activates te counter.. and it doesnt even trigger the achievement. package com.mart.achievements; import cpw.mods.fml.common.eventhandler.SubscribeEvent; import net.minecraftforge.event.entity.player.PlayerInteractEvent; import net.minecraftforge.event.entity.player.PlayerInteractEvent.Action; public class ThrowingHandler { public int PT = 0; @SubscribeEvent public void onItemThrow(PlayerInteractEvent event){ if (event.action == Action.RIGHT_CLICK_AIR){ PT = PT + 1; System.out.println(PT); if(PT == 10) { System.out.println("BRIKT"); event.entityPlayer.addStat(Achievements.Enderpearl, 1); } } } }
  3. Then this happens RIGHT_CLICK_AIR cannot be resolved or is not a field
  4. So i did some testing and it didnt work r is my cod: package com.mart.achievements; import ibxm.Player; import net.minecraft.block.Block; import net.minecraft.init.Blocks; import net.minecraftforge.event.entity.living.EnderTeleportEvent; import net.minecraftforge.event.entity.player.EntityItemPickupEvent; import net.minecraftforge.event.entity.player.PlayerInteractEvent; import cpw.mods.fml.common.event.FMLMissingMappingsEvent.Action; import cpw.mods.fml.common.eventhandler.SubscribeEvent; public class ThrowingHandler { public int PT = 0; @SubscribeEvent public void onItemThrow(PlayerInteractEvent p){ if (p.action.RIGHT_CLICK_BLOCK != null){ System.out.println("Mart"); PT = PT + 1; } if(PT == 10) { p.entityPlayer.addStat(Achievements.Enderpearl, 1); } } } And wich on if this should i use? MinecraftForge.EVENT_BUS.register(new ThrowingHandler()); FMLCommonHandler.instance().bus().register(new ThrowingHandler());
  5. I am searching for a ender pearl throw event so if it is throwed 10 times you get a achievement. Does somebody know wich event this is?And how to implement it?
  6. Hey, every time when i load my achievement page it crashes. I dont know what causes the problem but i think my achievement page since that is pretty straight forward. Here is my code Main class package com.mart.achievements; import net.minecraft.block.Block; import net.minecraft.init.Blocks; import net.minecraft.init.Items; import net.minecraft.item.ItemStack; import net.minecraft.stats.Achievement; import net.minecraft.stats.AchievementList; import net.minecraftforge.common.AchievementPage; import net.minecraftforge.common.MinecraftForge; import cpw.mods.fml.common.Mod; import cpw.mods.fml.common.Mod.EventHandler; import cpw.mods.fml.common.event.FMLInitializationEvent; import cpw.mods.fml.common.event.FMLPostInitializationEvent; import cpw.mods.fml.common.event.FMLPreInitializationEvent; import cpw.mods.fml.common.registry.GameRegistry; import cpw.mods.fml.common.registry.LanguageRegistry; @Mod(modid = Achievements.modid, version = Achievements.version) public class Achievements { public static final String modid = "More Achievements!"; public static final String version = "Version 1.0"; @EventHandler public void config(FMLPreInitializationEvent event) { } //everything public static Achievement Dirt; public static Achievement Cobble; @EventHandler public void load(FMLInitializationEvent event) { System.out.println("Loaded!"); MinecraftForge.EVENT_BUS.register(new PickupHandler()); AchievementPage.registerAchievementPage(page1); } @EventHandler public void modsLoaded(FMLPostInitializationEvent event) { Dirt = new Achievement("achievement.getDirt", "getDirt", 0, 0, Blocks.dirt, (Achievement)null).registerStat(); this.addAchievementName("Dirt", "Dirt.. Really?"); this.addAchievementDesc("Dirt", "You just found a piece of dirt.."); Cobble = new Achievement("achievement.getCobble", "getCobble", 0, 1, Blocks.cobblestone, (Achievement)null).registerStat(); this.addAchievementName("Cobble", "Well atleast its stone"); this.addAchievementDesc("Dirt", "1st pieve of cobble! You must be so proud of yourself ");; } private void addAchievementName(String ach, String name) { LanguageRegistry.instance().addStringLocalization("achievement." + ach, "en_US", name); } private void addAchievementDesc(String ach, String desc) { LanguageRegistry.instance().addStringLocalization("achievement." + ach + ".desc", "en_US", desc); } //Okay it seems that , Dirt, Cobble makes the page crash. How other should i put it in?? Any ideas? public static AchievementPage page1 = new AchievementPage("More Achievements!", Dirt, Cobble); } Crash log [21:28:30] [Client thread/FATAL]: Reported exception thrown! net.minecraft.util.ReportedException: Rendering screen at net.minecraft.client.renderer.EntityRenderer.updateCameraAndRender(EntityRenderer.java:1239) ~[EntityRenderer.class:?] at net.minecraft.client.Minecraft.runGameLoop(Minecraft.java:1066) ~[Minecraft.class:?] at net.minecraft.client.Minecraft.run(Minecraft.java:954) [Minecraft.class:?] at net.minecraft.client.main.Main.main(Main.java:112) [Main.class:?] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.7.0_51] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) ~[?:1.7.0_51] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.7.0_51] at java.lang.reflect.Method.invoke(Method.java:606) ~[?:1.7.0_51] at net.minecraft.launchwrapper.Launch.launch(Launch.java:134) [launchwrapper-1.9.jar:?] at net.minecraft.launchwrapper.Launch.main(Launch.java:28) [launchwrapper-1.9.jar:?] Caused by: java.lang.NullPointerException at net.minecraft.client.gui.achievement.GuiAchievements.func_146552_b(GuiAchievements.java:385) ~[GuiAchievements.class:?] at net.minecraft.client.gui.achievement.GuiAchievements.drawScreen(GuiAchievements.java:219) ~[GuiAchievements.class:?] at net.minecraft.client.renderer.EntityRenderer.updateCameraAndRender(EntityRenderer.java:1209) ~[EntityRenderer.class:?] ... 9 more ---- Minecraft Crash Report ---- // I bet Cylons wouldn't have this problem. Time: 27-2-14 21:28 Description: Rendering screen java.lang.NullPointerException: Rendering screen at net.minecraft.client.gui.achievement.GuiAchievements.func_146552_b(GuiAchievements.java:385) at net.minecraft.client.gui.achievement.GuiAchievements.drawScreen(GuiAchievements.java:219) at net.minecraft.client.renderer.EntityRenderer.updateCameraAndRender(EntityRenderer.java:1209) at net.minecraft.client.Minecraft.runGameLoop(Minecraft.java:1066) at net.minecraft.client.Minecraft.run(Minecraft.java:954) at net.minecraft.client.main.Main.main(Main.java:112) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at net.minecraft.launchwrapper.Launch.launch(Launch.java:134) at net.minecraft.launchwrapper.Launch.main(Launch.java:28) A detailed walkthrough of the error, its code path and all known details is as follows: --------------------------------------------------------------------------------------- -- Head -- Stacktrace: at net.minecraft.client.gui.achievement.GuiAchievements.func_146552_b(GuiAchievements.java:385) at net.minecraft.client.gui.achievement.GuiAchievements.drawScreen(GuiAchievements.java:219) -- Screen render details -- Details: Screen name: net.minecraft.client.gui.achievement.GuiAchievements Mouse location: Scaled: (191, 203). Absolute: (382, 72) Screen size: Scaled: (427, 240). Absolute: (854, 480). Scale factor of 2 -- Affected level -- Details: Level name: MpServer All players: 1 total; [EntityClientPlayerMP['Player125'/419, l='MpServer', x=128,44, y=73,62, z=-208,36]] Chunk stats: MultiplayerChunkCache: 225, 225 Level seed: 0 Level generator: ID 00 - default, ver 1. Features enabled: false Level generator options: Level spawn location: World: (120,64,-200), Chunk: (at 8,4,8 in 7,-13; contains blocks 112,0,-208 to 127,255,-193), Region: (0,-1; contains chunks 0,-32 to 31,-1, blocks 0,0,-512 to 511,255,-1) Level time: 589 game time, 589 day time Level dimension: 0 Level storage version: 0x00000 - Unknown? Level weather: Rain time: 0 (now: false), thunder time: 0 (now: false) Level game mode: Game mode: survival (ID 0). Hardcore: false. Cheats: false Forced entities: 120 total; [EntitySquid['Squid'/273, l='MpServer', x=151,43, y=51,39, z=-158,62], EntitySquid['Squid'/272, l='MpServer', x=150,28, y=56,09, z=-144,10], EntityBat['Bat'/258, l='MpServer', x=153,98, y=27,46, z=-207,85], EntityBat['Bat'/259, l='MpServer', x=151,17, y=18,71, z=-211,99], EntityZombie['Zombie'/256, l='MpServer', x=154,53, y=21,00, z=-213,72], EntityCreeper['Creeper'/257, l='MpServer', x=159,53, y=24,00, z=-208,28], EntityZombie['Zombie'/262, l='MpServer', x=144,50, y=13,00, z=-176,50], EntityZombie['Zombie'/263, l='MpServer', x=147,25, y=13,00, z=-182,47], EntityZombie['Zombie'/260, l='MpServer', x=149,56, y=40,00, z=-203,59], EntityCreeper['Creeper'/261, l='MpServer', x=148,69, y=13,00, z=-176,63], EntityItem['item.item.arrow'/266, l='MpServer', x=145,28, y=17,13, z=-180,88], EntityHorse['Horse'/267, l='MpServer', x=144,78, y=70,00, z=-187,22], EntitySkeleton['Skeleton'/264, l='MpServer', x=148,50, y=13,00, z=-179,97], EntityItem['item.item.bone'/265, l='MpServer', x=144,13, y=13,13, z=-176,13], EntitySquid['Squid'/270, l='MpServer', x=148,82, y=56,32, z=-147,05], EntitySquid['Squid'/271, l='MpServer', x=145,78, y=53,34, z=-150,39], EntitySpider['Spider'/268, l='MpServer', x=151,19, y=16,00, z=-170,00], EntitySkeleton['Skeleton'/269, l='MpServer', x=150,88, y=16,00, z=-167,56], EntityZombie['Zombie'/305, l='MpServer', x=171,59, y=57,00, z=-164,31], EntityZombie['Zombie'/304, l='MpServer', x=174,47, y=58,00, z=-165,94], EntityZombie['Zombie'/306, l='MpServer', x=174,50, y=36,00, z=-156,50], EntityHorse['Horse'/289, l='MpServer', x=162,50, y=72,00, z=-279,09], EntityHorse['Donkey'/292, l='MpServer', x=163,09, y=69,00, z=-238,97], EntityCreeper['Creeper'/293, l='MpServer', x=162,50, y=13,00, z=-217,50], EntityCreeper['Creeper'/294, l='MpServer', x=162,83, y=13,00, z=-214,40], EntityCreeper['Creeper'/295, l='MpServer', x=175,94, y=22,00, z=-219,53], EntitySkeleton['Skeleton'/296, l='MpServer', x=162,00, y=26,00, z=-210,69], EntitySkeleton['Skeleton'/297, l='MpServer', x=160,46, y=24,00, z=-210,56], EntitySkeleton['Skeleton'/298, l='MpServer', x=174,50, y=46,00, z=-215,50], EntitySkeleton['Skeleton'/299, l='MpServer', x=175,50, y=46,00, z=-215,50], EntityCreeper['Creeper'/300, l='MpServer', x=173,25, y=46,00, z=-200,41], EntityWitch['Witch'/301, l='MpServer', x=175,50, y=31,00, z=-186,81], EntitySpider['Spider'/302, l='MpServer', x=172,71, y=24,17, z=-169,54], EntitySkeleton['Skeleton'/303, l='MpServer', x=172,31, y=24,00, z=-167,47], EntityZombie['Zombie'/343, l='MpServer', x=187,87, y=21,00, z=-147,19], EntitySkeleton['Skeleton'/342, l='MpServer', x=177,88, y=26,00, z=-148,47], EntitySkeleton['Skeleton'/341, l='MpServer', x=179,28, y=25,00, z=-153,50], EntitySkeleton['Skeleton'/340, l='MpServer', x=176,50, y=24,00, z=-164,50], EntitySquid['Squid'/339, l='MpServer', x=189,78, y=47,00, z=-188,36], EntityCreeper['Creeper'/338, l='MpServer', x=178,78, y=30,00, z=-183,91], EntitySpider['Spider'/337, l='MpServer', x=189,31, y=28,91, z=-183,28], EntitySquid['Squid'/336, l='MpServer', x=183,52, y=48,00, z=-195,09], EntityCow['Cow'/78, l='MpServer', x=63,09, y=69,00, z=-287,63], EntityCow['Cow'/79, l='MpServer', x=50,31, y=67,00, z=-281,53], EntitySquid['Squid'/346, l='MpServer', x=189,64, y=47,44, z=-144,87], EntityCreeper['Creeper'/345, l='MpServer', x=178,54, y=36,24, z=-157,49], EntityZombie['Zombie'/344, l='MpServer', x=188,50, y=21,00, z=-149,50], EntityHorse['Donkey'/326, l='MpServer', x=181,16, y=72,00, z=-253,03], EntitySkeleton['Skeleton'/327, l='MpServer', x=189,35, y=46,00, z=-209,18], EntityHorse['Donkey'/324, l='MpServer', x=179,72, y=72,00, z=-250,97], EntityHorse['Donkey'/325, l='MpServer', x=177,03, y=73,00, z=-255,97], EntityHorse['Donkey'/322, l='MpServer', x=178,72, y=74,00, z=-256,72], EntityCow['Cow'/80, l='MpServer', x=60,48, y=69,00, z=-281,11], EntityHorse['Donkey'/323, l='MpServer', x=182,28, y=72,00, z=-251,19], EntityHorse['Horse'/321, l='MpServer', x=190,00, y=73,00, z=-274,00], EntitySpider['Spider'/334, l='MpServer', x=181,59, y=47,00, z=-203,91], EntityBat['Bat'/335, l='MpServer', x=182,67, y=47,63, z=-204,93], EntityCreeper['Creeper'/332, l='MpServer', x=176,50, y=46,00, z=-207,50], EntityCreeper['Creeper'/333, l='MpServer', x=181,50, y=46,00, z=-206,38], EntityCreeper['Creeper'/330, l='MpServer', x=186,50, y=42,00, z=-206,50], EntityCreeper['Creeper'/331, l='MpServer', x=179,50, y=46,00, z=-205,50], EntitySkeleton['Skeleton'/328, l='MpServer', x=190,31, y=25,00, z=-195,22], EntitySkeleton['Skeleton'/329, l='MpServer', x=189,31, y=25,00, z=-197,50], EntityBat['Bat'/368, l='MpServer', x=193,13, y=21,72, z=-155,53], EntityHorse['Horse'/356, l='MpServer', x=192,78, y=75,00, z=-275,22], EntitySkeleton['Skeleton'/357, l='MpServer', x=197,50, y=26,00, z=-196,50], EntityZombie['Zombie'/358, l='MpServer', x=203,50, y=38,00, z=-202,50], EntityCreeper['Creeper'/359, l='MpServer', x=200,85, y=45,00, z=-201,50], EntityHorse['Horse'/355, l='MpServer', x=196,50, y=75,00, z=-275,50], EntityBat['Bat'/364, l='MpServer', x=193,75, y=45,10, z=-202,59], EntitySkeleton['Skeleton'/366, l='MpServer', x=197,78, y=17,00, z=-154,41], EntitySquid['Squid'/124, l='MpServer', x=71,32, y=48,94, z=-218,24], EntityEnderman['Enderman'/367, l='MpServer', x=198,00, y=23,00, z=-147,16], EntityCow['Cow'/123, l='MpServer', x=66,69, y=70,00, z=-284,28], EntityBat['Bat'/360, l='MpServer', x=200,59, y=43,10, z=-200,94], EntityZombie['Zombie'/361, l='MpServer', x=199,98, y=45,00, z=-201,49], EntityBat['Bat'/362, l='MpServer', x=192,75, y=46,10, z=-202,56], EntitySkeleton['Skeleton'/363, l='MpServer', x=194,91, y=47,00, z=-202,47], EntityBat['Bat'/149, l='MpServer', x=90,72, y=34,10, z=-244,33], EntityZombie['Zombie'/163, l='MpServer', x=111,50, y=41,00, z=-211,50], EntitySkeleton['Skeleton'/162, l='MpServer', x=104,46, y=35,00, z=-251,50], EntityBat['Bat'/161, l='MpServer', x=104,92, y=39,28, z=-251,09], EntitySkeleton['Skeleton'/167, l='MpServer', x=100,50, y=23,00, z=-170,50], EntityZombie['Zombie'/166, l='MpServer', x=102,50, y=40,00, z=-212,50], EntityCreeper['Creeper'/165, l='MpServer', x=101,25, y=40,00, z=-213,25], EntityCreeper['Creeper'/164, l='MpServer', x=103,50, y=40,00, z=-212,00], EntityCreeper['Creeper'/186, l='MpServer', x=117,38, y=42,00, z=-209,31], EntityCreeper['Creeper'/187, l='MpServer', x=114,09, y=42,00, z=-208,53], EntityCreeper['Creeper'/190, l='MpServer', x=120,06, y=26,00, z=-176,50], EntitySkeleton['Skeleton'/191, l='MpServer', x=119,78, y=26,00, z=-178,31], EntityBat['Bat'/188, l='MpServer', x=125,75, y=18,10, z=-193,47], EntityCreeper['Creeper'/189, l='MpServer', x=124,69, y=12,00, z=-181,91], EntityClientPlayerMP['Player125'/419, l='MpServer', x=128,44, y=73,62, z=-208,36], EntitySquid['Squid'/201, l='MpServer', x=118,63, y=51,25, z=-147,88], EntityBat['Bat'/200, l='MpServer', x=118,70, y=29,06, z=-174,76], EntitySkeleton['Skeleton'/197, l='MpServer', x=118,28, y=26,00, z=-171,41], EntityZombie['Zombie'/196, l='MpServer', x=118,53, y=26,00, z=-170,47], EntityCreeper['Creeper'/199, l='MpServer', x=120,60, y=26,00, z=-170,56], EntitySkeleton['Skeleton'/198, l='MpServer', x=124,25, y=26,00, z=-167,69], EntityZombie['Zombie'/193, l='MpServer', x=120,50, y=26,00, z=-172,50], EntityZombie['Zombie'/192, l='MpServer', x=121,47, y=27,00, z=-176,98], EntitySkeleton['Skeleton'/195, l='MpServer', x=122,28, y=26,00, z=-170,44], EntityZombie['Zombie'/194, l='MpServer', x=117,50, y=26,00, z=-172,50], EntitySquid['Squid'/235, l='MpServer', x=141,70, y=57,31, z=-160,87], EntitySlime['Slime'/234, l='MpServer', x=136,84, y=15,00, z=-166,00], EntityCreeper['Creeper'/233, l='MpServer', x=133,44, y=30,12, z=-164,30], EntityWitch['Witch'/232, l='MpServer', x=130,50, y=29,00, z=-169,50], EntityHorse['Horse'/231, l='MpServer', x=138,00, y=64,00, z=-182,00], EntityCreeper['Creeper'/230, l='MpServer', x=142,97, y=13,00, z=-186,47], EntityBat['Bat'/229, l='MpServer', x=135,78, y=15,02, z=-190,22], EntityBat['Bat'/228, l='MpServer', x=137,31, y=14,13, z=-208,81], EntityHorse['Horse'/227, l='MpServer', x=140,19, y=73,00, z=-212,81], EntityHorse['Horse'/226, l='MpServer', x=135,19, y=73,00, z=-216,50], EntitySkeleton['Skeleton'/225, l='MpServer', x=136,50, y=16,00, z=-218,50], EntityHorse['Donkey'/254, l='MpServer', x=156,00, y=69,00, z=-235,75], EntityHorse['Donkey'/255, l='MpServer', x=156,00, y=69,00, z=-239,97], EntityHorse['Donkey'/252, l='MpServer', x=157,78, y=69,00, z=-234,72], EntityHorse['Donkey'/253, l='MpServer', x=153,78, y=69,00, z=-236,22], EntityHorse['Horse'/250, l='MpServer', x=157,16, y=76,00, z=-282,13], EntityBat['Bat'/251, l='MpServer', x=154,60, y=15,53, z=-230,20]] Retry entities: 0 total; [] Server brand: fml,forge Server type: Integrated singleplayer server Stacktrace: at net.minecraft.client.multiplayer.WorldClient.addWorldInfoToCrashReport(WorldClient.java:418) at net.minecraft.client.Minecraft.addGraphicsAndWorldToCrashReport(Minecraft.java:2559) at net.minecraft.client.Minecraft.run(Minecraft.java:976) at net.minecraft.client.main.Main.main(Main.java:112) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at net.minecraft.launchwrapper.Launch.launch(Launch.java:134) at net.minecraft.launchwrapper.Launch.main(Launch.java:28) -- System Details -- Details: Minecraft Version: 1.7.2 Operating System: Windows 7 (amd64) version 6.1 Java Version: 1.7.0_51, Oracle Corporation Java VM Version: Java HotSpot(TM) 64-Bit Server VM (mixed mode), Oracle Corporation Memory: 711327256 bytes (678 MB) / 1038876672 bytes (990 MB) up to 1038876672 bytes (990 MB) JVM Flags: 3 total; -Xincgc -Xmx1024M -Xms1024M AABB Pool Size: 12006 (672336 bytes; 0 MB) allocated, 12 (672 bytes; 0 MB) used IntCache: cache: 11, tcache: 0, allocated: 13, tallocated: 95 FML: MCP v9.01-pre FML v7.2.125.1033 Minecraft Forge 10.12.0.1033 4 mods loaded, 4 mods active mcp{8.09} [Minecraft Coder Pack] (minecraft.jar) Unloaded->Constructed->Pre-initialized->Initialized->Post-initialized->Available->Available->Available->Available FML{7.2.125.1033} [Forge Mod Loader] (forgeSrc-1.7.2-10.12.0.1033.jar) Unloaded->Constructed->Pre-initialized->Initialized->Post-initialized->Available->Available->Available->Available Forge{10.12.0.1033} [Minecraft Forge] (forgeSrc-1.7.2-10.12.0.1033.jar) Unloaded->Constructed->Pre-initialized->Initialized->Post-initialized->Available->Available->Available->Available More Achievements!{Version 1.0} [More Achievements!] (bin) Unloaded->Constructed->Pre-initialized->Initialized->Post-initialized->Available->Available->Available->Available Launched Version: 1.6 LWJGL: 2.9.0 OpenGL: ATI Mobility Radeon HD 5470 GL version 3.2.9262 Compatibility Profile Context, ATI Technologies Inc. Is Modded: Definitely; Client brand changed to 'fml,forge' Type: Client (map_client.txt) Resource Packs: [] Current Language: English (US) Profiler Position: N/A (disabled) Vec3 Pool Size: 4826 (270256 bytes; 0 MB) allocated, 69 (3864 bytes; 0 MB) used Anisotropic Filtering: Off (1) #@!@# Game crashed! Crash report saved to: #@!@# C:\Users\Mart\Desktop\ForgeModding\eclipse\.\crash-reports\crash-2014-02-27_21.28.30-client.txt AL lib: (EE) alc_cleanup: 1 device not closed I hope you can help me Okay it seems that , Dirt, Cobble makes the page crash. How other should i put it in?? Any ideas? public static AchievementPage page1 = new AchievementPage("More Achievements!", Dirt, Cobble); Is what i am talking about
  7. And does somebody know a way to look into source files? Then i could see it for myself
  8. Okay thx! But now why cant i put this after my achievement: .registerAchievement() and if so. is there a other method for the achievment registering?
  9. What on earth. What is this? I tried some things. But now i got everything exept the achievement showing up at my achievement page or the normal one. Can you help me? I This is the new code: package com.mart.achievements; import net.minecraft.block.Block; import net.minecraft.init.Blocks; import net.minecraft.init.Items; import net.minecraft.item.ItemStack; import net.minecraft.stats.Achievement; import net.minecraft.stats.AchievementList; import net.minecraftforge.common.AchievementPage; import net.minecraftforge.common.MinecraftForge; import cpw.mods.fml.common.Mod; import cpw.mods.fml.common.Mod.EventHandler; import cpw.mods.fml.common.event.FMLInitializationEvent; import cpw.mods.fml.common.event.FMLPostInitializationEvent; import cpw.mods.fml.common.event.FMLPreInitializationEvent; import cpw.mods.fml.common.registry.GameRegistry; import cpw.mods.fml.common.registry.LanguageRegistry; @Mod(modid = Achievements.modid, version = Achievements.version) public class Achievements { public static final String modid = "More Achievements!"; public static final String version = "Version 1.0"; @EventHandler public void config(FMLPreInitializationEvent event) { } //everything public static Achievement Dirt; @EventHandler public void load(FMLInitializationEvent event) { System.out.println("Loaded!"); AchievementPage.registerAchievementPage(page1); MinecraftForge.EVENT_BUS.register(new PickupHandler()); } @EventHandler public void modsLoaded(FMLPostInitializationEvent event) { //I NEED THIS LINE CORRECTED. Dirt = new Achievement("Dirt", "Dirt", 0, 0, Blocks.dirt, null); this.addAchievementName("Dirt", "Dirt.. Really?"); this.addAchievementDesc("Dirt", "You just found a piece of dirt.."); } private void addAchievementName(String ach, String name) { LanguageRegistry.instance().addStringLocalization("achievement." + ach, "en_US", name); } private void addAchievementDesc(String ach, String desc) { LanguageRegistry.instance().addStringLocalization("achievement." + ach + ".desc", "en_US", desc); } public static AchievementPage page1 = new AchievementPage("More Achievements!"); } package com.mart.achievements; import cpw.mods.fml.common.eventhandler.SubscribeEvent; import cpw.mods.fml.common.gameevent.PlayerEvent; import cpw.mods.fml.common.gameevent.PlayerEvent.ItemPickupEvent; import net.minecraft.entity.item.EntityItem; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.init.Blocks; import net.minecraft.item.Item; import net.minecraft.item.ItemStack; public class PickupHandler { private ItemStack MyBlockStack = new ItemStack(Blocks.dirt); @SubscribeEvent public void SomethingPickedup(ItemPickupEvent event) { if (event.pickedUp.getEntityItem() == MyBlockStack) { event.player.addStat(Achievements.Dirt, 1); } } }
  10. So i finnaly figured out how to do this but it still gives me a error. Is this the good line of code to make a new achievement. And how do i put it in my new achievement tab? public static Achievement Dirt; @EventHandler public void modsLoaded(FMLPostInitializationEvent event) { Dirt = new Achievement(27, "Dirt", 0, 0, Blocks.dirt, null).isAchievement(); this.addAchievementName("Dirt", "Dirt.. Really?"); this.addAchievementDesc("Dirt", "You just found a piece of dirt.."); }
  11. Well if you look at my code sometimes is says //Error I cant fix these or dont know what to put there
  12. Okay now i got that i still dont really know hot to do the rest. Since i cant find anything decent or i dont know what to do.
  13. Thx! But im not that good at modding and i dont know how to implement this.
  14. So i tried some things and sometimes i dont know what to do or i dont know whats wrong! So can someone figure out what i did wrong or why they give error messages? Im modding in Forge 1.7.2 Main class called Achievements

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.