fixes for func_sgwi...sed mayhem