Research fixes

This commit is contained in:
Anuken
2020-07-24 23:56:14 -04:00
parent 38e55ab541
commit 20077738d2
9 changed files with 48 additions and 38 deletions
+8 -8
View File
@@ -3,29 +3,29 @@ package mindustry.game;
import arc.*;
import arc.scene.ui.layout.*;
import arc.util.ArcAnnotate.*;
import mindustry.ctype.*;
import mindustry.type.*;
import mindustry.world.*;
/** Holds objective classes. */
public class Objectives{
public static class Unlock implements Objective{
public @NonNull Block block;
public static class Research implements Objective{
public @NonNull UnlockableContent content;
public Unlock(Block block){
this.block = block;
public Research(UnlockableContent content){
this.content = content;
}
protected Unlock(){}
protected Research(){}
@Override
public boolean complete(){
return block.unlocked();
return content.unlocked();
}
@Override
public String display(){
return Core.bundle.format("requirement.unlock", block.localizedName);
return Core.bundle.format("requirement.research", content.emoji() + " " + content.localizedName);
}
}