projects
/
zefram
/
minetest
/
minetest_engine.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
ea36951
)
Improve /spawnentity a bit
author
Perttu Ahola
<celeron55@gmail.com>
Sun, 4 Dec 2011 14:20:54 +0000
(16:20 +0200)
committer
Perttu Ahola
<celeron55@gmail.com>
Sun, 4 Dec 2011 14:20:54 +0000
(16:20 +0200)
data/mods/default/init.lua
patch
|
blob
|
history
diff --git
a/data/mods/default/init.lua
b/data/mods/default/init.lua
index e2d267d4e04b238865f3a64e2f8d7704add39145..782eba5a546530b05b993f5a3cabe993a58e5949 100644
(file)
--- a/
data/mods/default/init.lua
+++ b/
data/mods/default/init.lua
@@
-1491,7
+1491,9
@@
minetest.register_on_chat_message(function(name, message)
print("Unable to spawn entity, player is nil")
return true -- Handled chat message
end
- minetest.env:add_entity(player:getpos(), entityname)
+ local p = player:getpos()
+ p.y = p.y + 1
+ minetest.env:add_entity(p, entityname)
minetest.chat_send_player(name, '"'..entityname
..'" spawned.');
return true -- Handled chat message