diff --git a/tpl/bhl_bind_macro.twig b/tpl/bhl_bind_macro.twig index 4b1eb4d..2e8e392 100644 --- a/tpl/bhl_bind_macro.twig +++ b/tpl/bhl_bind_macro.twig @@ -638,6 +638,13 @@ Script_{{o.name|norm_name}}.Method_{{m.name}}.ReturnValue(frm, stack {% endif ~%} #if !BHL_FRONT , native_type: typeof({{token_or(o, 'bhl_native_class', o.name)}}) + {% if has_token(o, 'bhl_custom_rw') %} + , native_object_getter: (v) => { + var tmp = new {{token_or(o, 'bhl_native_class', o.name)}}(); + v.Decode(ref tmp); + return tmp; + } + {% endif %} #endif ); {{scope}}.{{o.name|ns_prefix}}Define(cl);