DIY ball lightning. How to make lightning in Minecraft? Ionized plasma column

One of my very good friends complains,
that she is throwing lightning bolts and feels electrified.
I dedicate this article to her, because, having made lightning according to my
recipes, you can release steam and remove excess charge.

So, what does it take to (lightning-fast) create lightning?

1. An electrical outlet... into which the cord from your computer is plugged.

2. Any version of Adobe Photoshop is installed on this computer.

3. The desire to master the method of creating lightning in 6 steps.

Photoshop is known as a tool for mocking photographs. However, few people tried to draw from scratch. More precisely, maybe they tried, but didn’t get far, it’s too complicated if you just try to draw in it without good advice.

So, lightning. By the way, in addition to the lightning itself, I will give valuable comments on using Photoshop.

Launch Adobe Photoshop.

1. Ctrl+N - create a new document. Specify dimensions, for example, 400 by 400 pixels.

2. Set the default colors - black and white. There is a D key for this - I recommend remembering it. (Try also X - switches background and art colors back and forth)

3. Fill the drawing with a gradient. Please note that you can access the main tools using the corresponding keys. These keys appear when you hold the mouse over the tool. For example, move the mouse to a brush, a tooltip appears - Brush (B) and other tools. Some letters offer a number of tools; access to them is carried out using Shift+letter. Returning to the gradient fill - this is the letter G, it includes both a simple color fill (in buckets with pouring paint) and a gradient. Press Shift+G until you see the gradient. Filling with a gradient is simple - you just need to click in one place of the picture and move the mouse to another place. There are several options for gradient fill - linear, radial, etc. It’s good to try everything to create different lightning bolts.

4. Apply the filter Filter => Render => Difference Clouds

5. Invert the colors (make a negative), which is achieved by pressing the I key (from inverse)

6. Darken the drawing. A good tool is levels - Ctrl+L, you need to move the levers to make the picture darker (move the central slider to the right). That's it, the black and white lightning is ready. You can color it a little.

7. Ctrl+U - the top slider is hue, the bottom two are saturation and brightness. Play with all the engines, look for your unique solution.

Isn't it true that the drawings you make are amazing? You can send me the most interesting ones, and I will post them here.
Anything else to show from Photoshop? By the way, now you can take any photo of yourself in the night sky and add your own lightning there, it can strike your hand. It doesn't hurt at all.

Laboratory experiments with atmospheric electricity reveal a lot, but mysteries still remain.

It turned out that cold plasma in a rarefied medium in the presence of a rapidly varying electric field has little to do with it.

There has been a ball lightning workshop at the St. Petersburg Institute of Nuclear Physics for several years. Here a small installation was invented and created that reproduces with sufficient accuracy the natural process of the birth of lightning on a damp surface: there is a copper input that plays the role of a lightning rod, a quartz tube with an electrode, and an open surface of tap water.

The role of the thunder cloud is a 600 µF capacitor bank, which can be charged up to 5.5 kV. This is a serious voltage - the slightest carelessness when working with it poses a mortal danger.

It was described in detail in an institute preprint dated March 24, 2004. The water in the polyethylene cup must be grounded; for this, a copper ring electrode is placed at the bottom. It is connected by an insulated copper busbar to the ground. The positive pole of the capacitor bank is also grounded.

From the copper input, a well-insulated busbar leads to the central electrode. This is a cylinder of iron, aluminum or copper, 5-6 mm in diameter, which is tightly surrounded by a quartz glass tube. It rises above the water surface by 2-3 mm, the electrode itself is lowered down by 3-4 mm. A cylindrical hole is formed into which a drop of water can be dropped. The end of the copper wire from the negative pole of the capacitor bank must be secured to a long ebonite handle.

If you quickly touch the copper input with this spark gap, a plasma jet will fly out from the central electrode with a pop, from which a spherical plasmoid will separate and float in the air. Its color will be different: a bright whitish plasmoid will fall from the iron electrode, green from the copper electrode, and white with a reddish tint from the aluminum electrode: such plasmoids are seen by pilots when lightning strikes the plane.
To get real ball lightning, you need to insert a cylinder of porous carbon into a quartz tube. Such coals are used in arc spectral analysis. Porous carbon can be impregnated with various solutions and suspensions.

If you apply a water extract from the soil to the electrode, with organic matter, particles of coal and clay, then when discharged, classic “orange” colored ball lightning will fly out of the electrode. True, she will live no longer than a second, but this is enough to examine her in all details and admire her.

Obtaining real ball lightning is not difficult. You need linear lightning striking some kind of lightning rod, and damp air.
In order to study the properties of ball lightning, we had to make thousands of them.

First of all, electrical measurements have shown that ball lightning is, indeed, an autonomous formation: the current in the discharge circuit disappears after a tenth of a second, then the lightning moves freely and glows due to the accumulated energy.

Surprisingly, ball lightning has room temperature!

Lightning, by the way, is not much hotter than a cucumber in the garden. This paradox is associated with the special state of ions in the ball lightning core. Each ion generated during the discharge is immediately hydrated - in humid air it is tightly surrounded by water molecules. Opposite ions are attracted to each other, but water molecules prevent them from getting closer. A special state of matter arises—hydrated clusters.

Computer modeling has shown that in hydrated plasma the rate of ion recombination slows down sharply. If in “dry” plasma it occurs in a billionth of a second, then for ions conserved in a cluster, recombination is delayed for tens and hundreds of seconds. During this time the lightning will glow.

In the ball lightning core, hydrated clusters with a large dipole moment form chain and fractal structures. A cloud of warm, humid air can accumulate enormous energy, up to a kilojoule per liter, if it receives it during discharge in the form of separated ions of different signs.

Thus, the mystery of ball lightning can be considered solved. But just recently it took its place among the mysteries of nature discussed on television and in the press, somewhere next to UFOs, the Tunguska meteorite and the Bermuda Triangle.

And this is not surprising. The myth of ball lightning has fed more than one generation of journalists and scientists.

In pursuit of sensation, colorful details were introduced into reports of ball lightning. The farmer's simple story: “There was a strong clap of thunder. A ball of fire, the size of a fist, ran down the drainpipe and dived into a barrel of water. The water gurgled. I walked over and stuck my hand in the water. The water seems to have become warmer...”, after four consecutive reprints in newspapers, turned into a scientific work on calculating the energy reserve in a volume the size of a fist, capable of evaporating a volume of water the size of a barrel.


How to make lightning in Minecraft?


In Minecraft, almost everything is possible, including influencing the weather, causing various phenomena whenever you want. Below you can find out how to make lightning in Minecraft.

How to summon lightning in Minecraft using commands

You can create lightning in Minecraft by entering several commands in the game chat. There are two ways to do this. In the first case, you need to wait for a thunderstorm and enter the following command in the chat: /weather thunder. Then put a space and in triangle brackets indicate the duration in seconds of this weather phenomenon. It should look like this: /weather thunder<15>. That is, lightning will flash for 15 seconds.

During a thunderstorm you need to be more careful as the lighting will become dimmer. However, you can spawn several different hostile mobs, so you should take a weapon with you. Also, during a thunderstorm, you need to stay away from creepers that emit blue light, as they are hit by lightning and can explode.

Also, during a thunderstorm, you can call lightning with another command. You will need to enter the following into the chat: /summon LightningBolt. But you must have a Minecraft version higher than 1.8 installed, otherwise nothing will work.

Summoning lightning using plugins

You can call lightning yourself after installing a special plugin called. You can download it.

After installing it, you can become a real Zeus the Thunderer; you just need to craft a rod that spews lightning. This will require the following resources:

  • redstone dust;
  • gold bar;
  • wooden stick;
  • emerald.

You only need to correctly arrange the elements on the workbench: in the third upper cell - an emerald, in the central one - a stick, in the first lower one - dust, in the lower middle one - a gold bar. The treasured rod will be in your hands, and you will be able to strike any mob with lightning.

You will find more crafting recipes in our section.

The famous ball lightning hunter Igor Pavlovich Stakhanov (1928-1987) had to develop a special technique for interviewing eyewitnesses in order to separate reality from speculation and fiction. After critical processing of eyewitness accounts, Stakhanov, like James Dale Barry ten years before him, came to the conclusion that in most cases, ball lightning is a luminous spheroid, 12 x 25 cm in diameter, freely floating in the air and existing 12 seconds. Less commonly, ball lightning has the shape of a torus or crown. It is usually painted in different shades of yellow-red, there are also gray-blue and lilac tones and, sometimes, greenish - from an admixture of copper.

Most lightning has a visible luminous core and a surrounding shell. Sometimes the core rotates around a horizontal axis. In rare cases, sparkles can be seen inside the zipper, like on a New Year's ball. It never chars paper or fabric and does not produce the feeling of a heated body. Usually it disappears without a trace, although sometimes it explodes with a sharp bang, like a balloon containing hydrogen or methane.

In the rarest cases, ball lightning can last ten seconds. The chemist Mikhail Dmitriev was lucky enough to observe remarkable lightning in 1867 on the river. Onege. The air that day was clean, well washed by rain. After a strong linear discharge with a thunderclap, ball lightning appeared above a long (130 m) raft of wet logs that formed a conducting plane. Ball lightning, with a gray-blue core and a bluish shell, slowly moved over the raft, gradually rising, came ashore and, after random movements among the trees, disappeared. It lasted for more than thirty seconds. Dmitriev managed to take air samples near the lightning. The analysis showed that the samples contained elevated levels of ozone and nitrogen oxides, as happens after a thunderstorm.

Ball lightning is far from the only natural phenomenon associated with atmospheric electricity. In addition to them, there are linear lightning, current jets, beaded lightning, blue jets and sprites, various forms of sitting discharges and St. Elmo's fire. Linear lightning is a formidable natural phenomenon and is a powerful high-voltage breakdown of a humid atmosphere. Most often, a linear discharge occurs above the ground in the cloud layer.

Current jets, a rarer phenomenon, are the flow of electric charge through a channel left by linear lightning or a high-energy cosmic particle. Current jets are being intensively studied. They can be obtained artificially by launching a rocket with a wire tail into a thundercloud. An electric charge flows down the wire and a luminous trace with a round luminous head appears.

Under certain conditions, the head of the jet, enriched with electrons, can separate and exist for some time in the form of an autonomous luminous formation.

The current stream always moves along the line of least electrical resistance. It most often enters the house through a chimney, electrical wiring, telephone or television cable. It can fly into a window, flowing around the glass, and sometimes makes a hole in it.

In strong winds, when the air is electrified by friction, current jets appear in clear weather. Then the electric charge flows off invisibly, and only in the narrowness of the channel does a bluish glow appear.

In the mountains, in the pure rarefied air, current streams and the fires of St. Elmo appear more often than on the plain. Climbers often suffer from electric currents. Without going into details, they call them “ball lightning”.

The negative charge that comes to the surface of the earth during a linear lightning discharge spreads along a narrow electrically conductive channel. If this channel comes to the surface again, then a plasma jet can escape from it, from which ball lightning will separate and float. Rare eyewitnesses have seen the birth of ball lightning. All the more significant is the incident that occurred on one geodetic tower with a simple lightning rod made of an iron cable. It was carelessly buried at the base, its end sticking out of the puddle. When lightning struck the lightning rod, a dazzling jet burst out from the end of the cable, from which a luminous lump separated and floated in the air.

One of the most amazing and inexplicable properties of ball lightning is its ability to remove gold wedding rings from hands without causing burns. A gold or copper wire ring hung in the path of ball lightning loses part of its mass, which can be determined by weighing. Apparently, this phenomenon is associated with accelerated recombination of ions on the metal surface, which is accompanied by its sputtering.

Our ball lightning workshop was visited by hundreds of people who wanted to see a rare phenomenon: academicians, scientists, specialists in the field of atmospheric electricity, journalists, television people, and those simply interested in ball lightning.

Eyewitnesses of the natural phenomenon were especially grateful; the demonstration of ball lightning evoked in them memories of a previous meeting with them. New details were revealed. It turned out that there are many more observers of short-lived ball lightning than those surveyed by Stakhanov; many simply do not attach importance to their encounter with this fleeting phenomenon.

For some viewers, the flash of the plasma jet caused a persistent afterimage on the retina. It exists for ten seconds and moves in space when you turn your head. How can one not recall the theory that long-lived ball lightning is not a physical, but a physiological phenomenon.

Of course, this theory is not correct: ball lightning can certainly live for more than ten seconds. This is by no means a lump of plasma, as some believe. This is a complex physical and chemical formation - a club of lukewarm, humid air with an abundant population of hydrated unlike ions bound into clusters that form a certain structure surrounded by a negatively charged shell. The physics of ball lightning is the physics of enormous currents at relatively low voltage.

It will take years to study such a complex state of matter in detail. The process can be accelerated if a decent premium is set for the method of sustainable production of long-lived ball lightning. We need international competitions to obtain the longest-lived ball lightning. Perhaps this will not be so difficult: it is known that some lightning rods on high-rise buildings are readily visited by lightning throughout the year. It is enough to place a basin of dirty water in the path of the charge drain to get a testing ground for creating real natural ball lightning.

You fly your ship through a cave, dodging enemy fire. However, pretty soon you realize that there are too many enemies and it looks like this is the end. In a desperate attempt to survive, you press the Button. Yes, on that same button. The one you prepared for a special occasion. Your ship charges up and fires deadly lightning bolts at your enemies, one after another, destroying the entire enemy fleet.

At least that's the plan.

But how exactly do you, as a game developer, render such an effect?

Generating lightning

As it turns out, generating lightning between two points can be a surprisingly simple task. It can be generated as follows (with a little randomness during generation). Below is an example of simple pseudo-code (this code, like everything in this article, refers to 2d lightning. Usually this is all you need. In 3d, just generate the lightning so that its offsets are relative to the camera plane. Or you can generate a full-fledged one lightning in all three dimensions - the choice is yours)

SegmentList.Add(new Segment(startPoint, endPoint)); offsetAmount = maximumOffset; // maximum displacement of the top of the lightning for each iteration // (a certain number of iterations) for each segment in segmentList // We go through the list of segments that were at the beginning of the current iteration segmentList.Remove(segment); // This segment is no longer required midPoint = Average(startpoint, endPoint); // Shift midPoint by a random amount in the direction of the perpendicular midPoint += Perpendicular(Normalize(endPoint-startPoint))*RandomFloat(-offsetAmount,offsetAmount); // Make two new segments, from the start point to the end point // and through a new (random) central segmentList.Add(new Segment(startPoint, midPoint)); segmentList.Add(new Segment(midPoint, endPoint)); end for offsetAmount /= 2; // Each time we halve the offset of the center point compared to the previous iteration end for

Essentially, each iteration splits each segment in half, with the center point slightly shifted. Each iteration this shift is halved. So, for five iterations we get the following:








Not bad. It already looks at least like lightning. However, lightning often has branches going in different directions.

To create them, sometimes when you split a lightning segment, instead of adding two segments, you need to add three. The third segment is simply a continuation of the lightning in the direction of the first (with a small random deviation).

Direction = midPoint - startPoint; splitEnd = Rotate(direction, randomSmallAngle)*lengthScale + midPoint; // lengthScale is better to take< 1. С 0.7 выглядит неплохо. segmentList.Add(new Segment(midPoint, splitEnd));

Then, in the next iterations, these segments are also divided. It would also be a good idea to reduce the brightness of the branch. Only the main lightning should be at full brightness, since it is the only one connected to the target.

Now it looks like this:





Now it looks more like lightning! Well... at least the shape. But what about everything else?

Adding light

The original system developed for the game used rounded beams. Each lightning segment was rendered using three quads, each with a light texture applied (to make it look like a rounded line). The rounded edges intersected to form joints. Looked pretty good:

... but, as you can see, it turned out quite bright. And, as the lightning decreased, the brightness only increased (as the intersections became closer). When trying to reduce the brightness, another problem arose - the transitions became Very visible as small dots along the entire length of the lightning.
If you have the ability to render lightning on an off-screen buffer, you can render it by applying maximum blending (D3DBLENDOP_MAX) to the off-screen buffer, and then simply add the result to the main screen. This will avoid the problem described above. If you don't have this option, you can create a vertex cut from the lightning by creating two vertices for each point of the lightning and moving each of them in the direction of the 2D normal (the normal is perpendicular to the average direction between the two segments going to that vertex).

It should look something like this:

Animating

And this is the most interesting thing. How do we animate this thing?

After experimenting a bit, I found the following useful:

Every lightning is actually two lightning at a time. In this case, every 1/3 second, one of the lightning ends, and the cycle of each lightning is 1/6 second. With 60 FPS it will look like this:

  • Frame 0: Lightning1 is generated at full brightness
  • Frame 10: Lightning1 is generated at partial brightness, lightning2 is generated at full brightness
  • Frame 20: New lightning1 is generated with full brightness, lightning2 is generated with partial brightness
  • Frame 30: New lightning2 is generated at full brightness, lightning1 is generated at partial brightness
  • Frame 40: New lightning1 is generated at full brightness, lightning2 is generated at partial brightness
  • Etc.

That is, they alternate. Of course, a simple static fade doesn't look very good, so each frame it makes sense to move each point a little (it looks especially cool to move the end points more - it makes everything more dynamic). As a result we get:

And of course you can move the endpoints... let's say if you're aiming at moving targets:

And it's all! As you can see, making a cool looking zipper is not that difficult.