Skip to content

Commit

Permalink
do not delete new .bak file
Browse files Browse the repository at this point in the history
  • Loading branch information
nekit508 committed Aug 3, 2024
1 parent b162695 commit 652e3f1
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 22 deletions.
22 changes: 1 addition & 21 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -191,24 +191,4 @@ configure(rootProject){
command.execute(null, layout.projectDirectory.asFile).waitForProcessOutput(System.out, System.err)
}
}
}

for(def i = 0; i < 2; i++){
final def isDex = i == 1
final def name = isDex ? 'installDex' : 'install'
final def input = isDex ? tasks.dex : tasks.jar

tasks.register(name){
inputs.files input
doLast{
def folder = Fi.get(OS.getAppDataDirectoryString('Mindustry')).child('mods')
folder.mkdirs()

folder.child(tasks.jar.archiveFileName.get()).delete()
folder.child(tasks.dex.archiveFileName.get()).delete()

new Fi(input.archiveFile.get().asFile).copyTo(folder)
logger.log(LogLevel.LIFECYCLE, "Copied :${isDex ? 'dex' : 'jar'} output to $folder.")
}
}
}
}
Binary file modified res/sprites/blocks/distribution/tin-belt/conveyor-tin-belt.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
3 changes: 2 additions & 1 deletion src/fos/graphics/ConveyorSpritesPacker.java
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@

public class ConveyorSpritesPacker { // TODO rename
public static Field packer;
public static int spacing = 4;
static {
try {
packer = Vars.mods.getClass().getDeclaredField("packer");
Expand Down Expand Up @@ -45,7 +46,7 @@ public static void generateRegions(TextureAtlas.AtlasRegion region, String prefi
for (int y = 0; y < 5; y++) {
for (int x = 0; x < 5; x++) {
TextureAtlas.AtlasRegion newRegion = new TextureAtlas.AtlasRegion(
region.texture, region.getX() + x * 32, region.getY() + y * 32, 32, 32);
region.texture, region.getX() + x * (32 + spacing), region.getY() + y * (32 + spacing), 32, 32);

if(region.splits != null){
newRegion.splits = region.splits;
Expand Down

0 comments on commit 652e3f1

Please sign in to comment.