Skip to content

Commit

Permalink
Added achievement "Better Crafting"
Browse files Browse the repository at this point in the history
- Added the achievement called "Better Crafting"
  • Loading branch information
fuj1n committed Dec 18, 2013
1 parent 3733154 commit f84004c
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 10 deletions.
2 changes: 2 additions & 0 deletions resources/assets/tinker/lang/en_US.lang
Original file line number Diff line number Diff line change
Expand Up @@ -598,6 +598,7 @@ achievement.tconstruct.preparedFight=Prepared to Fight
achievement.tconstruct.enemySlayer=Enemy Slayer
achievement.tconstruct.dualConvenience=Dual Convenience
achievement.tconstruct.doingItWrong=Doing it wrong
achievement.tconstruct.betterCrafting=Better Crafting

achievement.tconstruct.beginner.desc=Open the "Materials and You" manual
achievement.tconstruct.pattern.desc=Craft your first blank pattern
Expand All @@ -608,6 +609,7 @@ achievement.tconstruct.preparedFight.desc=Create your first weapon
achievement.tconstruct.enemySlayer.desc=Slay a mob
achievement.tconstruct.dualConvenience.desc=Kill a mob with a frying pan, and then cook their meat in it
achievement.tconstruct.doingItWrong.desc=You are doing it wrong!
achievement.tconstruct.betterCrafting.desc=Craft a Crafting Station by placing a Crafting Table by itself into the crafting grid

knapsack.tooltip=A Knapsack to hold your things.
strangefood1.tooltip=It smells terrible, but if you
Expand Down
16 changes: 6 additions & 10 deletions src/main/java/tconstruct/common/TContent.java
Original file line number Diff line number Diff line change
Expand Up @@ -830,17 +830,13 @@ public void addAchievements ()

achievements.put("tconstruct.beginner", new Achievement(2741, "tconstruct.beginner", 0, 0, TRepo.manualBook, null).setIndependent().registerAchievement());
achievements.put("tconstruct.pattern", new Achievement(2742, "tconstruct.pattern", 2, 1, TRepo.blankPattern, achievements.get("tconstruct.beginner")).registerAchievement());
achievements.put("tconstruct.tinkerer",
new Achievement(2743, "tconstruct.tinkerer", 2, 2, new ItemStack(TRepo.titleIcon, 1, 4096), achievements.get("tconstruct.pattern")).registerAchievement());
achievements.put("tconstruct.preparedFight",
new Achievement(2744, "tconstruct.preparedFight", 1, 3, new ItemStack(TRepo.titleIcon, 1, 4097), achievements.get("tconstruct.tinkerer")).registerAchievement());
achievements.put("tconstruct.proTinkerer", new Achievement(2745, "tconstruct.proTinkerer", 4, 4, new ItemStack(TRepo.titleIcon, 1, 4098), achievements.get("tconstruct.tinkerer")).setSpecial()
.registerAchievement());
achievements.put("tconstruct.tinkerer", new Achievement(2743, "tconstruct.tinkerer", 2, 2, new ItemStack(TRepo.titleIcon, 1, 4096), achievements.get("tconstruct.pattern")).registerAchievement());
achievements.put("tconstruct.preparedFight", new Achievement(2744, "tconstruct.preparedFight", 1, 3, new ItemStack(TRepo.titleIcon, 1, 4097), achievements.get("tconstruct.tinkerer")).registerAchievement());
achievements.put("tconstruct.proTinkerer", new Achievement(2745, "tconstruct.proTinkerer", 4, 4, new ItemStack(TRepo.titleIcon, 1, 4098), achievements.get("tconstruct.tinkerer")).setSpecial().registerAchievement());
achievements.put("tconstruct.smelteryMaker", new Achievement(2746, "tconstruct.smelteryMaker", -2, -1, TRepo.smeltery, achievements.get("tconstruct.beginner")).registerAchievement());
achievements.put("tconstruct.enemySlayer",
new Achievement(2747, "tconstruct.enemySlayer", 0, 5, new ItemStack(TRepo.titleIcon, 1, 4099), achievements.get("tconstruct.preparedFight")).registerAchievement());
achievements.put("tconstruct.dualConvenience", new Achievement(2748, "tconstruct.dualConvenience", 0, 7, new ItemStack(TRepo.titleIcon, 1, 4100), achievements.get("tconstruct.enemySlayer"))
.setSpecial().registerAchievement());
achievements.put("tconstruct.enemySlayer", new Achievement(2747, "tconstruct.enemySlayer", 0, 5, new ItemStack(TRepo.titleIcon, 1, 4099), achievements.get("tconstruct.preparedFight")).registerAchievement());
achievements.put("tconstruct.dualConvenience", new Achievement(2748, "tconstruct.dualConvenience", 0, 7, new ItemStack(TRepo.titleIcon, 1, 4100), achievements.get("tconstruct.enemySlayer")).setSpecial().registerAchievement());
achievements.put("tconstruct.doingItWrong", new Achievement(2749, "tconstruct.doingItWrong", -2, -3, new ItemStack(TRepo.manualBook, 1, 2), achievements.get("tconstruct.smelteryMaker")).registerAchievement());
achievements.put("tconstruct.betterCrafting", new Achievement(2750, "tconstruct.betterCrafting", -2, 2, TRepo.craftingStationWood, achievements.get("tconstruct.beginner")).registerAchievement());
}
}
4 changes: 4 additions & 0 deletions src/main/java/tconstruct/util/TCraftingHandler.java
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,10 @@ public void onCrafting (EntityPlayer player, ItemStack item, IInventory craftMat
}
player.addStat(TAchievements.achievements.get("tconstruct.smelteryMaker"), 1);
}

if (itemID == TRepo.craftingStationWood.blockID){
player.addStat(TAchievements.achievements.get("tconstruct.betterCrafting"), 1);
}
}
}

Expand Down

0 comments on commit f84004c

Please sign in to comment.