This commit is contained in:
Anuken
2020-05-02 00:51:42 -04:00
parent c16c64b049
commit ef42f022c7
5 changed files with 103 additions and 51 deletions

View File

@@ -7,29 +7,27 @@ import mindustry.gen.*;
import mindustry.type.*;
public class UnitTypes implements ContentList{
//TODO reimplement - DO NOT USE
public static UnitType
ghoul, revenant, lich,
crawler, fortress, eruptor, chaosArray, eradicator;
//TODO this is awful
public static @EntityDef({Unitc.class, Legsc.class}) UnitType titan;
public static @EntityDef({Unitc.class, Legsc.class}) UnitType dagger;
public static @EntityDef({Unitc.class, WaterMovec.class}) UnitType vanguard;
//ground
public static @EntityDef({Unitc.class, Legsc.class}) UnitType titan, dagger, crawler, fortress, eruptor, chaosArray, eradicator;
//air
public static @EntityDef({Unitc.class}) UnitType wraith, reaper, ghoul, revenant, lich;
//mining
public static @EntityDef({Unitc.class, Minerc.class}) UnitType draug;
public static @EntityDef({Unitc.class, Trailc.class}) UnitType wraith;
public static @EntityDef({Unitc.class}) UnitType reaper;
public static @EntityDef({Unitc.class}) UnitType spirit;
public static @EntityDef({Unitc.class, Builderc.class}) UnitType phantom;
//TODO remove
public static UnitType alpha, delta, tau, omega, dart, javelin, trident, glaive;
public static UnitType starter;
//building
public static @EntityDef({Unitc.class, Builderc.class}) UnitType phantom, spirit;
//water
public static @EntityDef({Unitc.class, WaterMovec.class}) UnitType vanguard;
@Override
public void load(){
dagger = new UnitType("dagger"){{
speed = 0.5f;
drag = 0.3f;
hitsize = 8f;

View File

@@ -3,40 +3,12 @@ package mindustry.entities;
import mindustry.annotations.Annotations.*;
import mindustry.gen.*;
class GroupDefs{
@GroupDef(value = Entityc.class, mapping = true)
class gall{
}
@GroupDef(value = Playerc.class, mapping = true)
class gplayer{
}
@GroupDef(value = Bulletc.class, spatial = true, collide = true)
class gbullet{
}
@GroupDef(value = Unitc.class, spatial = true, mapping = true)
class gunit{
}
@GroupDef(Tilec.class)
class gtile{
}
@GroupDef(value = Syncc.class, mapping = true)
class gsync{
}
@GroupDef(Drawc.class)
class gdraw{
}
class GroupDefs<G>{
@GroupDef(value = Entityc.class, mapping = true) G all;
@GroupDef(value = Playerc.class, mapping = true) G player;
@GroupDef(value = Bulletc.class, spatial = true, collide = true) G bullet;
@GroupDef(value = Unitc.class, spatial = true, mapping = true) G unit;
@GroupDef(value = Tilec.class) G tile;
@GroupDef(value = Syncc.class, mapping = true) G sync;
@GroupDef(value = Drawc.class) G draw;
}