Usage and tool break sounds were played at 'pointed_thing.above' which
can be nil if not pointing at anything or at an entity. This caused
sounds to be played to all players on a server non-positionally.
Fallback to player pos for sounds if 'pointed_thing.above' is nil.
Replace 'pt' variable with 'pointed_thing' in 'register_tool'.
TNT removes flammable nodes from the destruction radius and should
remove flames within it too because they lose their fuel and would
be removed by ABM later anyway.
Previous code:
Used looped sounds without attaching them to objects or playing direct
to players.
The looped sounds are not 'stopped' when players leave the area.
These may be causing the bug where sounds are heard at extreme
distances.
Entering a world with already present flames results in silent flames.
Sounds are often played at a large number of points in a 6 node lattice.
A large fire is reported to cause a high load, disabling the sound code
is reported to help this.
New code:
Optional flame sound to not interfere with ambience mods.
Permanent flame now has sound.
For multiple flames, sound is positioned at the centre of all flames, and
has volume determined by flame number.
The original freesound 'large fire' recording was used to create 3 sounds
that play at random for a non-repetitive effect. At low volume it is
suitable for small fires.
Original sound files and sound function (as an empty function) kept
temporarily to reduce disruption.
Reduce gain of flame extinguish sound.
With mip-mapping enabled, some GPUs cause a visual bug with indexed
textures that use alpha. This bug has been present for a while but
not noticed before. All indexed alpha textures must now be converted
to RGBA, to start this process we revert some textures converted to
indexed in the recent commit af3c918.
This fixes all cases where the color profile was broken, and
libpng warns about. It also makes almost all textures indexed
instead of RGB where possible (textures that don't have
semi-transparent pixels).