Add files via upload

This commit is contained in:
squiddible 2020-05-02 16:32:54 -04:00 committed by GitHub
parent 8d35e69bc2
commit 04e0d1c300
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

28
init.lua Normal file
View File

@ -0,0 +1,28 @@
local func = function()
local player = minetest.get_player_by_name("singleplayer")
local pos = player:get_pos()
local grav = 1
if pos.y > 10 then grav = 10/pos.y end
player:set_physics_override({gravity=grav})
end
minetest.register_abm({
nodenames = {
"air",
"default:stone",
"default:dirt",
"default:sand",
"default:water_source"
},
neighbors = {
"air",
"default:stone",
"default:dirt",
"default:sand",
"default:water_source"
},
interval = 1,
chance = 1,
action = func
})