Natives
This commit is contained in:
@@ -30,6 +30,7 @@ dependencies{
|
|||||||
|
|
||||||
natives "com.github.Anuken.Arc:natives-android:${getArcHash()}"
|
natives "com.github.Anuken.Arc:natives-android:${getArcHash()}"
|
||||||
natives "com.github.Anuken.Arc:natives-freetype-android:${getArcHash()}"
|
natives "com.github.Anuken.Arc:natives-freetype-android:${getArcHash()}"
|
||||||
|
natives "com.github.Anuken.Arc:natives-box2d-android:${getArcHash()}"
|
||||||
}
|
}
|
||||||
|
|
||||||
task deploy(type: Copy){
|
task deploy(type: Copy){
|
||||||
|
|||||||
@@ -206,6 +206,7 @@ project(":ios"){
|
|||||||
|
|
||||||
compile arcModule("natives:natives-ios")
|
compile arcModule("natives:natives-ios")
|
||||||
compile arcModule("natives:natives-freetype-ios")
|
compile arcModule("natives:natives-freetype-ios")
|
||||||
|
compile arcModule("natives:natives-box2d-ios")
|
||||||
compile arcModule("backends:backend-robovm")
|
compile arcModule("backends:backend-robovm")
|
||||||
|
|
||||||
compileOnly project(":annotations")
|
compileOnly project(":annotations")
|
||||||
|
|||||||
@@ -3,6 +3,7 @@ package mindustry.entities.units;
|
|||||||
import arc.math.*;
|
import arc.math.*;
|
||||||
import arc.math.geom.*;
|
import arc.math.geom.*;
|
||||||
import arc.util.*;
|
import arc.util.*;
|
||||||
|
import mindustry.entities.*;
|
||||||
import mindustry.gen.*;
|
import mindustry.gen.*;
|
||||||
import mindustry.world.*;
|
import mindustry.world.*;
|
||||||
import mindustry.world.meta.*;
|
import mindustry.world.meta.*;
|
||||||
@@ -36,10 +37,11 @@ public class AIController implements UnitController{
|
|||||||
}
|
}
|
||||||
|
|
||||||
protected void targetClosest(){
|
protected void targetClosest(){
|
||||||
//Teamc newTarget = Units.closestTarget(unit.team(), unit.x(), unit.y(), Math.max(unit.range(), unit.type().range), u -> (unit.type().targetAir && u.isFlying()) || (unit.type().targetGround && !u.isFlying()));
|
//TODO optimize!
|
||||||
//if(newTarget != null){
|
Teamc newTarget = Units.closestTarget(unit.team(), unit.x(), unit.y(), Math.max(unit.range(), unit.type().range), u -> (unit.type().targetAir && u.isFlying()) || (unit.type().targetGround && !u.isFlying()));
|
||||||
// target = newTarget;
|
if(newTarget != null){
|
||||||
//}
|
target = newTarget;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
@@ -1,3 +1,3 @@
|
|||||||
org.gradle.daemon=true
|
org.gradle.daemon=true
|
||||||
org.gradle.jvmargs=-Xms256m -Xmx1024m
|
org.gradle.jvmargs=-Xms256m -Xmx1024m
|
||||||
archash=9fc6cd8c90e0665cc3a583879b2007fe29fbc929
|
archash=a6056fa47248251552aacd365648030f4f6dd3a4
|
||||||
|
|||||||
@@ -49,7 +49,7 @@ if(!hasProperty("release")){
|
|||||||
':Arc:natives:natives-freetype-ios',
|
':Arc:natives:natives-freetype-ios',
|
||||||
':Arc:natives:natives-box2d-desktop',
|
':Arc:natives:natives-box2d-desktop',
|
||||||
':Arc:natives:natives-box2d-android',
|
':Arc:natives:natives-box2d-android',
|
||||||
//':Arc:natives:natives-box2d-ios', TODO
|
':Arc:natives:natives-box2d-ios',
|
||||||
':Arc:backends',
|
':Arc:backends',
|
||||||
':Arc:backends:backend-sdl',
|
':Arc:backends:backend-sdl',
|
||||||
':Arc:backends:backend-android',
|
':Arc:backends:backend-android',
|
||||||
|
|||||||
Reference in New Issue
Block a user