Skip to content

Commit 4d9c918

Browse files
authoredOct 20, 2020
Devtest: Automatically enable zoom capability (#10493)
Make minor improvements to the zoom testing chat command. Delete incorrect line about creative mode from README.md.
1 parent c7aa92a commit 4d9c918

File tree

2 files changed

+6
-5
lines changed

2 files changed

+6
-5
lines changed
 

Diff for: ‎games/devtest/README.md

-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,6 @@ Basically, just create a world and start. A few important things to note:
2323
* Use the `/infplace` command to toggle infinite node placement in-game
2424
* Use the Param2 Tool to change the param2 of nodes; it's useful to experiment with the various drawtype test nodes
2525
* Check out the game settings and server commands for additional tests and features
26-
* Creative Mode does nothing (apart from default engine behavior)
2726

2827
Confused by a certain node or item? Check out for inline code comments. The usages of most tools are explained in their tooltips.
2928

Diff for: ‎games/devtest/mods/util_commands/init.lua

+6-4
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,12 @@ minetest.register_chatcommand("hp", {
3636
end,
3737
})
3838

39-
minetest.register_chatcommand("zoom", {
40-
params = "[<zoom_fov>]",
39+
minetest.register_on_joinplayer(function(player)
40+
player:set_properties({zoom_fov = 15})
41+
end)
42+
43+
minetest.register_chatcommand("zoomfov", {
44+
params = "[<FOV>]",
4145
description = "Set or display your zoom_fov",
4246
func = function(name, param)
4347
local player = minetest.get_player_by_name(name)
@@ -58,8 +62,6 @@ minetest.register_chatcommand("zoom", {
5862
end,
5963
})
6064

61-
62-
6365
local s_infplace = minetest.settings:get("devtest_infplace")
6466
if s_infplace == "true" then
6567
infplace = true

0 commit comments

Comments
 (0)
Please sign in to comment.