Well, if you can't escape it then just fight it, you can drink 2 bottles of beer to gain maximum damage outputs and use Halberd for dealing with goblins, Bandits will be a little harder, you can learn the "Backstab" technique using the dagger weapon in the game to one shot them one by one.