Compare commits

...
1 Commits
Author SHA1 Message Date
MysteriousAges fd82a0ef72 Fixing things, and adding balance to grafter. 2013-03-24 13:34:17 -07:00
6 changed files with 49 additions and 14 deletions

No files matched your search

+1 -1
View File
@@ -17,7 +17,7 @@
<property name="mc.version" value="1.4.7"/> <property name="mc.version" value="1.4.7"/>
<property name="forge.version" value="6.6.0.507"/> <property name="forge.version" value="6.6.0.507"/>
<property name="thaumicbees.version" value="1.4.3b"/> <property name="thaumicbees.version" value="1.4.3c"/>
<!-- for local deployment only, not used by main --> <!-- for local deployment only, not used by main -->
<property name="deploy.type" value="previews" /> <property name="deploy.type" value="previews" />
+6
View File
@@ -1,3 +1,9 @@
1.4.3c
Thaumium Grafter now doubles your chance to get Greatwood & Silverwood saplings.
Thaumium Grafter now takes extra damage when trying to break Greatwood & Silverwood leaves.
Thaumium Grafter now has a balancing feature when repairing.
Extra... uh. "Enhancements". =D
1.4.3b 1.4.3b
Greatwood & Silverwood planks support BuildCraft facades. Greatwood & Silverwood planks support BuildCraft facades.
Tweaking Aura cost for Repair on Thaumium Grafters and other balance. Tweaking Aura cost for Repair on Thaumium Grafters and other balance.
+4 -4
View File
@@ -49,11 +49,11 @@ public class Allele implements IAllele
Allele.spawnBats = new AlleleEffectSpawnMob("effectBatty", false, ThaumcraftHelper.Entity.FIREBAT.entityID); Allele.spawnBats = new AlleleEffectSpawnMob("effectBatty", false, ThaumcraftHelper.Entity.FIREBAT.entityID);
Allele.spawnBats.setThrottle(300).setSpawnsOnPlayerNear("Bat"); Allele.spawnBats.setThrottle(300).setSpawnsOnPlayerNear("Bat");
Allele.spawnWisp = new AlleleEffectSpawnWisp("effectWispy", false, ThaumcraftHelper.Entity.WISP.entityID); Allele.spawnWisp = new AlleleEffectSpawnWisp("effectWispy", false, ThaumcraftHelper.Entity.WISP.entityID, "thaumcraft.wisplive");
Allele.spawnWisp.setThrottle(1800); Allele.spawnWisp.setThrottle(1800).setChanceToSpawn(79);
Allele.spawnGhast = new AlleleEffectSpawnMob("Ghast", false, "Ghast"); Allele.spawnGhast = new AlleleEffectSpawnMob("Ghast", false, "Ghast", "mob.ghast.moan");
Allele.spawnGhast.setThrottle(2000).setChanceToSpawn(20).setMaxMobsInSpawnZone(1); Allele.spawnGhast.setThrottle(2060).setChanceToSpawn(10).setMaxMobsInSpawnZone(1);
} }
private String uid; private String uid;
@@ -21,11 +21,17 @@ public class AlleleEffectSpawnMob extends AlleleEffect
protected boolean spawnsWhilePlayerNear; protected boolean spawnsWhilePlayerNear;
protected String alternateMob; protected String alternateMob;
protected String mobName; protected String mobName;
protected String mobSound;
protected int throttle; protected int throttle;
protected int chanceToSpawn; protected int chanceToSpawn;
protected int maxMobsInArea; protected int maxMobsInArea;
public AlleleEffectSpawnMob(String id, boolean isDominant, String mobToSpawn) public AlleleEffectSpawnMob(String id, boolean isDominant, String mobToSpawn)
{
this(id, isDominant, mobToSpawn, null);
}
public AlleleEffectSpawnMob(String id, boolean isDominant, String mobToSpawn, String mobSoundFx)
{ {
super(id, isDominant); super(id, isDominant);
this.aggosOnPlayer = false; this.aggosOnPlayer = false;
@@ -33,6 +39,7 @@ public class AlleleEffectSpawnMob extends AlleleEffect
this.throttle = 200; this.throttle = 200;
this.chanceToSpawn = 100; this.chanceToSpawn = 100;
this.maxMobsInArea = 6; this.maxMobsInArea = 6;
this.mobSound = mobSoundFx;
} }
@Override @Override
@@ -109,6 +116,17 @@ public class AlleleEffectSpawnMob extends AlleleEffect
} }
else else
{ {
if (this.mobSound != null && w.rand.nextInt(100) < 35)
{
int range = genome.getTerritory()[0];
double x = housing.getXCoord() + w.rand.nextDouble() * (range * 2) - range;
range = genome.getTerritory()[1];
double y = housing.getYCoord() + w.rand.nextDouble() * (range * 2) - range;
range = genome.getTerritory()[2];
double z = housing.getZCoord() + w.rand.nextDouble() * (range * 2) - range;
w.playSoundEffect(x, y, z, this.mobSound, 0.5f,
(w.rand.nextFloat() - w.rand.nextFloat()) * 0.2f + 1.0f);
}
storedData.setBoolean(0, true); storedData.setBoolean(0, true);
} }
} }
@@ -18,9 +18,9 @@ public class AlleleEffectSpawnWisp extends AlleleEffectSpawnMob
private byte[] wispTypes = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47 }; private byte[] wispTypes = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47 };
public AlleleEffectSpawnWisp(String id, boolean isDominant, String mobToSpawn) public AlleleEffectSpawnWisp(String id, boolean isDominant, String mobToSpawn, String soundToPlay)
{ {
super(id, isDominant, mobToSpawn); super(id, isDominant, mobToSpawn, soundToPlay);
} }
@Override @Override
@@ -57,11 +57,7 @@ public class AlleleEffectSpawnWisp extends AlleleEffectSpawnMob
Field type = wispEntity.getDeclaredField("type"); Field type = wispEntity.getDeclaredField("type");
type.setByte(mob, wispTypes[world.rand.nextInt(wispTypes.length)]); type.setByte(mob, wispTypes[world.rand.nextInt(wispTypes.length)]);
} }
catch (Exception e) catch (Exception e) { /*Last time I had a request to post error messages, I regretted it.*/ }
{
FMLLog.info("ThaumicBees is using an invalid classname: " + ThaumcraftHelper.Entity.WISP.getClassName()
+ " Please report this error in the thread if you see it.", (Object[])null);
}
spawnedFlag = world.spawnEntityInWorld(mob); spawnedFlag = world.spawnEntityInWorld(mob);
if (this.aggosOnPlayer && player != null) if (this.aggosOnPlayer && player != null)
@@ -48,7 +48,22 @@ public class ItemThaumiumGrafter extends Item implements IVisRepairable, IToolGr
@Override @Override
public boolean onBlockDestroyed(ItemStack itemstack, World world, int id, int x, int y, int z, EntityLiving entityliving) { public boolean onBlockDestroyed(ItemStack itemstack, World world, int id, int x, int y, int z, EntityLiving entityliving) {
itemstack.damageItem(1, entityliving); int damage = 1;
if (id == Config.tcLeaf.blockID)
{
Block block = Block.blocksList[id];
int meta = world.getBlockMetadata(x, y, z) & 1;
block.dropBlockAsItemWithChance(world, x, y, z, meta, 0, 0);
if (meta == ThaumcraftHelper.TreeType.GREATWOOD.ordinal())
{
damage = 2;
}
else if (meta == ThaumcraftHelper.TreeType.SILVERWOOD.ordinal())
{
damage = 4;
}
}
itemstack.damageItem(damage, entityliving);
return true; return true;
} }
@@ -86,7 +101,7 @@ public class ItemThaumiumGrafter extends Item implements IVisRepairable, IToolGr
if (e instanceof EntityPlayer) if (e instanceof EntityPlayer)
{ {
EntityPlayer p = (EntityPlayer)e; EntityPlayer p = (EntityPlayer)e;
p.addExhaustion(0.12f); p.addExhaustion(0.19f);
} }
stack.damageItem(-1, (EntityLiving)e); stack.damageItem(-1, (EntityLiving)e);
} }