summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--assets/deco/nest_0.pngbin0 -> 8612 bytes
-rw-r--r--assets/deco/nest_1.pngbin0 -> 10112 bytes
-rw-r--r--assets/deco/nest_2.pngbin0 -> 11419 bytes
-rw-r--r--assets/deco/nest_3.pngbin0 -> 11290 bytes
-rw-r--r--assets/deco/nest_4.pngbin0 -> 9742 bytes
-rw-r--r--src/game/assets.cpp1
-rw-r--r--src/game/decos.cpp5
-rw-r--r--src/game/game.hpp5
-rw-r--r--src/game/worldgen.cpp4
9 files changed, 12 insertions, 3 deletions
diff --git a/assets/deco/nest_0.png b/assets/deco/nest_0.png
new file mode 100644
index 0000000..65233e2
--- /dev/null
+++ b/assets/deco/nest_0.png
Binary files differ
diff --git a/assets/deco/nest_1.png b/assets/deco/nest_1.png
new file mode 100644
index 0000000..a9dd177
--- /dev/null
+++ b/assets/deco/nest_1.png
Binary files differ
diff --git a/assets/deco/nest_2.png b/assets/deco/nest_2.png
new file mode 100644
index 0000000..16ed9cb
--- /dev/null
+++ b/assets/deco/nest_2.png
Binary files differ
diff --git a/assets/deco/nest_3.png b/assets/deco/nest_3.png
new file mode 100644
index 0000000..93cc6b4
--- /dev/null
+++ b/assets/deco/nest_3.png
Binary files differ
diff --git a/assets/deco/nest_4.png b/assets/deco/nest_4.png
new file mode 100644
index 0000000..4336b53
--- /dev/null
+++ b/assets/deco/nest_4.png
Binary files differ
diff --git a/src/game/assets.cpp b/src/game/assets.cpp
index a908962..e5fee38 100644
--- a/src/game/assets.cpp
+++ b/src/game/assets.cpp
@@ -25,6 +25,7 @@ void load(void)
deco.stone.load("assets/deco/stone_", 1);
deco.eyething.load("assets/deco/eyething_", 2);
+ deco.nest.load("assets/deco/nest_", 5);
world::register_tile(TILE_DIRT, 0);
render::register_tile(TILE_DIRT, "assets/tiles/dirt.png");
diff --git a/src/game/decos.cpp b/src/game/decos.cpp
index 63780fa..ae103ef 100644
--- a/src/game/decos.cpp
+++ b/src/game/decos.cpp
@@ -23,6 +23,11 @@ static const struct {
&assets::deco.eyething,
{-0.4f, +0.1f}, {+0.4f, +0.4f}, CF_SOLID,
{-0.4f, -1.2f}, {+0.4f, +0.4f}, 0.3
+ },
+ {
+ &assets::deco.nest,
+ {-0.6f, +0.2f}, {+0.6f, +0.6f}, CF_SOLID,
+ {-0.6f, -0.6f}, {+0.6f, +0.6f}, 1.0
}
};
diff --git a/src/game/game.hpp b/src/game/game.hpp
index e1eca84..4cc1077 100644
--- a/src/game/game.hpp
+++ b/src/game/game.hpp
@@ -44,7 +44,7 @@ namespace game {
} fx_assets_t;
typedef struct {
- render::animated_texture_t stone, eyething;
+ render::animated_texture_t stone, eyething, nest;
} deco_assets_t;
extern human_assets_t human;
@@ -185,7 +185,8 @@ namespace game {
typedef enum {
DECO_STONE,
DECO_STONE_SMALL,
- DECO_EYETHING
+ DECO_EYETHING,
+ DECO_NEST
} deco_type_t;
class deco_t : public world::entity_t {
diff --git a/src/game/worldgen.cpp b/src/game/worldgen.cpp
index 74a07c7..01b05ca 100644
--- a/src/game/worldgen.cpp
+++ b/src/game/worldgen.cpp
@@ -12,7 +12,9 @@ void add_decoration(world_t *world, state_t *game, v2f_t x, float noise)
if (noise < 0.3)
return;
- if (noise > 0.45)
+ if (noise > 0.5)
+ type = DECO_NEST;
+ else if (noise > 0.40)
type = DECO_EYETHING;
else if (noise > 0.35)
type = DECO_STONE;