summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorquou <quou@disroot.org>2024-07-28 14:31:12 +1000
committerquou <quou@disroot.org>2024-07-28 14:31:12 +1000
commit8313dc2387e35bd69b01a23fbbc12fc0e6946993 (patch)
tree54414faa45f814f7c0d236a460fe7a15b16ffd6a
parent95387c4f2f656b86ec81bd01ea9473b41baea76a (diff)
brick texture
-rw-r--r--Makefile1
-rw-r--r--asset.h5
-rw-r--r--intermediate/brick.bmpbin0 -> 16522 bytes
-rw-r--r--render.c2
4 files changed, 7 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index 050f658..3d2983f 100644
--- a/Makefile
+++ b/Makefile
@@ -33,6 +33,7 @@ mesh_sources = \
texture_sources = \
$(int_dir)/gun.bmp \
+ $(int_dir)/brick.bmp
meshes = $(mesh_sources:$(int_dir)/%.obj=$(data_dir)/%.msh)
textures = $(texture_sources:$(int_dir)/%.bmp=$(data_dir)/%.bc1)
diff --git a/asset.h b/asset.h
index 91bb2fe..a569202 100644
--- a/asset.h
+++ b/asset.h
@@ -26,6 +26,11 @@ struct Mesh;
asset_type_texture, \
"gun.bc1" \
) \
+ x( \
+ asset_id_brick_texture, \
+ asset_type_texture, \
+ "brick.bc1" \
+ ) \
typedef enum {
#define x(id, type, path) id,
diff --git a/intermediate/brick.bmp b/intermediate/brick.bmp
new file mode 100644
index 0000000..fdd25cd
--- /dev/null
+++ b/intermediate/brick.bmp
Binary files differ
diff --git a/render.c b/render.c
index 7c4dd77..f6dc018 100644
--- a/render.c
+++ b/render.c
@@ -727,7 +727,7 @@ void ren_map(
int x, w, h, hh;
const int* data = (const int*)&map[1];
/* temp */
- const Texture* texture = get_texture(asset_id_gun_texture);
+ const Texture* texture = get_texture(asset_id_brick_texture);
w = r->vp[0] << fbits;
h = r->vp[1] << fbits;
hh = h / 2;