From f86576293e0db99a38ed104a078679a2192f6948 Mon Sep 17 00:00:00 2001 From: Pavel Shevaev Date: Tue, 20 May 2025 14:51:16 +0300 Subject: [PATCH] Fixing factory codegen --- tpl/codegen_factory.twig | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/tpl/codegen_factory.twig b/tpl/codegen_factory.twig index 608bbf5..935b0dc 100644 --- a/tpl/codegen_factory.twig +++ b/tpl/codegen_factory.twig @@ -33,10 +33,8 @@ static public class AutogenBundle { switch(class_id) { -{%- for u in meta.getunits ~%} -{%- if u.object is instanceof('\\mtgMetaStruct')~%} - case {{u.object.classid}}: { return typeof({{u.object.name}}); } -{%- endif ~%} +{%- for t in meta.factorytypes ~%} + case {{t.classid}}: { return typeof({{t.fullname}}); } {%- endfor ~%} default: {