mirror of
https://github.com/curioustorvald/Terrarum.git
synced 2026-03-07 12:21:52 +09:00
no quartz on igneous rocks
This commit is contained in:
@@ -7,12 +7,12 @@
|
||||
"17";"16";"16";"BLOCK_STONE_QUARRIED";"0.1252";"0.1252";"0.1252";"0.1252";"48";"2400";"ROCK";"1";"1";"N/A";"0";"4";"16";"0.0000";"0.0000";"0.0000";"0.0000";"0.0";"ROCK,NATURAL,OREBEARING"
|
||||
"18";"18";"18";"BLOCK_STONE_TILE_WHITE";"0.1252";"0.1252";"0.1252";"0.1252";"48";"2400";"ROCK";"1";"1";"N/A";"0";"4";"16";"0.0000";"0.0000";"0.0000";"0.0000";"0.18";"STONE"
|
||||
"19";"19";"19";"BLOCK_STONE_BRICKS";"0.1252";"0.1252";"0.1252";"0.1252";"48";"2400";"ROCK";"1";"1";"N/A";"0";"4";"16";"0.0000";"0.0000";"0.0000";"0.0000";"0.0";"STONE"
|
||||
"20";"20";"20";"BLOCK_STONE_GABBRO";"0.1252";"0.1252";"0.1252";"0.1252";"80";"2400";"ROCK";"1";"1";"N/A";"0";"4";"16";"0.0000";"0.0000";"0.0000";"0.0000";"0.0";"ROCK,NATURAL,DEEPROCK,OREBEARING,OLDNAME¤0.4.4¤STONE_DEEP"
|
||||
"20";"20";"20";"BLOCK_STONE_DEEP";"0.1252";"0.1252";"0.1252";"0.1252";"80";"2400";"ROCK";"1";"1";"N/A";"0";"4";"16";"0.0000";"0.0000";"0.0000";"0.0000";"0.0";"ROCK,NATURAL,DEEPROCK,OREBEARING"
|
||||
"21";"21";"21";"BLOCK_STONE_MARBLE";"0.1252";"0.1252";"0.1252";"0.1252";"48";"2400";"ROCK";"1";"1";"N/A";"0";"4";"16";"0.0000";"0.0000";"0.0000";"0.0000";"0.1";"ROCK,NATURAL,FLUXSTONE"
|
||||
"22";"22";"22";"BLOCK_STONE_ORTHOCLASE";"0.1252";"0.1252";"0.1252";"0.1252";"48";"2400";"ROCK";"1";"1";"N/A";"0";"4";"16";"0.0000";"0.0000";"0.0000";"0.0000";"0.0";"ROCK,NATURAL,OREBEARING"
|
||||
"23";"23";"23";"BLOCK_STONE_PLAGIOCLASE";"0.1252";"0.1252";"0.1252";"0.1252";"48";"2400";"ROCK";"1";"1";"N/A";"0";"4";"16";"0.0000";"0.0000";"0.0000";"0.0000";"0.0";"ROCK,NATURAL,OREBEARING"
|
||||
"24";"24";"24";"BLOCK_STONE_MICROCLINE";"0.1252";"0.1252";"0.1252";"0.1252";"48";"2400";"ROCK";"1";"1";"N/A";"0";"4";"16";"0.0000";"0.0000";"0.0000";"0.0000";"0.0";"ROCK,NATURAL,OREBEARING"
|
||||
"25";"25";"25";"BLOCK_STONE_BASALT";"0.1252";"0.1252";"0.1252";"0.1252";"48";"2400";"ROCK";"1";"1";"N/A";"0";"4";"16";"0.0000";"0.0000";"0.0000";"0.0000";"0.0";"ROCK,NATURAL,OREBEARING"
|
||||
"22";"22";"22";"BLOCK_STONE";"0.1252";"0.1252";"0.1252";"0.1252";"48";"2400";"ROCK";"1";"1";"N/A";"0";"4";"16";"0.0000";"0.0000";"0.0000";"0.0000";"0.0";"ROCK,NATURAL,OREBEARING"
|
||||
"23";"23";"23";"BLOCK_STONE";"0.1252";"0.1252";"0.1252";"0.1252";"48";"2400";"ROCK";"1";"1";"N/A";"0";"4";"16";"0.0000";"0.0000";"0.0000";"0.0000";"0.0";"ROCK,NATURAL,OREBEARING"
|
||||
"24";"24";"24";"BLOCK_STONE";"0.1252";"0.1252";"0.1252";"0.1252";"48";"2400";"ROCK";"1";"1";"N/A";"0";"4";"16";"0.0000";"0.0000";"0.0000";"0.0000";"0.0";"ROCK,NATURAL,OREBEARING"
|
||||
"25";"25";"25";"BLOCK_STONE_BASALT";"0.1252";"0.1252";"0.1252";"0.1252";"48";"2400";"ROCK";"1";"1";"N/A";"0";"4";"16";"0.0000";"0.0000";"0.0000";"0.0000";"0.0";"ROCK,NATURAL,OREBEARING,BASALT"
|
||||
"26";"26";"26";"BLOCK_STONE_SLATE";"0.1252";"0.1252";"0.1252";"0.1252";"48";"2400";"ROCK";"1";"1";"N/A";"0";"4";"16";"0.0000";"0.0000";"0.0000";"0.0000";"0.0";"ROCK,NATURAL,OREBEARING"
|
||||
"27";"27";"27";"BLOCK_STONE_LIMESTONE";"0.1252";"0.1252";"0.1252";"0.1252";"48";"2400";"ROCK";"1";"1";"N/A";"0";"4";"16";"0.0000";"0.0000";"0.0000";"0.0000";"0.0";"ROCK,NATURAL,OREBEARING,FLUXSTONE"
|
||||
|
||||
|
||||
|
@@ -5,11 +5,16 @@
|
||||
"BLOCK_AIR": "Air",
|
||||
|
||||
"BLOCK_STONE": "Stone",
|
||||
"BLOCK_STONE_QUARRIED": "Quarried Stone",
|
||||
"BLOCK_STONE_TILE_WHITE": "Stone Tile",
|
||||
"BLOCK_STONE_BASALT": "Basalt",
|
||||
"BLOCK_STONE_BRICKS": "Stone Bricks",
|
||||
"BLOCK_STONE_DEEP": "Deepstone",
|
||||
"BLOCK_STONE_LIMESTONE": "Limestone",
|
||||
"BLOCK_STONE_MARBLE": "Marble",
|
||||
"BLOCK_STONE_QUARRIED": "Quarried Stone",
|
||||
"BLOCK_STONE_SLATE": "Slate",
|
||||
"BLOCK_STONE_TILE_WHITE": "White Stone Tile",
|
||||
"BLOCK_STONE_TILE_BLACK": "Black Stone Tile",
|
||||
|
||||
"BLOCK_BRICKS": "Bricks", /* always plural */
|
||||
|
||||
"BLOCK_DIRT": "Dirt",
|
||||
|
||||
@@ -9,10 +9,10 @@
|
||||
"8";"0.017";"0.020";"0.511";"1.0";"a16x16";"lead (galena)";""
|
||||
"9";"0.008";"0.200";"0.480";"1.0";"a16x16";"uranium (pitchblende)";"FLUXSTONE"
|
||||
|
||||
"256";"0.010";"-0.366";"0.528";"2.4";"a16x8";"rocksalt";"DEEPROCK"
|
||||
"257";"0.007";"0.100";"0.494";"1.0";"a16x8";"amethyst";""
|
||||
"258";"0.019";"0.015";"0.509";"1.0";"a16x8";"quartz";""
|
||||
"259";"0.010";"-0.166";"0.517";"1.4";"a16x8";"nitre";"DEEPROCK"
|
||||
"256";"0.010";"-0.366";"0.528";"2.4";"a16x8";"rocksalt";"DEEPROCK,BASALT"
|
||||
"257";"0.007";"0.100";"0.494";"1.0";"a16x8";"amethyst";"DEEPROCK,BASALT"
|
||||
"258";"0.019";"0.015";"0.509";"1.0";"a16x8";"quartz";"DEEPROCK,BASALT"
|
||||
"259";"0.010";"-0.166";"0.517";"1.4";"a16x8";"nitre";"DEEPROCK,BASALT"
|
||||
|
||||
################################################################################
|
||||
|
||||
|
||||
|
@@ -47,7 +47,7 @@ object WorldSimulator {
|
||||
private val fluidNewTypeMap = Array(DOUBLE_RADIUS) { Array(DOUBLE_RADIUS) { Fluid.NULL } }
|
||||
|
||||
const val FLUID_MAX_MASS = 1f // The normal, un-pressurized mass of a full water cell
|
||||
const val FLUID_MAX_COMP = 0.02f // How much excess water a cell can store, compared to the cell above it. A tile of fluid can contain more than MaxMass water.
|
||||
const val FLUID_MAX_COMP = 0.01f // How much excess water a cell can store, compared to the cell above it. A tile of fluid can contain more than MaxMass water.
|
||||
// const val FLUID_MIN_MASS = net.torvald.terrarum.gameworld.FLUID_MIN_MASS //Ignore cells that are almost dry (smaller than epsilon of float16)
|
||||
const val minFlow = 1f / 512f
|
||||
|
||||
@@ -204,12 +204,17 @@ object WorldSimulator {
|
||||
fluidmapToWorld()
|
||||
}
|
||||
|
||||
fun isSolid(worldX: Int, worldY: Int): Boolean {
|
||||
val tile = world.getTileFromTerrain(worldX, worldY)
|
||||
return BlockCodex[tile].isSolid
|
||||
}
|
||||
|
||||
fun isFlowable(type: ItemID, worldX: Int, worldY: Int): Boolean {
|
||||
val fluid = world.getFluid(worldX, worldY)
|
||||
val tile = world.getTileFromTerrain(worldX, worldY)
|
||||
|
||||
// true if target's type is the same as mine, or it's NULL (air)
|
||||
return ((fluid.type == type || fluid.type == Fluid.NULL) && !BlockCodex[tile].isSolid)
|
||||
return (((fluid.type == type && fluid.amount < FLUID_MAX_MASS + FLUID_MAX_COMP) || fluid.type == Fluid.NULL) && !BlockCodex[tile].isSolid)
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -350,10 +355,7 @@ object WorldSimulator {
|
||||
val maxSpeed = 1f / FluidCodex[remainingType].viscosity.sqr()
|
||||
|
||||
// check solidity
|
||||
if (!isFlowable(remainingType, worldX, worldY)) continue
|
||||
// check if the fluid is a same kind
|
||||
//if (!isFlowable(type, worldX, worldY))) continue
|
||||
|
||||
if (isSolid(worldX, worldY)) continue
|
||||
|
||||
// Custom push-only flow
|
||||
var flow = 0f
|
||||
|
||||
@@ -34,6 +34,7 @@ internal object ExportMap : ConsoleCommand {
|
||||
"ores@basegame:6" to Cvec(0xffcc00ff.toInt()),
|
||||
"ores@basegame:7" to Cvec(0xd5d9f9ff.toInt()),
|
||||
"ores@basegame:8" to Cvec(0xff9300ff.toInt()),
|
||||
"ores@basegame:9" to Cvec(0x88ff00ff.toInt()),
|
||||
"ores@basegame:256" to Cvec(0xff00ffff.toInt()),
|
||||
"ores@basegame:257" to Cvec(0xee77ffff.toInt()),
|
||||
"ores@basegame:258" to Cvec(0xffffffff.toInt()),
|
||||
|
||||
Reference in New Issue
Block a user