Unlock tweaks
This commit is contained in:
@@ -88,6 +88,8 @@ public class Planet extends UnlockableContent{
|
||||
t.printStackTrace();
|
||||
}
|
||||
}
|
||||
|
||||
sectors.random().unlocked = true;
|
||||
}else{
|
||||
sectors = new Array<>();
|
||||
}
|
||||
|
||||
@@ -21,6 +21,7 @@ public class Sector{
|
||||
public final SectorData data;
|
||||
|
||||
public @Nullable SaveSlot save;
|
||||
public boolean unlocked;
|
||||
|
||||
//TODO implement a dynamic (?) launch period
|
||||
public int launchPeriod = 10;
|
||||
@@ -35,7 +36,7 @@ public class Sector{
|
||||
}
|
||||
|
||||
public boolean locked(){
|
||||
return true;
|
||||
return !unlocked;
|
||||
}
|
||||
|
||||
/** @return light dot product in the range [0, 1]. */
|
||||
|
||||
@@ -213,7 +213,7 @@ public class PlanetDialog extends FloatingDialog{
|
||||
batch.proj().mul(planet.getTransform(mat));
|
||||
|
||||
for(Sector sec : planet.sectors){
|
||||
if(sec.save == null){
|
||||
if(sec.locked()){
|
||||
draw(sec, shadowColor, -0.001f);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user