12
« on: November 22, 2009, 10:55:58 pm »
I was just thinking about a way to improve control over mechanical devices, and give a much-needed nerfing to early defense strategies that make it easier to make an impregnable fortress than it is to train a basic military.
Basically, the idea goes something like this -
Make it so there are two kinds of power. Let's call them "clockwise" and "counterclockwise." One is just the opposite of the other, and all connected components of a network of gears and axels are powered with the net difference - so if you hook up a 50 counterclockwise source and a 30 clockwise source, you end up with 20 counterclockwise force, so it's generally best to avoid doing this.
Power sources, when created, are set to provide either clockwise or counterclockwise power. Add a new gear type which reverses the power type when toggled via a lever.
Buildings which currently just magically work (like drawbridges, gates, floodgates, etc) can no longer be operated just with a lever. Instead, if clockwise power is hooked up to them, they do one thing, and the opposite if the other direction of power is hooked up to it. Bridges, in particular, require power in proportion to how large they are to function, and what they're made out of.
Weapon traps now require power. A trap has to be "wound up" to function (or could be done manually, like resetting a cage or stonefall trap), by being provided power in a given direction. However, while recieving power in this direction, they can't fire. If receiving power in the opposite direction, they just keep going off continually, harming anything in their square.
Add new manual power sources - treadmills, winches, etc. So that powered systems are easier to set up. (These can be toggled on the fly.) Would also make it easier to set up basic defenses - so you *can* set up a drawbridge, but the easiest solution is to have it connected by a winch which may take a couple dwarves to operate, and more if you've made it really big and made it out of stone.
Mechanical systems are in general controlled by turning power on and off by toggling gears or starting or stopping the manual power generation. For example, a basic drawbridge setup would mean the drawbridge, a nearby winch, and some means of transmitting the power from the winch to the drawbridge - the way the drawbridge is raised is by assigning dwarves to work the winch.
I'd also suggest adding more uses for power - in particular, other kinds of mills. Medieval europe had a lot more kinds of mills than just flour mills - there were "hammer mills" with mechanical hammers driven by water for more efficient smithing, "fulling mills" that made the finishing of wollen cloth faster, furnaces driven by bellows which were run by water, etc. Most kinds of workshops could be made more efficient by powering them.
As a more advanced feature, there's potential here for things like counterweights and the like for "storing" power - set up a counterweight that, when released via lever, provides power for a short amount of time, for instance. That way with a little more setup, you could make a drawbridge that can be raised by a single dwarf operating the counterweight, but just takes a lot more work to lower again.
The end result should be that automated defenses should take a lot more setup and forethought to implement - a solution for a mature fortress, and not an easy defense for small camps - while adding more options like rigging "blenders" out of weapon traps that go off as long as they're powered, and other "prone-to-fail," absurdly complex mechanical schemes.
Biggest problem I can see is the calculation of how power is transmitted.- particularly in circumstances like having power reversed and put into an endless loop, or something, and it starts to look suspiciously like a flow. (You'd probably have to calculate it like a flow, but the advantage is that it wouldn't have to be updated unless something changes in the system.) I think the easiest solution is when things go strange, just have mechanical components fail, break, etc, if something goes wrong with calculating power.
And on a tangent, it'd also be nice to have pumps which can be set to pressurize water (for increased power consumption/exhaustion). Just make it so that when the pump tries to put water into its output square, let it search for empty squares up to its own Z level + a setable pressurization value (Though only if it can't flow down first, of course). This way we could pump water into pressurized systems to raise its level rather than having to build huge stacks of pumps - this would have both the upside of saving us setup work (the most efficient ways of which really show off how dumb dwarves are when you're trying to channel and they keep insisting on doing it from the wrong side) while adding the *spectacularly* dangerous possibility of runaway pressurized magma! Nothing's surer to cause "fun" than a system of tubes to carry pressurized magma throughout a fort.