Description

When editing the module the call to FHlslNiagaraTranslator::HandleDataInterfaceCall has the usage "Module", so it treads the module as if that was its stack context, even though the module's usage bitmask does not allow for that, so an error is produced that is confusing to the user.

Steps to Reproduce
  1. Create a new Niagara module asset
  2. Change the module's usage bitmask to Emitter Spawn Script (uncheck all default usages)
  3. Add an Emitter Properties DI
  4. Call Set Fixed Bounds on the DI
  5. Wire the exec pins up to the rest of the graph
  6. Save & Compile

RESULT

There will be a compiler error with this message:

Function call "SetFixedBounds" is not allowed for stack context ENiagaraScriptUsage::Module. Allowed: ENiagaraScriptUsage::EmitterSpawnScript, ENiagaraScriptUsage::EmitterUpdateScript, ENiagaraScriptUsage::SystemSpawnScript, ENiagaraScriptUsage::SystemUpdateScript - 

Have Comments or More Details?

There's no existing public thread on this issue, so head over to Questions & Answers just mention UE-177080 in the post.

0
Login to Vote

Fixed
ComponentUE - Niagara
Affects Versions5.1
Target Fix5.2
Fix Commit24132772
CreatedFeb 14, 2023
ResolvedFeb 15, 2023
UpdatedFeb 24, 2023