1
0
Fork 0
Commit Graph

53 Commits (c6fc911c12603d253528e700980161ad4121d277)

Author SHA1 Message Date
ancientmarinerdev be8d9122ee Fix crash when creeper explodes in minecart 2023-05-07 21:11:48 +01:00
ancientmarinerdev 547973877a Fix old burning storage crash and log any relevent info. 2023-03-12 21:08:24 +00:00
Johannes Fritz 36427d5aef Check enable damage instead of creative mode in some cases 2022-10-09 21:45:05 +02:00
Sumyjkl eb89466436 add dependency for mcl_weather to mcl_burning to hopefully avoid crashes 2022-08-03 22:45:15 +10:00
cora ef093d0c00 Be more careful with possibly expired objects 2022-06-04 20:26:00 +02:00
kabou 1b99b73894 Fix wrong player name accessor.
* Duh..
2022-03-30 01:31:38 +02:00
kabou 14da059ce7 Add extra check and warning on missing player data.
* For some unexplained reason, `mcl_burning.storage[player]` can
  sometimes be `nil`, causing a crash in `on_leaveplayer()`.  This
  commit adds a check for that.  If a `nil` is encountered, a sane
  value is substituted and a warning is set to the log.
2022-03-29 12:06:00 +02:00
kabou 9eba0e4860 Remove unused code.
* Remove unused code that was commented out.  The code tried to find
  fire luaentities in the same spot as the newly created fire luaentity.
  It may have been intended to optimize getting set on fire multiple
  times, but it makes no sense as it does not discriminate between fire
  luaentities attached to the object set on fire and those attached to
  other objects.  The function that this code was in also has a better
  way to prevent adding multiple fire luaentities in the first place.
2022-03-18 11:39:11 +01:00
kabou 90311da514 Preempt possible crash on nil in on_joinplayer.
* In mineclone5 a crash was reported to occur when deserialization of
  storage returned nil in on_joinplayer.    https://git.minetest.land/
  MineClone5/MineClone5/commit/96c4fb60d8641b4181edb902ed24dbf173828d09
  This commit uses a different, but equally effective fix.
2022-03-18 11:36:33 +01:00
kabou e9ff2ba32a Minor changes to mcl_burning.
* Remove animation_frame from fire entity state, it is now kept in the
  storage table of the parent entity.
* Rename animation_timer in fire entity table to _mcl_animation_timer,
  in line with mineclone2 policy on adding custom members to minetest
  tables.
* Comment out code that does nothing sensible.  Scheduled for deletion
  at a later time.
2022-03-18 11:36:23 +01:00
kabou c3e0996902 Fix fire HUD not showing on join while burning.
* Add the fire HUD to a player who joins the server while still burning
  from the previous session.
2022-03-02 17:15:05 +01:00
kabou d424d4f10e Add comments to mcl_burning.update_hud(). 2022-03-02 16:39:27 +01:00
kabou e80006f4ea Do not set fire to objects that are already burning.
Changes to mcl_burning.set_on_fire():
* Add logic that only updates the burn time, but skips adding fire
  entities to objects that are already burning.
* Condense code a little, remove single use variables.
* Add a comment to a questionable piece of code.
* Add comments to the function.
2022-03-02 16:25:40 +01:00
kabou b17776699e Add comments to "storage" table.
* Document attributes of the "storage" table.
2022-03-02 15:40:29 +01:00
kabou 86a4ece7d2 Add local copy of minetest.find_nodes_in_area. 2022-03-02 15:25:03 +01:00
kabou df5d24104d Make player burning HUD work without csm.
* Add update_hud() function.
* Remove the client channels.
* Unglobalize animation_frames variable.
* Fix bug where player state was not stored on shutdown of singleplayer
  game.
* Remove superfluous sanity_check() function, this code could easily be
  inlined in its only caller.
2022-03-02 15:21:55 +01:00
kabou 56b63463a5 Fix burning entity animation.
The parameters for the flames sprite were incorrect, causing the reverse
side of the sprite to appear as an opaque black rectangle.  Use the
correct incantation.
2022-03-02 10:47:46 +01:00
iliekprogrammar 96c4fb60d8
Fix crash on startup during immediate runtime by mcl_burning
The crash occurs if mcl_burning:data is deserialized to nil. The cause of
mcl_burning being set to "return nil" is unknown. Therefore, when it occurs, it
will be logged as warning.
2021-11-13 10:55:24 +08:00
Elias Fleckenstein 27e4bd6d09 Fix burning entity packet spam
- Use upright_sprite for 3rd person flame display, which is both closer to minecraft and allows for client side texture animation
- Take care of flame HUD in the MineClone2Client
2021-09-18 22:28:20 +02:00
AFCMS cd33d406b2 fix many codestyle issues (functions, strings, modpaths) 2021-05-29 16:12:33 +02:00
AFCMS ad16fe7072 [mcl_burning] fix warnings 2021-05-25 00:48:46 +02:00
Elias Fleckenstein fb60bd0253 Disable backface culling of fire entity 2021-05-21 20:45:53 +02:00
Elias Fleckenstein edc89898bb Integrate fire resistance 2021-04-25 20:51:13 +02:00
Elias Fleckenstein 302175691a Integrate death messages 2021-04-25 16:42:38 +02:00
Elias Fleckenstein 58d67aace6 Merge branch 'master' into damage 2021-04-25 13:29:07 +02:00
Elias Fleckenstein 9eba2add3f Rewrite burning API 2021-04-25 13:09:20 +02:00
Elias Fleckenstein a03e7f6f3a Re-enable player ignition from lava 2021-04-23 13:46:20 +02:00
Elias Fleckenstein ca75a893db Merge branch 'master' into damage 2021-04-17 12:58:19 +02:00
Elias Fleckenstein bd3c08d367 Improve mcl_burning player performance 2021-04-16 19:50:56 +02:00
Elias Fleckenstein 875bb3db84 Use fire-like damage types properly 2021-04-14 17:20:51 +02:00
Elias Fleckenstein ce0148d9a8 Rewrite armor; new damage system 2021-04-14 15:46:52 +02:00
Elias Fleckenstein fe937665f9 Fix #1336 2021-03-24 08:27:31 +01:00
Elias Fleckenstein ecd27a4cdb Initialize burning HUD with proper texture 2021-03-19 11:41:29 +01:00
Elias Fleckenstein 55df2a57f4 Fix #1336 2021-03-19 11:40:46 +01:00
Elias Fleckenstein 4ff987ccc5 Remove burning sound for objects 2021-03-19 11:39:04 +01:00
AFCMS 6645c4cb30 Really 2021-03-16 17:43:32 +01:00
AFCMS 5d17a6b699 fix SO MANY pairs/ipairs 2021-03-16 17:35:46 +01:00
kay27 cad23bd851 Prevent accessing uninitialized mcl_weather from mcl_burning 2021-03-16 14:05:38 +04:00
Elias Fleckenstein 5de9d90569 Simplify mcl_burning API 2021-02-22 10:55:14 +01:00
Elias Fleckenstein c9e589b931 Add mcl_burning damage interval 2021-02-18 14:47:35 +01:00
HimbeerserverDE 00df587bf7 Add flame enchantment 2021-01-27 20:11:02 +01:00
kay27 2e898b3113 Decrease player burn time in Creative mode 2021-01-22 20:03:55 +04:00
MysticTempest 689e6edac2 Make 'mcl_burning' support other texture packs. 2021-01-22 03:07:21 -06:00
Elias Fleckenstein b6aabfc853 Fix #992 2021-01-20 16:20:45 +01:00
Elias Fleckenstein b338d36d63 Remove the /burn command 2021-01-12 09:19:18 +00:00
Elias Fleckenstein f86cf37ac9 Fix zombies sometimes just disappearing when dieing to fire 2021-01-04 13:30:30 +01:00
Elias Fleckenstein 10d6ca4107 Change max_hear_distance of fire sound and tweak fire entity size 2021-01-03 18:22:33 +01:00
Elias Fleckenstein c2521885ff Remove extinguish sound 2021-01-02 14:03:50 +01:00
Elias Fleckenstein 939a73dd77 Remove Licenses from mcl_burning and mcl_enchanting 2021-01-02 11:18:18 +01:00
Elias Fleckenstein 071ba77bb0 mcl_burning fully working 2021-01-01 19:25:47 +01:00