Added id_glass

This commit is contained in:
CobaltXII
2018-12-31 17:56:53 -05:00
parent b6eefb8c93
commit 7ba158ad0f
5 changed files with 19 additions and 3 deletions

View File

@@ -91,6 +91,8 @@ enum block_id
id_black_wool,
id_glass,
id_null
};
@@ -108,6 +110,8 @@ inline bool is_transparent(block_id id)
id == id_water ||
id == id_glass ||
id == id_null
)
{
@@ -205,7 +209,9 @@ std::vector<std::string> block_id_to_string =
"red_wool",
"black_wool"
"black_wool",
"glass",
};
// Conversion from block_id to std::string (used for in-game text).
@@ -296,5 +302,7 @@ std::vector<std::string> block_id_to_block_name =
"Red Wool",
"Black Wool"
"Black Wool",
"Glass"
};

View File

@@ -152,6 +152,8 @@ void load_block_face_info_array()
make_face_info_all(block_name_to_layer.at("wool_colored_red")),
make_face_info_all(block_name_to_layer.at("wool_colored_black"))
make_face_info_all(block_name_to_layer.at("wool_colored_black")),
make_face_info_all(block_name_to_layer.at("glass"))
};
}

View File

@@ -29,6 +29,8 @@ std::vector<std::string> all_tex =
"emerald_ore",
"glass",
"gold_ore",
"grass_side",

View File

@@ -8,6 +8,10 @@ inline bool hide_face(block_id face, block_id neighbor)
{
hide = false;
}
else if (face == id_glass && neighbor == id_glass)
{
hide = false;
}
return hide;
}

BIN
tex/glass.png Executable file

Binary file not shown.

After

Width:  |  Height:  |  Size: 184 B