mostly working splicing now messing with critical variables