Page 1 of 1

mod doesn't work anymore

PostPosted: Sat Feb 01, 2014 02:16
by wcwyes
I was working on this mod in 0.4.7 but it doesn't seem to work anymore
Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
Code: Select all
minetest.register_chatcommand("spawn",
    {
        params = "",
        description = "respawn",
        func = function(name)
            local spawn_point = minetest.string_to_pos(minetest.setting_get("static_spawnpoint"))
            local player = minetest.get_player_by_name(name)
            player:setpos(spawn_point);
        end
})

PostPosted: Sat Feb 01, 2014 07:39
by sfan5
1) This is seriously annoying me, can't people read? This topic clearly belongs into Modding General, but no, you posted it in General Discussion as apparently nobody is able to read </rant> Topic moved to Modding General

2) By just saying 'Doesn't work' nobody will be able to help you

PostPosted: Sat Feb 01, 2014 10:45
by PilzAdam
wcwyes wrote:I was working on this mod in 0.4.7 but it doesn't seem to work anymore
Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
Code: Select all
minetest.register_chatcommand("spawn",
    {
        params = "",
        description = "respawn",
        func = function(name)
            local spawn_point = minetest.string_to_pos(minetest.setting_get("static_spawnpoint"))
            local player = minetest.get_player_by_name(name)
            player:setpos(spawn_point);
        end
})

This will only work if you have set static_spawnpoint in minetest.conf, which is not always the case.