wraped code in an multi-platform exporter
this is the fastest version AND it is pretty OOP