I just recently started watching Gintama and am beginning to love it! I just want to know if the joke is referring to another anime. Also, if there is any reason at all on why it must be a vending machine.
I believe this is the first time he did it.
The reason this particular joke catches my interest is because it kept on reoccurring. The second reason is because time travelling anime like Steins;Gate is awesome. Even though it might not be the same.
I just had to ask this question after the third time they used this joke on the 10th episode, though it was not Gintoki and the alien character wants to enter a car's boot/trunk.