Rewrite C&C shellmap in lua