How does the inability to produce vitamin C helped weight gain?
The effect comes indirectly since lower levels of ascorbate increases urate levels, according to 


  Arthritis Rheum. 2005 Jun;52(6):1843-7.
  
  The effects of vitamin C supplementation on serum concentrations of
  uric acid: results of a randomized controlled trial. 
  
  Huang HY1, Appel
  LJ, Choi MJ, Gelber AC, Charleston J, Norkus EP, Miller ER 3rd.


So the direct weight gain effect is due to increased levels of uric acid. 

Further in the chain of events is that 


  Recent studies show that fructose-induced uric acid generation causes
  mitochondrial oxidative stress that stimulates fat accumulation
  independent of excessive caloric intake.


according to 


  Diabetes 2013 Oct; 62(10): 3307-3315.
  
  Sugar, Uric Acid, and the Etiology of Diabetes and Obesity
  
  Richard J. Johnson1,2⇑, Takahiko Nakagawa1,3, L. Gabriela Sanchez-Lozada4, Mohamed Shafiu5, Shikha Sundaram6, Myphuong Le1, Takuji Ishimoto1, Yuri Y. Sautin7 and Miguel A. Lanaspa1