Skip to content
Permalink
Browse files

Normalize all line endings

  • Loading branch information...
WeAthFoLD committed Jul 22, 2018
1 parent b937a21 commit 270a750a94f851c6c8468d05ffc8c48350dbee7b
@@ -0,0 +1,2 @@

text eol=crlf
@@ -0,0 +1,60 @@
/**
* Copyright (c) Lambda Innovation, 2013-2016
* This file is part of the AcademyCraft mod.
* https://github.com/LambdaInnovation/AcademyCraft
* Licensed under GPLv3, see project root for more information.
*/
package cn.academy.support.ic2;

import cn.academy.ability.api.event.AbilityActivateEvent;
import cn.academy.vanilla.electromaster.entity.EntitySurroundArc;
import cn.lambdalib.util.helper.BlockPos;
import cn.lambdalib.util.mc.IBlockSelector;
import cn.lambdalib.util.mc.WorldUtils;
import cpw.mods.fml.common.eventhandler.SubscribeEvent;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
import ic2.core.block.wiring.BlockCable;
import net.minecraft.block.Block;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.world.World;
import net.minecraftforge.common.MinecraftForge;

import java.util.List;

/**
* @author KSkun
*/
public class IC2SkillHelper {

private static final IBlockSelector blockSelector = new IBlockSelector() {
@Override
public boolean accepts(World world, int x, int y, int z, Block block) {
if(block instanceof BlockCable) {
return true;
} else {
return false;
}
}
};

public void init() {
MinecraftForge.EVENT_BUS.register(this);
}

@SideOnly(Side.CLIENT)
@SubscribeEvent
public void onAbilityActive(AbilityActivateEvent event) {
spawnArc(event.player);
}

@SideOnly(Side.CLIENT)
public void spawnArc(EntityPlayer player) {
List<BlockPos> blockList = WorldUtils.getBlocksWithin(player, 5, 100, blockSelector);
World world = player.worldObj;
for(BlockPos bp : blockList) {
world.spawnEntityInWorld(new EntitySurroundArc(world, bp.x, bp.y, bp.z, 1, 1));
}
}

}
@@ -0,0 +1,23 @@
package cn.academy.vanilla;

import net.minecraft.util.ResourceLocation;
import net.minecraft.util.SoundEvent;
import net.minecraftforge.common.MinecraftForge;
import net.minecraftforge.event.RegistryEvent;
import net.minecraftforge.fml.common.eventhandler.SubscribeEvent;

public class ModuleSoundEvent
{
static{
MinecraftForge.EVENT_BUS.register(new ModuleSoundEvent());
}
public static SoundEvent silbarn_sound = new SoundEvent(new ResourceLocation( "random.bow"));
public static SoundEvent md_ray_small = new SoundEvent(new ResourceLocation( "academy","md.ray_small"));
public static SoundEvent silbarn_light = new SoundEvent(new ResourceLocation( "academy","entity.silbarn_light"));
public static SoundEvent silbarn_heavy = new SoundEvent(new ResourceLocation( "academy","entity.silbarn_heavy"));

@SubscribeEvent
public void onRegisterSound(RegistryEvent.Register<SoundEvent> event) {
event.getRegistry().registerAll(silbarn_sound, md_ray_small);
}
}
@@ -0,0 +1,53 @@
package cn.academy.vanilla.vecmanip;

import cn.academy.ability.api.Category;
import cn.academy.vanilla.ModuleVanilla;
import cn.academy.vanilla.vecmanip.skill.*;

public class CatVecManip extends Category {

public CatVecManip() {
super("vecmanip");
colorStyle.fromHexColor(0xff000000);

DirectedShock.setPosition(16, 45);
Groundshock.setPosition(64, 85);
VecAccel.setPosition(76, 40);
VecDeviation.setPosition(145, 53);
DirectedBlastwave.setPosition(136, 80);
StormWing.setPosition(130, 20);
BloodRetrograde.setPosition(204, 83);
VecReflection.setPosition(210, 50);
PlasmaCannon.setPosition(175, 14);

// Level 1
addSkill(DirectedShock$.MODULE$);
addSkill(Groundshock$.MODULE$);

// 2
addSkill(VecAccel$.MODULE$);
addSkill(VecDeviation$.MODULE$);

// 3
addSkill(DirectedBlastwave$.MODULE$);
addSkill(StormWing$.MODULE$);

// 4
addSkill(BloodRetrograde$.MODULE$);
addSkill(VecReflection$.MODULE$);

// 5
addSkill(PlasmaCannon$.MODULE$);

Groundshock.setParent(DirectedShock$.MODULE$);
VecAccel.setParent(DirectedShock$.MODULE$);
VecDeviation.setParent(VecAccel$.MODULE$);
DirectedBlastwave.setParent(Groundshock$.MODULE$);
StormWing.setParent(VecAccel$.MODULE$);
BloodRetrograde.setParent(DirectedBlastwave$.MODULE$);
VecReflection.setParent(VecDeviation$.MODULE$);
PlasmaCannon.setParent(StormWing$.MODULE$);

ModuleVanilla.addGenericSkills(this);
}
}
@@ -0,0 +1,70 @@
package cn.academy.vanilla.vecmanip.client.effect;

public class AnimPresets
{
public static CompTransformAnim createPrepareAnim()
{
CompTransformAnim anim = new CompTransformAnim(new CompTransform);

anim.animTransform.curveY = new CubicCurve();
val curvey = anim.animTransform.curveY;
curvey.addPoint(0, 0);
curvey.addPoint(0.5, 0.2);
curvey.addPoint(1, 0.4);

anim.animTransform.curveX = new CubicCurve();
val curvex = anim.animTransform.curveX;
curvex.addPoint(0, 0);
curvex.addPoint(1, -0.02);

anim.animTransform.curveZ = new CubicCurve();
val curvez = anim.animTransform.curveZ;
curvez.addPoint(0, 0);
curvez.addPoint(1, -0.05);

anim.animRotation.curveX = new CubicCurve();
val curverx = anim.animRotation.curveX;
curverx.addPoint(0, 0);
curverx.addPoint(1, -20);

// anim.animRotation.curveX.addPoint(0)
return anim;
}

public static void createPunchAnim()
{
CompTransformAnim anim = new CompTransformAnim(new CompTransform);

anim.animTransform.curveY = new CubicCurve();
val curvey = anim.animTransform.curveY;
curvey.addPoint(0, 0.8);
curvey.addPoint(0.5, 0.75);
curvey.addPoint(1, 0);

anim.animTransform.curveX = new CubicCurve();
val curvex = anim.animTransform.curveX;
curvex.addPoint(0, -0.04);
curvex.addPoint(0.5, -0.04);
curvex.addPoint(1, 0);

anim.animTransform.curveZ = new CubicCurve();
val curvez = anim.animTransform.curveZ;
curvez.addPoint(0, -0.0);
curvez.addPoint(0.3, -0.4);
curvez.addPoint(1, 0);

anim.animRotation.curveX = new CubicCurve();
val curverx = anim.animRotation.curveX;
curverx.addPoint(0, -40);
curverx.addPoint(0.5, -45);
curverx.addPoint(1, 0);

anim.animRotation.curveY = new CubicCurve();
val curvery = anim.animRotation.curveY;
curvery.addPoint(0, 0);
curvery.addPoint(0.3, 10);
curvery.addPoint(1, 0);

return anim;
}
}

0 comments on commit 270a750

Please sign in to comment.
You can’t perform that action at this time.