Add sneak_glitch

Ill be unsing the old code.
This commit is contained in:
Elkien3 2017-10-20 12:28:16 -05:00
parent 493713fc75
commit 07720626da
3 changed files with 47 additions and 0 deletions

View File

@ -0,0 +1,30 @@
Minetest mod: sneak_glitch
============================
This mod re-enables the sneak glitch in your Minetest world. It
will allow you to use the 1-row and 2-row sneak ladders again.
License: CC0
Dependencies: (none)
Old sneak behaviour
----------------------
If you dislike the new sneak code, add the following setting
to your minetest.conf file:
sneak_glitch.use_old_code = true
In case you used the ingame command `/set` to do this change,
rejoin the world in order to apply the new settings for this mod.
Other climbing mods
---------------------
Make all leaves climbable [climbing_leaves]
https://forum.minetest.net/viewtopic.php?t=15679
https://github.com/pithydon/climbing_leaves
Mountain Climbing [handholds]
https://forum.minetest.net/viewtopic.php?t=17069
https://github.com/Ezhh/handholds

View File

@ -0,0 +1,15 @@
-- Enable the sneak glitch (horray!)
local use_old_code = minetest.settings:get_bool("sneak_glitch.use_old_code")
if use_old_code == nil then
-- Default to the new sneak code
use_old_code = false
end
minetest.register_on_joinplayer(function(player)
player:set_physics_override({
sneak_glitch = true,
sneak = true,
new_move = not use_old_code
})
end)

View File

@ -0,0 +1,2 @@
# Replaces the new sneak behaviour with the old one
sneak_glitch.use_old_code (Use old sneak code) bool false