Fixed build shader / Server now displays map directory

This commit is contained in:
Anuken 2019-02-06 13:59:10 -05:00
parent 4f9e64588f
commit 25658f2a0a
4 changed files with 13 additions and 12 deletions

View File

@ -22,7 +22,7 @@ bool id(vec2 coords, vec4 base){
}
bool cont(vec2 T, vec2 v){
float step = 1.0;
const float step = 3.0;
vec4 base = texture2D(u_texture, T);
return base.a > 0.1 &&
(id(T + vec2(0, step) * v, base) || id(T + vec2(0, -step) * v, base) ||
@ -41,13 +41,8 @@ void main() {
vec2 center = ((u_uv + u_uv2)/2.0 - u_uv) /v;
float dst = (abs(center.x - coords.x) + abs(center.y - coords.y))/2.0;
float chance = 1.0;
if(u_progress > 0.8){
chance = 1.0-(u_progress-0.8)*5.0;
}
if((mod(u_time / 1.5 + value, 20.0) < 5.0 && cont(t, v))){
if((mod(u_time / 1.5 + value, 20.0) < 15.0 && cont(t, v))){
gl_FragColor = u_color;
}else if(dst > (1.0-u_progress) * (center.x)){
gl_FragColor = color;

View File

@ -673,9 +673,10 @@ public class Blocks implements ContentList{
}};
junction = new Junction("junction"){{
requirements(Category.distribution, ItemStack.with(Items.copper, 2));
requirements(Category.distribution, ItemStack.with(Items.copper, 3));
speed = 26;
capacity = 32;
health = 25;
}};
itemBridge = new BufferedItemBridge("bridge-conveyor"){{

View File

@ -251,7 +251,7 @@ public class PlacementFragment extends Fragment{
//update category empty values
for(Category cat : Category.values()){
Array<Block> blocks = getByCategory(cat);
categoryEmpty[cat.ordinal()] = returnArray.isEmpty() || !returnArray.first().unlocked();
categoryEmpty[cat.ordinal()] = blocks.isEmpty() || !blocks.first().unlocked();
}
int f = 0;

View File

@ -244,10 +244,15 @@ public class ServerControl implements ApplicationListener{
});
handler.register("maps", "Display all available maps.", arg -> {
info("Maps:");
for(Map map : world.maps.all()){
info(" &ly{0}: &lb&fi{1} / {2}x{3}", map.name, map.custom ? "Custom" : "Default", map.meta.width, map.meta.height);
if(!world.maps.all().isEmpty()){
info("Maps:");
for(Map map : world.maps.all()){
info(" &ly{0}: &lb&fi{1} / {2}x{3}", map.name, map.custom ? "Custom" : "Default", map.meta.width, map.meta.height);
}
}else{
info("No maps found.");
}
info("&lyMap directory: &lb&fi{0}", customMapDirectory.file().getAbsoluteFile().toString());
});
handler.register("status", "Display server status.", arg -> {