aboutsummaryrefslogtreecommitdiff
path: root/game/src/Game/GameSession/MapView.gd
diff options
context:
space:
mode:
author hop311 <hop3114@gmail.com>2023-11-16 00:54:57 +0100
committer hop311 <hop3114@gmail.com>2023-11-16 00:54:57 +0100
commit3490e740a7235dce236fc2ce973e5cbf64d6e727 (patch)
tree283c52e391c09ca8c4fb7ab6d81f4351c0fa7025 /game/src/Game/GameSession/MapView.gd
parentbc0b3c61ae0b742da304cada451fba1df72bb0ad (diff)
Striped mapmodes
Diffstat (limited to 'game/src/Game/GameSession/MapView.gd')
-rw-r--r--game/src/Game/GameSession/MapView.gd5
1 files changed, 4 insertions, 1 deletions
diff --git a/game/src/Game/GameSession/MapView.gd b/game/src/Game/GameSession/MapView.gd
index 345ab9e..7093c69 100644
--- a/game/src/Game/GameSession/MapView.gd
+++ b/game/src/Game/GameSession/MapView.gd
@@ -74,7 +74,10 @@ func _ready():
# Set map mesh size and get bounds
const pixels_per_terrain_tile : float = 32.0
_map_shader_material.set_shader_parameter(GameLoader.ShaderManager.param_terrain_tile_factor,
- float(GameSingleton.get_height()) / pixels_per_terrain_tile)
+ float(GameSingleton.get_map_height()) / pixels_per_terrain_tile)
+ const pixels_per_stripe_tile : float = 16.0
+ _map_shader_material.set_shader_parameter(GameLoader.ShaderManager.param_stripe_tile_factor,
+ float(GameSingleton.get_map_height()) / pixels_per_stripe_tile)
var map_mesh_aabb := _map_mesh.get_core_aabb() * _map_mesh_instance.transform
_map_mesh_corner = Vector2(
min(map_mesh_aabb.position.x, map_mesh_aabb.end.x),