From c9776f481c65aad75f39445c5d1d3277f2a7c19d Mon Sep 17 00:00:00 2001 From: jj Date: Sun, 21 Apr 2013 22:29:51 +0200 Subject: [PATCH] ruby: add construction/siegeengine bld subtypes in building_alloc --- plugins/ruby/building.rb | 2 ++ 1 file changed, 2 insertions(+) diff --git a/plugins/ruby/building.rb b/plugins/ruby/building.rb index 37b91d166..5378aaa6e 100644 --- a/plugins/ruby/building.rb +++ b/plugins/ruby/building.rb @@ -48,6 +48,8 @@ module DFHack raise "invalid building type #{type.inspect}" if not cls bld = cls.cpp_new bld.race = ui.race_id + subtype = ConstructionType.int(subtype) if subtype.kind_of?(::Symbol) and type == :Construction + subtype = SiegeengineType.int(subtype) if subtype.kind_of?(::Symbol) and type == :SiegeEngine subtype = WorkshopType.int(subtype) if subtype.kind_of?(::Symbol) and type == :Workshop subtype = FurnaceType.int(subtype) if subtype.kind_of?(::Symbol) and type == :Furnace subtype = CivzoneType.int(subtype) if subtype.kind_of?(::Symbol) and type == :Civzone