1
0
mirror of https://github.com/HybridDog/nether-pack.git synced 2024-11-16 15:30:20 +01:00
Commit Graph

35 Commits

Author SHA1 Message Date
Deathwing777
84d5e1ce3c
Made changes after testing previous commit.
init.lua:
- Added `nether.bottom`

portal.lua:
- Reverted `nether.is_player_in_nether(player)` to previous state.
- Added `nether.is_player_trapped_in_nether(player)`
- Added 2 new chat functions for debugging purposes.
- Tested that chat function `/update_hells_registry` indeed works to check if a player has dug their way out of the nether.
- Moved the functional code from `/update_hells_registry` to `nether.registry_update(player)`
- Fixed some English grammar in automated chat messages.
2024-02-27 17:49:30 -08:00
Deathwing777
2951813d2c
Implemented HybridDog's change request.
- Modifications to `nether.is_player_in_nether()` and `nether.external_nether_teleport()`
- Renamed `players_in_nether[]` to `players_trapped_in_nether[]`
- Fixed punctuation in a comment. =D
2024-02-27 12:50:35 -08:00
Deathwing777
242a32e1ad
Implemented HybridDog's change requests.
This should now be ready to merge.
2024-02-24 11:49:58 -08:00
Deathwing777
9af94a8bc6
Code cleanup and new global/chat function.
- Added a new global function to the nether table that lets external mods tell us to update a player's Nether status based on the player's position. This function has been exposed to the console via a registered chat function.
- Switched from NETHER as the global table to nether as the global table after discovering that nether was already being used in init.lua.
- Switched from accessing function calls in the global table from  table syntax to object syntax; as it looks cleaner.
2024-02-20 14:53:14 -08:00
Deathwing777
9c98786ff7
Fixes HybridDog#16
Added new chat function `in_hell [<player_name>]` and used it to find the bug. The issue was that `local function obsidian_teleport(player, pname, target)` failed to test `nether.trap_players` before modifying `players_in_nether`.
2024-02-20 13:24:29 -08:00
Deathwing777
17cf0ff5a3
Fixes Issue #14
Fixes: "Needs a global table so other mods can be nether aware. #14"
2024-02-20 12:03:32 -08:00
HybridDog
02d14a8970 Fix nether portal detection
The function which calculates positions of an empty square currently has a bug:
it returns the northeastern and southwestern corners twice
and omits the northwestern and southeastern ones.
This leads to a nether portal detection which is not rigorous enough, skipping eight nodes.

This commit fixes the problem.
Closes #13
2023-10-30 17:39:56 +01:00
HybridDog
f12d33c743 Replace deprecated function names (e.g. moveto -> move_to) and make stairs optional 2022-08-20 20:11:35 +02:00
HybridDog
817efcdd29 Add settingtypes.txt to configure player trapping and message logging
There are also some changes to fix problems when trapping is enabled while damage is disabled or the other way round.
2022-08-16 17:25:41 +02:00
HybridDog
6507e43dc5 Do not ignore the portal code if damage is enabled and the "nether_players" file does not exist
I have accidentally introduced the bug in commit 4a7dd247e7.
It was discovered thanks to the people who reported it on the Minetest forum.
2022-08-15 15:47:16 +02:00
Desour
27bf94c4d0 Fix portal player y pos being off by 1 node sometimes 2022-07-26 17:52:25 +02:00
HybridDog
c35d18a519 Fix some deprecation warnings 2021-12-22 18:46:56 +01:00
HybridDog
fb1eca6c11 Add .luacheckrc and do some code fixes 2021-12-22 18:46:52 +01:00
HybridDog
fadf202663 Fix object teleportation from and to nether 2018-08-18 20:00:40 +02:00
HybridDog
df2d49edb0 Override player:set_pos etc. to disallow teleports from/to nether
constantly testing the player position is not longer necessary.
2018-08-15 19:52:39 +02:00
HybridDog
4a7dd247e7 Do not use players_in_nether as list but hashmap
Also, comment broken function
2018-08-15 17:31:15 +02:00
HybridDog
2f3522598c portal.lua: Fix some 80 char line breaks 2018-08-15 16:57:23 +02:00
HybridDog
020ab700ff Fix get_node vs get_node_or_nil usage 2018-08-15 16:52:04 +02:00
DS-Minetest
e8a666f34e replace deprecated setting methods 2017-07-05 18:52:46 +02:00
HybridDog
03da51be24 add support to the function delayer mod 2016-05-04 18:36:22 +02:00
Wouters Dorian
b2dd95eb50 Don't use globalsteps 2016-05-04 18:32:17 +02:00
HybridDog
99eceb10eb assume player:getpos always returns a vector
remove patch file
2016-05-04 18:27:36 +02:00
2a3e553b9c fix crash nether if player cancel join server "/nether/portal.lua:243: attempt to index a nil value" 2016-05-04 18:24:57 +02:00
HybridDog
9cee9d0ec6 🐈 2016-01-04 13:25:06 +01:00
HybridDog
041f1ce21a untested: save known opposite portal y to meta 2016-01-04 12:00:35 +01:00
HybridDog
b8f81b71bc make obsidian portal always work 2016-01-04 11:48:21 +01:00
HybridDog
cacfae9502 add comments and begin making obsidian portal always work 2016-01-04 10:55:39 +01:00
HybridDog
524312a8d3 change nether pearl and portal.lua 2016-01-01 12:39:21 +01:00
HybridDog
6245b9e4e1 allow disabling killing of people using the simple portal 2015-12-31 15:15:39 +01:00
HybridDog
1003e8288c dont send players to hell if they execute those chatcommands without nether priv 2015-12-30 11:16:58 +01:00
HybridDog
a0995f18f8 cache used portals instead of always teleporting to 100 etc 2015-12-28 20:04:38 +01:00
HybridDog
624cf7243d update chatcommand 2015-12-28 19:01:30 +01:00
HybridDog
1e0bcbb709 fix player doesnt hear nether teleporter sound, thanks to @crabman77 2015-12-28 18:38:09 +01:00
HybridDog
b09a30c141 🐈 2015-05-29 12:08:27 +02:00
HybridDog
7c75dafcdb at least a bit history 2015-02-18 18:34:03 +01:00