Merge branches 'master' and 'mech-rework' of https://github.com/Anuken/Mindustry into mech-rework
# Conflicts: # android/src/mindustry/android/AndroidLauncher.java # annotations/src/main/java/mindustry/annotations/SerializeAnnotationProcessor.java # annotations/src/main/java/mindustry/annotations/impl/AssetsAnnotationProcessor.java # build.gradle # core/assets-raw/fontgen/config.json # core/assets/bundles/bundle_cs.properties # core/assets/bundles/bundle_it.properties # core/assets/fonts/font.ttf # core/assets/fonts/icon.ttf # core/assets/icons/icons.properties # core/assets/sprites/block_colors.png # core/assets/sprites/sprites.atlas # core/assets/sprites/sprites.png # core/assets/sprites/sprites3.png # core/assets/sprites/sprites5.png # core/src/mindustry/content/UnitTypes.java # core/src/mindustry/core/NetClient.java # core/src/mindustry/core/NetServer.java # core/src/mindustry/entities/bullet/BulletType.java # core/src/mindustry/entities/type/TileEntity.java # core/src/mindustry/maps/filters/FilterOption.java # core/src/mindustry/mod/Scripts.java # core/src/mindustry/ui/Fonts.java # core/src/mindustry/ui/dialogs/DeployDialog.java # core/src/mindustry/ui/fragments/HudFragment.java # core/src/mindustry/ui/fragments/MenuFragment.java # core/src/mindustry/world/blocks/production/Cultivator.java # core/src/mindustry/world/blocks/units/CommandCenter.java # gradle.properties # tools/src/mindustry/tools/FontGenerator.java
This commit is contained in:
@@ -3,8 +3,7 @@ package mindustry.entities.bullet;
|
||||
import arc.audio.*;
|
||||
import arc.math.*;
|
||||
import mindustry.content.*;
|
||||
import mindustry.ctype.Content;
|
||||
import mindustry.ctype.ContentType;
|
||||
import mindustry.ctype.*;
|
||||
import mindustry.entities.*;
|
||||
import mindustry.entities.Effects.*;
|
||||
import mindustry.entities.effect.*;
|
||||
@@ -41,7 +40,9 @@ public abstract class BulletType extends Content{
|
||||
public float recoil;
|
||||
/** Whether to kill the shooter when this is shot. For suicide bombers. */
|
||||
public boolean killShooter;
|
||||
|
||||
/** Whether to instantly make the bullet disappear. */
|
||||
public boolean instantDisappear;
|
||||
/** Damage dealt in splash. 0 to disable.*/
|
||||
public float splashDamage = 0f;
|
||||
/** Knockback in velocity. */
|
||||
public float knockback;
|
||||
@@ -151,6 +152,10 @@ public abstract class BulletType extends Content{
|
||||
if(killShooter && b.getOwner() instanceof HealthTrait){
|
||||
((HealthTrait)b.getOwner()).kill();
|
||||
}
|
||||
|
||||
if(instantDisappear){
|
||||
b.time(lifetime);
|
||||
}
|
||||
}
|
||||
|
||||
public void update(Bullet b){
|
||||
|
||||
Reference in New Issue
Block a user