Fixing Leap ritual.

This commit is contained in:
WayofTime 2014-11-01 10:21:03 -04:00
parent 04dcd073ad
commit 2f0ed920d4
2 changed files with 44 additions and 14 deletions

View file

@ -65,7 +65,7 @@ import WayofTime.alchemicalWizardry.common.items.thaumcraft.ItemSanguineArmour;
import WayofTime.alchemicalWizardry.common.potion.*;
import WayofTime.alchemicalWizardry.common.renderer.AlchemyCircleRenderer;
import WayofTime.alchemicalWizardry.common.rituals.*;
import WayofTime.alchemicalWizardry.common.spell.simple.*
import WayofTime.alchemicalWizardry.common.spell.simple.*;
import WayofTime.alchemicalWizardry.common.summoning.SummoningHelperAW;
import WayofTime.alchemicalWizardry.common.summoning.meteor.MeteorRegistry;
import WayofTime.alchemicalWizardry.common.tileEntity.*;

View file

@ -79,6 +79,8 @@ public class RitualEffectLeap extends RitualEffect
livingEntity.motionY = motionY;
livingEntity.fallDistance = 0;
if(livingEntity instanceof EntityPlayer)
{
switch (direction)
{
case 1:
@ -97,6 +99,34 @@ public class RitualEffectLeap extends RitualEffect
SpellHelper.setPlayerSpeedFromServer((EntityPlayer) livingEntity, -speed, motionY, 0);
break;
}
}else
{
livingEntity.motionY = motionY;
switch (direction)
{
case 1:
livingEntity.motionX = 0.0;
livingEntity.motionZ = -speed;
break;
case 2:
livingEntity.motionX = speed;
livingEntity.motionZ = 0.0;
break;
case 3:
livingEntity.motionX = 0.0;
livingEntity.motionZ = -speed;
break;
case 4:
livingEntity.motionX = -speed;
livingEntity.motionZ = 0.0;
break;
}
}
flag++;
} else