"Literally shat myself" can mean three things:
— semi-literal: I lost control of my bowels because I was laughing so hard.
— super-literal: I expelled myself from my own anus because I was laughing so hard.
— not literal at all: I didn't really shit my pants, but I sure was laughing hard.