Fix Boat Trails Being Drawn on Land (#5340)
* update * Revert "update" This reverts commit6ff3523276. * Hacky Implementation * Revert "Hacky Implementation" This reverts commit632121312d. * Not so Hacky Implementation Co-authored-by: Leonwang4234 <62972692+Leonwang4234@users.noreply.github.com> Co-authored-by: Leonwang4234 <leonwang4234@gmail.com> Co-authored-by: Anuken <arnukren@gmail.com>
This commit is contained in:
@@ -15,6 +15,8 @@ import mindustry.type.*;
|
||||
import mindustry.world.*;
|
||||
import mindustry.world.blocks.environment.*;
|
||||
|
||||
import static mindustry.Vars.*;
|
||||
|
||||
@Component
|
||||
abstract class WaterMoveComp implements Posc, Velc, Hitboxc, Flyingc, Unitc{
|
||||
@Import float x, y, rotation;
|
||||
@@ -31,7 +33,7 @@ abstract class WaterMoveComp implements Posc, Velc, Hitboxc, Flyingc, Unitc{
|
||||
|
||||
int sign = i == 0 ? -1 : 1;
|
||||
float cx = Angles.trnsx(rotation - 90, type.trailX * sign, type.trailY) + x, cy = Angles.trnsy(rotation - 90, type.trailX * sign, type.trailY) + y;
|
||||
t.update(cx, cy);
|
||||
t.update(cx, cy, world.floorWorld(cx, cy).isLiquid ? 1 : 0);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user