RF0202: Signal parameter is not Variant-compatible
DateTime is unsupported as an engine signal parameter.
For a C# project using Reckfell.NET.Sdk 1.0.0. Fix the first build error first: later messages may be a consequence.
Cause
DateTime is unsupported as an engine signal parameter.
Fix
Pass a supported representation, an integer here. For time, separately define its unit and epoch; changing the type does not define them automatically.
Failing example
Save the file in a test C# project and run dotnet build. This version intentionally fails to build.
Example.cs
using Reckfell;
namespace DiagnosticExamples.RF0202;
public partial class Example : Entity { [Signal] public delegate void ChangedEventHandler(System.DateTime value); }Expected messages: RF0202.
Working version
Replace the failing version with these files; do not keep both declarations in the project.
Example.cs
using Reckfell;
namespace DiagnosticExamples.RF0202;
public partial class Example : Entity
{
[Signal] public delegate void ChangedEventHandler(int value);
public void Publish() => EmitSignal(SignalName.Changed, 7);
}Result
Publish() delivers the integer value 7 to the subscriber.
Related material
Reckfell Engine documentationBack to top ↑