The following job will throw an entityQuery duplicate component error
public partial struct DisabledEnableableBug : ISystem
{
public void OnUpdate(ref SystemState state)
{
new BugJob().ScheduleParallel();
}
}
[WithDisabled(typeof(Revivable))]
public partial struct BugJob : IJobEntity
{
public void Execute(
ref Revivable revivable,
EnabledRefRW<Revivable> revivableBit
)
{
revivable.StartTick = 0;
revivableBit.ValueRW = true;
}
}
public struct Revivable : IComponentData, IEnableableComponent
{
public int StartTick;
};