1.7.10 moving forward to v1.1.0!
This commit is contained in:
parent
1778cfa737
commit
a92efa364d
51 changed files with 849 additions and 175 deletions
|
@ -263,22 +263,18 @@ public class SpellEffectEarth extends SpellEffect
|
|||
@Override
|
||||
protected int getCostForOffenseTool()
|
||||
{
|
||||
// TODO Auto-generated method stub
|
||||
return 0;
|
||||
return 1000;
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
protected int getCostForDefenseTool()
|
||||
{
|
||||
return (int)(1000 * (1 + this.potencyEnhancement*0.1f) * (1 + this.powerEnhancement*0.2f) * Math.pow(0.85, costEnhancement));
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
protected int getCostForEnvironmentTool()
|
||||
{
|
||||
return (int)(10 * (1+this.potencyEnhancement*0.8) * Math.pow(1.5*this.powerEnhancement + 3, 2) * Math.pow(0.85, this.costEnhancement));
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -17,6 +17,7 @@ import WayofTime.alchemicalWizardry.common.spell.complex.effect.impactEffects.fi
|
|||
import WayofTime.alchemicalWizardry.common.spell.complex.effect.impactEffects.fire.SelfEnvironmentalFire;
|
||||
import WayofTime.alchemicalWizardry.common.spell.complex.effect.impactEffects.fire.SelfOffensiveFire;
|
||||
import WayofTime.alchemicalWizardry.common.spell.complex.effect.impactEffects.fire.ToolDefaultFire;
|
||||
import WayofTime.alchemicalWizardry.common.spell.complex.effect.impactEffects.fire.ToolEnvironmentalFire;
|
||||
import WayofTime.alchemicalWizardry.common.spell.complex.effect.impactEffects.fire.ToolOffensiveFire;
|
||||
|
||||
public class SpellEffectFire extends SpellEffect
|
||||
|
@ -181,15 +182,21 @@ public class SpellEffectFire extends SpellEffect
|
|||
}
|
||||
|
||||
@Override
|
||||
public void defensiveModificationTool(SpellParadigmTool parad) {
|
||||
// TODO Auto-generated method stub
|
||||
public void defensiveModificationTool(SpellParadigmTool parad)
|
||||
{
|
||||
parad.addCritChance("defFire", this.potencyEnhancement);
|
||||
|
||||
parad.addDuration("defFire", 1200 * this.powerEnhancement);
|
||||
|
||||
parad.addToolString("defFire", "Unbreaking" + " " + SpellHelper.getNumeralForInt(this.powerEnhancement + 1));
|
||||
}
|
||||
|
||||
@Override
|
||||
public void environmentalModificationTool(SpellParadigmTool parad) {
|
||||
// TODO Auto-generated method stub
|
||||
public void environmentalModificationTool(SpellParadigmTool parad)
|
||||
{
|
||||
parad.addBlockBreakEffect(new ToolEnvironmentalFire(this.powerEnhancement,this.potencyEnhancement,this.costEnhancement));
|
||||
|
||||
parad.addToolString("envFire", "Magma Plume" + " " + SpellHelper.getNumeralForInt(this.powerEnhancement + 1));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -201,18 +208,18 @@ public class SpellEffectFire extends SpellEffect
|
|||
@Override
|
||||
protected int getCostForOffenseTool()
|
||||
{
|
||||
return (int)(0); //TODO
|
||||
return (int)(1000 * (1 + this.powerEnhancement*0.3f) * (1 + this.potencyEnhancement*0.2f) * Math.pow(0.85, costEnhancement));
|
||||
}
|
||||
|
||||
@Override
|
||||
protected int getCostForDefenseTool() {
|
||||
// TODO Auto-generated method stub
|
||||
return 0;
|
||||
protected int getCostForDefenseTool()
|
||||
{
|
||||
return (int)(500 * (1 + this.powerEnhancement*0.5f) * (1 + this.potencyEnhancement) * Math.pow(0.85, costEnhancement));
|
||||
}
|
||||
|
||||
@Override
|
||||
protected int getCostForEnvironmentTool() {
|
||||
// TODO Auto-generated method stub
|
||||
protected int getCostForEnvironmentTool()
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -0,0 +1,47 @@
|
|||
package WayofTime.alchemicalWizardry.common.spell.complex.effect.impactEffects.fire;
|
||||
|
||||
import java.util.Random;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.init.Blocks;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.common.util.ForgeDirection;
|
||||
import WayofTime.alchemicalWizardry.common.spell.complex.effect.impactEffects.tool.OnBreakBlockEffect;
|
||||
|
||||
public class ToolEnvironmentalFire extends OnBreakBlockEffect
|
||||
{
|
||||
public ToolEnvironmentalFire(int power, int potency, int cost)
|
||||
{
|
||||
super(power, potency, cost);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int onBlockBroken(ItemStack container, World world, EntityPlayer player, Block block, int meta, int x, int y, int z, ForgeDirection sideBroken)
|
||||
{
|
||||
int amount = 0;
|
||||
int cost = (int)(250 * (1 - 0.1f*powerUpgrades) * Math.pow(0.85, costUpgrades));
|
||||
int radius = this.powerUpgrades;
|
||||
float chance = 0.35f + 0.15f*this.potencyUpgrades;
|
||||
|
||||
for(int i=-radius; i<=radius; i++)
|
||||
{
|
||||
for(int j=-radius; j<=radius; j++)
|
||||
{
|
||||
for(int k=-radius; k<=radius; k++)
|
||||
{
|
||||
Block blockAffected = world.getBlock(x + i -sideBroken.offsetX, y + j, z + k - sideBroken.offsetZ);
|
||||
|
||||
if((new Random().nextFloat() <= chance) && (blockAffected == Blocks.gravel || blockAffected == Blocks.stone || blockAffected == Blocks.cobblestone))
|
||||
{
|
||||
world.setBlock(x + i -sideBroken.offsetX, y + j, z + k - sideBroken.offsetZ, Blocks.lava);
|
||||
amount += cost;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return amount;
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue