More work on DC grid
This commit is contained in:
parent
bf182141da
commit
c52bca4a12
|
@ -82,7 +82,7 @@ class TileBattery extends SpatialTile(Material.iron) with TIO with TElectric wit
|
||||||
//TODO: Voltage of battery should decrease over time.
|
//TODO: Voltage of battery should decrease over time.
|
||||||
//TODO: Test, remove this
|
//TODO: Test, remove this
|
||||||
if (doCharge)
|
if (doCharge)
|
||||||
dcNode.setVoltage(500)
|
dcNode.generateVoltage(500)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -39,7 +39,7 @@ class TileSolarPanel extends TileElectric(Material.iron) with TIO with RenderCon
|
||||||
return SpatialBlock.icon.get("solarPanel_side")
|
return SpatialBlock.icon.get("solarPanel_side")
|
||||||
}
|
}
|
||||||
|
|
||||||
override def update
|
override def update()
|
||||||
{
|
{
|
||||||
super.update()
|
super.update()
|
||||||
|
|
||||||
|
@ -51,8 +51,7 @@ class TileSolarPanel extends TileElectric(Material.iron) with TIO with RenderCon
|
||||||
{
|
{
|
||||||
if (!(world.isThundering || world.isRaining))
|
if (!(world.isThundering || world.isRaining))
|
||||||
{
|
{
|
||||||
println(dcNode)
|
dcNode.generateVoltage(Settings.solarPower / 20)
|
||||||
dcNode.setVoltage(Settings.solarPower / 20)
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue