Render roads directly as part of the tile texture in shaders/simple.frag
This commit is contained in:
+16
-4
@@ -17,7 +17,10 @@ RoadConfigManager::RoadConfigManager()
|
||||
dirt.colorStr = "#c49a62";
|
||||
dirt.borderColorStr = "#6b4b23";
|
||||
dirt.width = 3.5f;
|
||||
dirt.worldWidth = 0.11f;
|
||||
dirt.worldWidth = 0.068f;
|
||||
dirt.borderWidth = 0.022f;
|
||||
dirt.textureScale = 2.4f;
|
||||
dirt.opacity = 0.90f;
|
||||
dirt.cost = 5;
|
||||
m_types["dirt"] = dirt;
|
||||
|
||||
@@ -28,7 +31,10 @@ RoadConfigManager::RoadConfigManager()
|
||||
stone.colorStr = "#9aa1a8";
|
||||
stone.borderColorStr = "#464b50";
|
||||
stone.width = 4.0f;
|
||||
stone.worldWidth = 0.13f;
|
||||
stone.worldWidth = 0.078f;
|
||||
stone.borderWidth = 0.020f;
|
||||
stone.textureScale = 2.8f;
|
||||
stone.opacity = 0.94f;
|
||||
stone.cost = 15;
|
||||
m_types["stone"] = stone;
|
||||
|
||||
@@ -39,7 +45,10 @@ RoadConfigManager::RoadConfigManager()
|
||||
rail.colorStr = "#3a3c40";
|
||||
rail.borderColorStr = "#181a1c";
|
||||
rail.width = 4.5f;
|
||||
rail.worldWidth = 0.15f;
|
||||
rail.worldWidth = 0.086f;
|
||||
rail.borderWidth = 0.024f;
|
||||
rail.textureScale = 3.0f;
|
||||
rail.opacity = 0.96f;
|
||||
rail.cost = 30;
|
||||
m_types["rail"] = rail;
|
||||
}
|
||||
@@ -75,7 +84,10 @@ bool RoadConfigManager::loadConfigFile(const QString &filePath)
|
||||
rCfg.colorStr = it.value().hasChild("color") ? it.value()["color"].asString("#c49a62") : "#c49a62";
|
||||
rCfg.borderColorStr = it.value().hasChild("border_color") ? it.value()["border_color"].asString("#6b4b23") : "#6b4b23";
|
||||
rCfg.width = it.value().hasChild("width") ? it.value()["width"].asFloat(3.5f) : 3.5f;
|
||||
rCfg.worldWidth = it.value().hasChild("world_width") ? it.value()["world_width"].asFloat(0.11f) : 0.11f;
|
||||
rCfg.worldWidth = it.value().hasChild("world_width") ? it.value()["world_width"].asFloat(0.068f) : 0.068f;
|
||||
rCfg.borderWidth = it.value().hasChild("border_width") ? it.value()["border_width"].asFloat(0.022f) : 0.022f;
|
||||
rCfg.textureScale = it.value().hasChild("texture_scale") ? it.value()["texture_scale"].asFloat(2.4f) : 2.4f;
|
||||
rCfg.opacity = it.value().hasChild("opacity") ? it.value()["opacity"].asFloat(0.90f) : 0.90f;
|
||||
rCfg.cost = it.value().hasChild("cost") ? it.value()["cost"].asInt(5) : 5;
|
||||
m_types[rCfg.id] = rCfg;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user