This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Inductive read_thread st defs : list nat -> rthreadptr -> term -> Prop := | |
| read_thread_val : forall varmap rid v c t h, | |
nth_error st.(st_rthreads) rid = Some {| rt_code := Val v ; rt_cont := c |} -> | |
read_val st defs varmap v t -> | |
read_cont st defs varmap c h -> | |
read_thread st defs varmap rid (fill_hctx h t) | |
| read_thread_term : forall varmap rid e el c t h, | |
nth_error st.(st_rthreads) rid = Some {| rt_code := Term t e ; rt_cont := c |} -> | |
closed_at t (length e) -> | |
Forall2 (read_val st defs varmap) e el -> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
type term = | |
| Var of string | |
| Lam of string * term | |
| App of term * term | |
module SMap = Map.Make(String) | |
type value = | |
| Clos of string * term * env * (string * value) option ref | |
| Freevar of string |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
local function do_compile(expr, output, i) | |
if expr.type == "constant" then | |
output[i] = {type = "constant", value = expr.value} | |
return i + 1 | |
elseif expr.type == "builtin_function" then | |
for _, arg in ipairs(expr.args) do | |
i = do_compile(arg, output, i) | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
local t = 0 | |
local function make_color(x, y, z) | |
return string.format("#%02x%02x%02x", math.floor(x * 255), math.floor(y * 255), math.floor(z * 255)) | |
end | |
minetest.register_globalstep(function(dtime) | |
t = t + dtime | |
if t > 30 then t = 0 end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
local settings = { | |
enable_fire = {"Enable fire", "bool", true}, | |
enable_tnt = {"Enable TNT", "bool", true}, | |
} | |
local settings_list = { | |
"enable_fire", | |
"enable_tnt", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/src/localplayer.cpp b/src/localplayer.cpp | |
index ab30df22..35d3e224 100644 | |
--- a/src/localplayer.cpp | |
+++ b/src/localplayer.cpp | |
@@ -450,7 +450,7 @@ void LocalPlayer::move(f32 dtime, Environment *env, f32 pos_max_d, | |
*/ | |
const ContentFeatures &f = nodemgr->get(map->getNodeNoEx(getStandingNodePos())); | |
// Determine if jumping is possible | |
- m_can_jump = touching_ground && !in_liquid; | |
+ m_can_jump = (touching_ground || (physics_override_sneak_glitch && m_sneak_node_exists && control.sneak)) && !in_liquid; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
minetest.register_privilege("forceload", | |
{description = "Can use world forceloaders", | |
give_to_singleplayer = true}) | |
minetest.register_node("worldloader:worldloader", { | |
description = "Test", | |
drawtype = "normal", | |
tiles = {"worldloader_worldloader.png"}, | |
groups = {oddly_breakable_by_hand = 2}, | |
on_place = function(itemstack, user, pointed_thing) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pipes = [[None] * 10 for i in range(10)] | |
new_pipes = [[None] * 10 for i in range(10)] | |
new_pipes2 = [[None] * 10 for i in range(10)] | |
for i in range(5): | |
pipes[1][i+1] = 0 | |
def update(): | |
for i in range(1, 9): | |
for j in range(1, 9): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--run Files | |
local modpath = minetest.get_modpath("waypoints") | |
waypoints = {} | |
waypoints.players = {} | |
local time = 0 | |
minetest.register_on_leaveplayer(function(player)--Called if on a server, if single player than it isn't called | |
--specialties.writeXP(player:get_player_name()) | |
end) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
minetest.get_force_load_handler() | |
^ returns a force load handler | |
handler.force_load_block(pos) | |
^ force loads the block containing pos | |
^ returns the number of times the block is currently force loaded by the handler | |
^ can be 0 if the block was not force loaded | |
^ force loading a block multiple times does not count towards the max force loaded | |
^ block limit of the handler |
NewerOlder