Hotfixing Autoloader redstone activation
Dieser Commit ist enthalten in:
Ursprung
14822378ce
Commit
c7f9e416ff
@ -42,21 +42,30 @@ abstract class IAutoLoader {
|
||||
|
||||
final boolean active;
|
||||
final int length;
|
||||
int status;
|
||||
|
||||
RedstoneActivation(IAutoLoader loader, Location location, int ticks, boolean active){
|
||||
super(loader, location);
|
||||
this.length = ticks;
|
||||
this.active = active;
|
||||
status = 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean perform() {
|
||||
return loader.setRedstone(location, active);
|
||||
status++;
|
||||
if(status < length)
|
||||
return false;
|
||||
|
||||
if(!loader.setRedstone(location, active))
|
||||
return false;
|
||||
status = 0;
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override
|
||||
int ticks() {
|
||||
return length;
|
||||
return 1;
|
||||
}
|
||||
}
|
||||
|
||||
|
In neuem Issue referenzieren
Einen Benutzer sperren