Fixing Leap ritual.
This commit is contained in:
parent
04dcd073ad
commit
2f0ed920d4
src/main/java/WayofTime/alchemicalWizardry
|
@ -65,7 +65,7 @@ import WayofTime.alchemicalWizardry.common.items.thaumcraft.ItemSanguineArmour;
|
||||||
import WayofTime.alchemicalWizardry.common.potion.*;
|
import WayofTime.alchemicalWizardry.common.potion.*;
|
||||||
import WayofTime.alchemicalWizardry.common.renderer.AlchemyCircleRenderer;
|
import WayofTime.alchemicalWizardry.common.renderer.AlchemyCircleRenderer;
|
||||||
import WayofTime.alchemicalWizardry.common.rituals.*;
|
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.SummoningHelperAW;
|
||||||
import WayofTime.alchemicalWizardry.common.summoning.meteor.MeteorRegistry;
|
import WayofTime.alchemicalWizardry.common.summoning.meteor.MeteorRegistry;
|
||||||
import WayofTime.alchemicalWizardry.common.tileEntity.*;
|
import WayofTime.alchemicalWizardry.common.tileEntity.*;
|
||||||
|
|
|
@ -79,24 +79,54 @@ public class RitualEffectLeap extends RitualEffect
|
||||||
livingEntity.motionY = motionY;
|
livingEntity.motionY = motionY;
|
||||||
livingEntity.fallDistance = 0;
|
livingEntity.fallDistance = 0;
|
||||||
|
|
||||||
switch (direction)
|
if(livingEntity instanceof EntityPlayer)
|
||||||
{
|
{
|
||||||
case 1:
|
switch (direction)
|
||||||
SpellHelper.setPlayerSpeedFromServer((EntityPlayer) livingEntity, 0, motionY, -speed);
|
{
|
||||||
break;
|
case 1:
|
||||||
|
SpellHelper.setPlayerSpeedFromServer((EntityPlayer) livingEntity, 0, motionY, -speed);
|
||||||
|
break;
|
||||||
|
|
||||||
case 2:
|
case 2:
|
||||||
SpellHelper.setPlayerSpeedFromServer((EntityPlayer) livingEntity, speed, motionY, 0);
|
SpellHelper.setPlayerSpeedFromServer((EntityPlayer) livingEntity, speed, motionY, 0);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 3:
|
case 3:
|
||||||
SpellHelper.setPlayerSpeedFromServer((EntityPlayer) livingEntity, 0, motionY, speed);
|
SpellHelper.setPlayerSpeedFromServer((EntityPlayer) livingEntity, 0, motionY, speed);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 4:
|
case 4:
|
||||||
SpellHelper.setPlayerSpeedFromServer((EntityPlayer) livingEntity, -speed, motionY, 0);
|
SpellHelper.setPlayerSpeedFromServer((EntityPlayer) livingEntity, -speed, motionY, 0);
|
||||||
break;
|
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++;
|
flag++;
|
||||||
} else
|
} else
|
||||||
|
|
Loading…
Reference in a new issue