By the way, let me explain the historical background: There are various theories on when and where "Black Powder" was invented, but the prevailing theory is that it was invented in China in the 6th to 9th centuries.
In those days, alchemists carried out research on elixirs of eternal youth, as one of the things produced in the process, the formula for gunpowder was recorded in the『Zhengzhou miaodao yaolüe』which was written around the year 850.
Around the middle of the 13th century, their successors developed weapons called『Fire Lances』, consisting of a short pipe packed with gunpowder affixed to the tip of a piece of wood or bamboo. (These weapons do not shoot bullets, instead they were simple flamethrowers or flash weapons).
These were the origins of gun-type firearms.