Compare commits

...

2 commits

Author SHA1 Message Date
Anuken
e399ae9182 arc 2025-11-24 18:30:03 -05:00
Anuken
b3f0e9399d Fixed tests 2025-11-24 17:29:36 -05:00
3 changed files with 5 additions and 3 deletions

View file

@ -95,8 +95,9 @@ public class Block extends UnlockableContent implements Senseable{
/** if true, double-tapping this configurable block clears configuration. */ /** if true, double-tapping this configurable block clears configuration. */
public boolean clearOnDoubleTap = false; public boolean clearOnDoubleTap = false;
/** whether this block has a tile entity that updates */ /** whether this block has a tile entity that updates */
@NoPatch
public boolean update; public boolean update;
/** whether this block has health and can be destroyed */ /** whether this block has health and can be destroyed. note that setting this to false does nothing if update = true! */
public boolean destructible; public boolean destructible;
/** whether unloaders work on this block */ /** whether unloaders work on this block */
public boolean unloadable = true; public boolean unloadable = true;

View file

@ -26,4 +26,4 @@ org.gradle.caching=true
org.gradle.internal.http.socketTimeout=100000 org.gradle.internal.http.socketTimeout=100000
org.gradle.internal.http.connectionTimeout=100000 org.gradle.internal.http.connectionTimeout=100000
android.enableR8.fullMode=false android.enableR8.fullMode=false
archash=65d654d634 archash=6d94644c8b

View file

@ -480,6 +480,7 @@ public class PatcherTests{
@Test @Test
void addWeapon() throws Exception{ void addWeapon() throws Exception{
int oldSize = UnitTypes.flare.weapons.size;
Vars.state.patcher.apply(Seq.with(""" Vars.state.patcher.apply(Seq.with("""
unit.flare.weapons.+: { unit.flare.weapons.+: {
x: 0 x: 0
@ -493,7 +494,7 @@ public class PatcherTests{
""")); """));
assertNoWarnings(); assertNoWarnings();
assertEquals(3, UnitTypes.flare.weapons.size); assertEquals(oldSize + 1, UnitTypes.flare.weapons.size);
assertEquals(100, UnitTypes.flare.weapons.peek().bullet.damage); assertEquals(100, UnitTypes.flare.weapons.peek().bullet.damage);
} }