Updating multiplayer auto-components to require the LocalPredictionPlayerInputComponent service if they use NetworkInputs. Without LocalPredictionPlayerInputComponent CreateInput and ProcessInput will never be called
Signed-off-by: Gene Walters <genewalt@amazon.com>
This commit is contained in:
@@ -1465,6 +1465,11 @@ namespace {{ Component.attrib['Namespace'] }}
|
||||
{% call(ComponentService) ParseComponentServiceNames(Component, ClassType, 'Required') %}
|
||||
required.push_back(AZ_CRC_CE("{{ ComponentService }}"));
|
||||
{% endcall %}
|
||||
|
||||
{% if NetworkInputCount > 0 %}
|
||||
// This component uses NetworkInputs so it requires LocalPredictionPlayerInputComponent which is responsible for calling CreateInput and ProcessInput
|
||||
required.push_back(AZ_CRC_CE("LocalPredictionPlayerInputComponent"));
|
||||
{% endif %}
|
||||
}
|
||||
|
||||
void {{ ComponentBaseName }}::GetDependentServices([[maybe_unused]] AZ::ComponentDescriptor::DependencyArrayType& dependent)
|
||||
|
||||
Reference in New Issue
Block a user