I am trying to create a framework for option backtesting for the community to use.

I have everything ready to go but there is one major problem:

I can't make my own custom class a tradeable asset!

So what I want to do is on every OnData(TradeBars data) event of the underlying stock, I will create a new option instance. I will then calculate the theoretical price of this option and populate all its other fields. After this, it should then become a tradable asset such that we can call Order() on it. I've tried creating my own custom data with AddData<.Option.>("AAPL.CALL", Resolution.Hourly); (the dots are to escape the brackets for this post) but this class only reads data before starting the backtest. I need to be able to add data to this asset on the fly.

However, this isn't possible! And if I can't do that, we can't backtest actually buying and selling the option.

Can anyone help me out with this? If we can solve this I can have the option backtesting framework ready within the week.
Thanks in advance :)