Make sure Multiplayer AutoComponents dont generate property OnChange script events if GenerateEventBindings is disabled
Signed-off-by: Gene Walters <genewalt@amazon.com>
This commit is contained in:
@@ -909,6 +909,7 @@ enum class NetworkProperties
|
|||||||
controller->Set{{ UpperFirst(Property.attrib['Name']) }}({{ LowerFirst(Property.attrib['Name']) }});
|
controller->Set{{ UpperFirst(Property.attrib['Name']) }}({{ LowerFirst(Property.attrib['Name']) }});
|
||||||
{% endif %}
|
{% endif %}
|
||||||
})
|
})
|
||||||
|
{% if Property.attrib['GenerateEventBindings']|booleanTrue %}
|
||||||
{% if Property.attrib['Container'] == 'Vector' or Property.attrib['Container'] == 'Array' -%}
|
{% if Property.attrib['Container'] == 'Vector' or Property.attrib['Container'] == 'Array' -%}
|
||||||
->Method("GetOn{{ UpperFirst(Property.attrib['Name']) }}ChangedEvent", [](AZ::EntityId id) -> AZ::Event<int32_t, {{ Property.attrib['Type'] }}>*
|
->Method("GetOn{{ UpperFirst(Property.attrib['Name']) }}ChangedEvent", [](AZ::EntityId id) -> AZ::Event<int32_t, {{ Property.attrib['Type'] }}>*
|
||||||
{% else %}
|
{% else %}
|
||||||
@@ -936,6 +937,7 @@ enum class NetworkProperties
|
|||||||
{% else %}
|
{% else %}
|
||||||
->Attribute(AZ::Script::Attributes::AzEventDescription, AZ::BehaviorAzEventDescription{ "On {{ UpperFirst(Property.attrib['Name']) }} Changed Event", {"New {{ Property.attrib['Type'] }}"} })
|
->Attribute(AZ::Script::Attributes::AzEventDescription, AZ::BehaviorAzEventDescription{ "On {{ UpperFirst(Property.attrib['Name']) }} Changed Event", {"New {{ Property.attrib['Type'] }}"} })
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% endcall %}
|
{% endcall %}
|
||||||
|
|||||||
Reference in New Issue
Block a user