Raise walls: plan them on own floor, imps build reinforced earth
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
398bb95681
commit
ed3bc437e5
26 files changed
+347
-11
No files matched your search
@@ -175,13 +175,14 @@ pub enum Tool {
|
||||
Bridge,
|
||||
Steel,
|
||||
Drawbridge,
|
||||
Wall,
|
||||
Trap(crate::traps::TrapKind),
|
||||
Spell(crate::spells::Spell),
|
||||
Order(u8), // 0 attack, 1 guard
|
||||
}
|
||||
|
||||
// New tools are appended so that existing key bindings ("tool<i>") keep their meaning
|
||||
pub const TOOLS: [Tool; 49] = [
|
||||
pub const TOOLS: [Tool; 50] = [
|
||||
Tool::Dig,
|
||||
Tool::Hand,
|
||||
Tool::Room(0),
|
||||
@@ -231,6 +232,7 @@ pub const TOOLS: [Tool; 49] = [
|
||||
Tool::Order(1),
|
||||
Tool::Drawbridge,
|
||||
Tool::Spell(crate::spells::Spell::Freeze),
|
||||
Tool::Wall,
|
||||
];
|
||||
|
||||
|
||||
@@ -274,6 +276,7 @@ pub fn tool_info(t: Tool) -> ToolInfo {
|
||||
Tool::Summon => ("summon", I_SUMMON, None),
|
||||
Tool::Bridge => ("bridge", I_BRIDGE, None),
|
||||
Tool::Drawbridge => ("drawbridge", I_DRAWBRIDGE, None),
|
||||
Tool::Wall => ("wall", I_WALL, None),
|
||||
Tool::Steel => ("steel", I_STEEL, None),
|
||||
};
|
||||
let name = match room {
|
||||
@@ -289,6 +292,7 @@ pub fn tool_cost_static(t: Tool) -> String {
|
||||
Tool::Spell(sp) => trf("cost.mana", &[(sp.cost() as i32).to_string()]),
|
||||
Tool::Trap(k) => trf("cost.work", &[(k.work() as i32).to_string()]),
|
||||
Tool::Bridge => trf("cost.bridge", &[BRIDGE_COST[0].to_string(), (crate::wood::BRIDGE_WOOD as i32).to_string(), BRIDGE_COST[1].to_string()]),
|
||||
Tool::Wall => trf("cost.gold_tile", &[(crate::walls::WALL_COST as i32).to_string()]),
|
||||
Tool::Drawbridge => trf("cost.drawbridge", &[DRAWBRIDGE_COST[0].to_string(), (crate::wood::DRAWBRIDGE_WOOD as i32).to_string(), DRAWBRIDGE_COST[1].to_string()]),
|
||||
Tool::Steel => trf("cost.steel", &[STEEL_COST[0].to_string(), STEEL_COST[1].to_string()]),
|
||||
Tool::Tower(TowerKind::Rune) => {
|
||||
@@ -315,6 +319,7 @@ pub fn tool_cost(t: Tool, g: &Game) -> String {
|
||||
Tool::Heal => trf("cost.mana", &["60".into()]),
|
||||
Tool::Summon => trf("cost.mana", &[(g.summon_cost() as i32).to_string()]),
|
||||
Tool::Bridge => trf("cost.bridge", &[BRIDGE_COST[0].to_string(), (crate::wood::BRIDGE_WOOD as i32).to_string(), BRIDGE_COST[1].to_string()]),
|
||||
Tool::Wall => trf("cost.gold_tile", &[(crate::walls::WALL_COST as i32).to_string()]),
|
||||
Tool::Drawbridge => trf("cost.drawbridge", &[DRAWBRIDGE_COST[0].to_string(), (crate::wood::DRAWBRIDGE_WOOD as i32).to_string(), DRAWBRIDGE_COST[1].to_string()]),
|
||||
Tool::Steel => trf("cost.steel", &[STEEL_COST[0].to_string(), STEEL_COST[1].to_string()]),
|
||||
Tool::Tower(TowerKind::Rune) => {
|
||||
@@ -337,7 +342,7 @@ pub fn tool_cost(t: Tool, g: &Game) -> String {
|
||||
pub const CATS: [(&str, &[usize]); 7] = [
|
||||
("cat.dig", &[0]),
|
||||
("cat.hand", &[1]),
|
||||
("cat.rooms", &[2, 3, 4, 5, 6, 12, 40, 13, 18, 21, 41, 42, 43, 44, 17, 47]),
|
||||
("cat.rooms", &[2, 3, 4, 5, 6, 12, 40, 13, 18, 21, 41, 42, 43, 44, 17, 47, 49]),
|
||||
("cat.towers", &[14, 15, 16, 20]),
|
||||
("cat.traps", &[22, 23, 24, 25, 26, 27, 28, 29, 30, 31]),
|
||||
("cat.spells", &[9, 10, 11, 32, 33, 34, 35, 36, 37, 38, 39, 48]),
|
||||
|
||||
Reference in new issue
Block a user