Simulating simple SMPS model
Unless you allow enough time for the transformer to reverse its flux, using one of many methods,  the average DC current will saturate it and the core inductance drops like a rock and gets hot.  Try a Centre tapped Vdc with bipolar switches.  Other ways using tertiary winding to cancel the flux on the primary.