Task planning and explanation with virtual actions