Post your mod requests/ideas here

markveidemanis
Member
 
Posts: 211
Joined: Thu Sep 27, 2012 15:41

by markveidemanis » Mon Dec 10, 2012 13:38

panels - like from hdblocks mod, but 16x16 and really thin and only add top, bottom and side
simple|!
BitCoin: 1Eq4arvykGNa1YC2DbJpWcwGfMvtFGjAoR
 

frenchfan=binou
 

by frenchfan=binou » Tue Dec 11, 2012 15:52

Hello, please, is there a function and or a module Minetest, Minecraft, which scans all external mods (= add-ons / modules), in addition to what is available by default in the base game (without modules) and directly displays that can be manufactured without having to find what and how. The same kind of table on minecraft xbox in fact ?! thank you very much in advance.

Yes, please, that one or more great dev (woman(s) or man(s)) provides that, if there is not yet currently this function, the table shows that all the can be made and how, +or- (but best as possible) as the xbox. Thank you, please, always.

In all modules and in the base game (with or without modules here), readable by the function and or special module, you need to add tags (( < / explanatory:en-US > )) around to the explanatory text, of what this object is, how to make it in the workshop (crafting table) and how to use it, (with management languages translation, and in to files standardized to provide the translated text, otherwise english by default, but the tree (the structure to add translations) should be there already in place), and to retrieve other information about objects that can be made it in the crafting table (such as what resources are needed). For "what resources are needed", the code can be scanned but it would be better to have tags dedicated to accelerate research that can be produced when opening the workshop. Thank you in advance for improvements.

(It lacks a graphical system to modify all configuration files (as i see it is often necessary to modify the files to activate an option or otherwise), the same idea of compatibility and be able to read external modules for the workshop (crafting table) :

- 1a) There should have a window like the Windows Notepad (like theme xp) ;
- 1b) At right (reading a special file containing all the possibilities for the current file, and also reading all special file of the modules may contain a change to the current file), such as vertical tabs that are in fact each of them, an available line (the name of an option tag) in the file open on the left.
- 1b=>) * Each lines at right or tabs should have a drop down menu with multiple choices, with the help and explanation (with a translation) of each attribute / value data and there would have a button to add or remove the option.
- 1b=-=>) - If possible, with a system of sorts to find out which options are placed on the lines.
- 1b=>) * Should be able to undo / redo the last action (with tracking, for see, what is going to be canceled (undo) / redo again) and see if something has changed (Apply button grayed out as nothing is changed).
- 1c) The end of the line (carriage return) Linux / Windows to be processed automatically and also correctly.

Thank you tremendously please.)

/!\ The advantage with the game minetest is that we are not obliged to register and have internet !

Minecraft : https://minecraft.net/download
Download Minetest : http://minetest.net/download.php
 

dise
New member
 
Posts: 4
Joined: Sun Nov 11, 2012 12:36

by dise » Fri Dec 14, 2012 23:05

markveidemanis wrote:hi, can someone make a mod that lets some people on a server be in creative mode, and some in survival mode. possible like a command: /gamemode [creative/survival]
thanks

+1
 

Kryuko
Member
 
Posts: 76
Joined: Tue Dec 11, 2012 20:26

by Kryuko » Wed Dec 19, 2012 17:05

Hi.
Can someone make tpa mod?
In minecraft, the tpa is a teleport for the normal users, when someone using tpa for teleporting to another user, this user receive one teleport request, he can accept the teleport or decline.

Can someone make it please?
 

4aiman
Member
 
Posts: 1208
Joined: Mon Jul 30, 2012 05:47

by 4aiman » Sun Dec 23, 2012 22:22

I've found some topic about the "fun" (http://minetest.net/forum/viewtopic.php?id=4050) and want to expand the griefing theme.
The main point of some users was that protection make it impossible to come an conquer some area like it happened in the real history - with the destruction of the buildings and so on. I do NOT appreciate griefing, but that topic make me think that it could be some fun in griefing IF:
- each player by placing any block obtains exlusive rights to the area around that block (placed block + one block around that);
- if the area is taken allready, the player should get a mesage of that very fact;
- the owner of that area should be notified that he have a message, asking for building on his territory;
- there were protection of the buildings made by currently offline players;
- the buildings must be destroyable only when their owner can protect them e.g. when he or she is online;
- there should be parties or "home city" identification and that should be displayed near the nickname;
- only parties that has declared "war" to each other could grief each other's buildings;
- only councilium of all party members may decide to declare a war;
- war would be declared when no less than 70% is for it;
- those, who was against the war should have a chance to switch their parties (but not for any of that which would be at war with their current);
- those, who was against the war should have a chance to create a new party;
- those, who was against the war must be able to live in ther houses undisturbed, but if they would go outside - they can get killed - a war is a war, jus consider neutral citizen house=bunker ;)

I believe with that implemented some people would enjoy it ;)
Last edited by 4aiman on Sun Dec 23, 2012 22:23, edited 1 time in total.
 

User avatar
rubenwardy
Member
 
Posts: 4500
Joined: Tue Jun 12, 2012 18:11
GitHub: rubenwardy
IRC: rubenwardy
In-game: rubenwardy

by rubenwardy » Mon Dec 24, 2012 14:10

4aiman wrote:I've found some topic about the "fun" (http://minetest.net/forum/viewtopic.php?id=4050) and want to expand the griefing theme.
The main point of some users was that protection make it impossible to come an conquer some area like it happened in the real history - with the destruction of the buildings and so on. I do NOT appreciate griefing, but that topic make me think that it could be some fun in griefing IF:
- each player by placing any block obtains exlusive rights to the area around that block (placed block + one block around that);
- if the area is taken allready, the player should get a mesage of that very fact;
- the owner of that area should be notified that he have a message, asking for building on his territory;
- there were protection of the buildings made by currently offline players;
- the buildings must be destroyable only when their owner can protect them e.g. when he or she is online;
- there should be parties or "home city" identification and that should be displayed near the nickname;
- only parties that has declared "war" to each other could grief each other's buildings;
- only councilium of all party members may decide to declare a war;
- war would be declared when no less than 70% is for it;
- those, who was against the war should have a chance to switch their parties (but not for any of that which would be at war with their current);
- those, who was against the war should have a chance to create a new party;
- those, who was against the war must be able to live in ther houses undisturbed, but if they would go outside - they can get killed - a war is a war, jus consider neutral citizen house=bunker ;)

I believe with that implemented some people would enjoy it ;)


Good idea! no idea how to code it...
 

tux_peng
Member
 
Posts: 99
Joined: Thu Dec 06, 2012 18:21

by tux_peng » Mon Dec 24, 2012 22:43

Servers now up (Economy, no PvP) Forum up already! http://tuxcraft.info
 

User avatar
jmf
Member
 
Posts: 164
Joined: Mon Nov 05, 2012 18:13

by jmf » Wed Dec 26, 2012 13:02

tux_peng: you can make a new player model easily.
If the server has got this model, every player uses it.
Add textures to it and you have got your pony mod.
Last edited by jmf on Wed Dec 26, 2012 13:03, edited 1 time in total.
My ingame name is "john", my IRC name is "john_minetest".
I am chef mod on this server: minetest.org : 30015(see here)
"I am immune to signature virus." <-- Add this to your signature to gain immunity!!!
 

Maro
 

by Maro » Thu Dec 27, 2012 22:12

A Mobs (creepers and villagers) mod and an Armor mod.
 

User avatar
Chinchow
Member
 
Posts: 683
Joined: Tue Sep 18, 2012 21:37

by Chinchow » Thu Dec 27, 2012 22:16

Maro wrote:A Mobs (creepers and villagers) mod and an Armor mod.

There is 2D mobs mod and a 3d npc mod as for armor Nubelite made one although you can't see it on your player btw creepers are from minecraft if you want minecraft things go play minecraft
Sometimes, it's harder to think up a mod than it is to create it.
Mods: Orichalcum Stonebricks Extra Chests
 

Josh
Member
 
Posts: 1146
Joined: Fri Jun 29, 2012 23:11

by Josh » Fri Dec 28, 2012 02:15

Chinchow wrote:if you want minecraft things go play minecraft

Exactly, This is mineTEST :)
Last edited by Josh on Fri Dec 28, 2012 02:16, edited 1 time in total.
 

Josh
Member
 
Posts: 1146
Joined: Fri Jun 29, 2012 23:11

by Josh » Fri Dec 28, 2012 02:25

Pilzadam's quest
-------------------------------------------------------------------------------------------------------------------------------------------------------------
Salutation's sir Pilzadam the noble king of minetest challeges you to make a Realistic-looking chest like you see in dungeons and other similar places. It's look can be 3D shaped, size is your choice and it has to open. Succeed in your quest and you will receive a mese cookie.
-------------------------------------------------------------------------------------------------------------------------------------------------------------
P.S: You don't have to make this, but it would be intresting :)
 

User avatar
PilzAdam
Member
 
Posts: 4026
Joined: Fri Jul 20, 2012 16:19
GitHub: PilzAdam
IRC: PilzAdam

by PilzAdam » Fri Dec 28, 2012 02:35

Josh wrote:Pilzadam's quest
-------------------------------------------------------------------------------------------------------------------------------------------------------------
Salutation's sir Pilzadam the noble king of minetest challeges you to make a Realistic-looking chest like you see in dungeons and other similar places. It's look can be 3D shaped, size is your choice and it has to open. Succeed in your quest and you will receive a mese cookie.
-------------------------------------------------------------------------------------------------------------------------------------------------------------
P.S: You don't have to make this, but it would be intresting :)

The nodeboxes for the opened and the closed state are easy to do but there are two problems:
1.: The animation to open the chest isnt possible.
2.: There are no callbacks in the API to register when a chest is opened/closed.
 

User avatar
Chinchow
Member
 
Posts: 683
Joined: Tue Sep 18, 2012 21:37

by Chinchow » Fri Dec 28, 2012 02:35

How about a teslacoil one that would emit lightning around it and shock the player it touches and it could be harvested with lightning rods and crafted into useful things
Sometimes, it's harder to think up a mod than it is to create it.
Mods: Orichalcum Stonebricks Extra Chests
 

Josh
Member
 
Posts: 1146
Joined: Fri Jun 29, 2012 23:11

by Josh » Fri Dec 28, 2012 02:57

PilzAdam wrote:
Josh wrote:Pilzadam's quest
-------------------------------------------------------------------------------------------------------------------------------------------------------------
Salutation's sir Pilzadam the noble king of minetest challeges you to make a Realistic-looking chest like you see in dungeons and other similar places. It's look can be 3D shaped, size is your choice and it has to open. Succeed in your quest and you will receive a mese cookie.
-------------------------------------------------------------------------------------------------------------------------------------------------------------
P.S: You don't have to make this, but it would be intresting :)

The nodeboxes for the opened and the closed state are easy to do but there are two problems:
1.: The animation to open the chest isnt possible.
2.: There are no callbacks in the API to register when a chest is opened/closed.

Oh, well it's....impossible :(
 

User avatar
kaeza
Member
 
Posts: 2141
Joined: Thu Oct 18, 2012 05:00
GitHub: kaeza
IRC: kaeza diemartin blaaaaargh
In-game: kaeza

by kaeza » Fri Dec 28, 2012 03:54

Josh wrote:
PilzAdam wrote:
Josh wrote:Pilzadam's quest
-------------------------------------------------------------------------------------------------------------------------------------------------------------
Salutation's sir Pilzadam the noble king of minetest challeges you to make a Realistic-looking chest like you see in dungeons and other similar places. It's look can be 3D shaped, size is your choice and it has to open. Succeed in your quest and you will receive a mese cookie.
-------------------------------------------------------------------------------------------------------------------------------------------------------------
P.S: You don't have to make this, but it would be intresting :)

The nodeboxes for the opened and the closed state are easy to do but there are two problems:
1.: The animation to open the chest isnt possible.
2.: There are no callbacks in the API to register when a chest is opened/closed.

Oh, well it's....impossible :(

It *may* be possible (theoretically, haven't tested it).
First you make two nodes: a closed chest, and an open chest. Then, you make it so punching the node switches the node (i.e: changes the open one to the closed one and viceversa), and you only define right-clicking for the "open" chest.
EDIT: I may do it if someone makes the nodebox for me.
EDIT2: BTW, yes, the animation may also be possible using some clever way, like how falling nodes and mesecons movestones are implemented.
Last edited by kaeza on Fri Dec 28, 2012 04:01, edited 1 time in total.
Your signature is not the place for a blog post. Please keep it as concise as possible. Thank you!

Check out my stuff! | Donations greatly appreciated! PayPal | BTC: 1DFZAa5VtNG7Levux4oP6BuUzr1e83pJK2
 

User avatar
Zeg9
Member
 
Posts: 608
Joined: Fri Sep 21, 2012 11:02

by Zeg9 » Fri Dec 28, 2012 09:50

kaeza wrote:
Josh wrote:
PilzAdam wrote:The nodeboxes for the opened and the closed state are easy to do but there are two problems:
1.: The animation to open the chest isnt possible.
2.: There are no callbacks in the API to register when a chest is opened/closed.

Oh, well it's....impossible :(

It *may* be possible (theoretically, haven't tested it).
First you make two nodes: a closed chest, and an open chest. Then, you make it so punching the node switches the node (i.e: changes the open one to the closed one and viceversa), and you only define right-clicking for the "open" chest.
EDIT: I may do it if someone makes the nodebox for me.
EDIT2: BTW, yes, the animation may also be possible using some clever way, like how falling nodes and mesecons movestones are implemented.


Animation is possible with the new models code and an entity. I may do this part...
I made a few (a lot of?) mods for minetest: here is a list.
See also the MT-Faithful texture pack (work in progress).
 

User avatar
Chinchow
Member
 
Posts: 683
Joined: Tue Sep 18, 2012 21:37

by Chinchow » Fri Dec 28, 2012 19:57

OK I'm gonna suggest a mod that I was gonna make and just wanted more ideas to add to it but it got closed because someone mistook it for a request so now it is I want a mod that adds more liquids other than water and lava
Sometimes, it's harder to think up a mod than it is to create it.
Mods: Orichalcum Stonebricks Extra Chests
 

User avatar
jojoa1997
Member
 
Posts: 2890
Joined: Thu Dec 13, 2012 05:11

by jojoa1997 » Fri Dec 28, 2012 20:14

liquid that floats
Coding;
1X coding
3X debugging
12X tweaking to be just right
 

Ragnar
Member
 
Posts: 850
Joined: Thu Oct 25, 2012 15:19

by Ragnar » Fri Dec 28, 2012 21:36

@doggy i could make an expansion pack for my mod with new liquids, that you can tweak to make a new mod maybe =)
Are you saying that I put an abnormal brain into a seven and a half foot long, fifty-four inch wide GORILLA?
 

User avatar
Chinchow
Member
 
Posts: 683
Joined: Tue Sep 18, 2012 21:37

by Chinchow » Fri Dec 28, 2012 22:30

Ragnar wrote:@doggy i could make an expansion pack for my mod with new liquids, that you can tweak to make a new mod maybe =)

1. Am I doggy or is everyone doggy cause if everyone is doggy @doggy would be hard to understand

2.go ahead looking forward to it
Sometimes, it's harder to think up a mod than it is to create it.
Mods: Orichalcum Stonebricks Extra Chests
 

Ragnar
Member
 
Posts: 850
Joined: Thu Oct 25, 2012 15:19

by Ragnar » Sat Dec 29, 2012 05:51

i reconize you, but i never was good with remembering names... and youre doggy =)
Are you saying that I put an abnormal brain into a seven and a half foot long, fifty-four inch wide GORILLA?
 

User avatar
cactuz_pl
Member
 
Posts: 874
Joined: Tue Jun 05, 2012 16:34

by cactuz_pl » Sat Dec 29, 2012 09:15

Ban which works even when player is offline, and when he trying to connect server is adding his IP to banlist.

Edit:

Command will add name to "future ban list". Server could compare logged player's name with this list and ban if name match to the list.
Last edited by cactuz_pl on Sat Dec 29, 2012 11:55, edited 1 time in total.
Nope
 

User avatar
PilzAdam
Member
 
Posts: 4026
Joined: Fri Jul 20, 2012 16:19
GitHub: PilzAdam
IRC: PilzAdam

by PilzAdam » Sat Dec 29, 2012 12:40

cactuz_pl wrote:Ban which works even when player is offline, and when he trying to connect server is adding his IP to banlist.

Edit:

Command will add name to "future ban list". Server could compare logged player's name with this list and ban if name match to the list.

This is untested code:
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
future_ban_list = {}

minetest.register_chatcommand("future_ban", {
    params = "<playername> | leave playername out to see the future ban list",
    description = "The player will be banned when trying to join",
    privs = {ban=true},
    func = function(name, param)
        if param == "" then
            minetest.chat_send_player(name, "Future ban list: " .. dump(future_ban_list))
            return
        end
        if not minetest.env:get_player_by_name(param) then
            table.insert(future_ban_list, param)
            minetest.chat_send_player(name, desc .. " to future ban list added.")
            minetest.log("action", name .. " added " .. desc .. " to future ban list.")
            return
        end
        if not minetest.ban_player(param) then
            table.insert(future_ban_list, param)
            minetest.chat_send_player(name, desc .. " to future ban list added.")
            minetest.log("action", name .. " added " .. desc .. " to future ban list.")
        else
            local desc = minetest.get_ban_description(param)
            minetest.chat_send_player(name, "Banned " .. desc .. ".")
            minetest.log("action", name .. " bans " .. desc .. ".")
        end
    end
})

minetest.register_on_joinplayer(function(player)
    local name = player:get_player_name()
    for _,n in ipairs(future_ban_list) do
        if n == name then
            if not minetest.ban_player(name) then
                minetest.chat_send_player(name, "Failed to ban player " .. name .. " (from future ban list).")
            else
                local desc = minetest.get_ban_description(name)
                minetest.log("action", desc .. " banned (from future ban list).")
            end
        end
    end
end)

 

TheMan
 

by TheMan » Sat Dec 29, 2012 14:09

HOW ABOUT A [FORCEFIELD]

*Made of cery clear undestructible glass.
*It can reduce griefing.






COULD THIS BE DONE?
 

User avatar
Chinchow
Member
 
Posts: 683
Joined: Tue Sep 18, 2012 21:37

by Chinchow » Sat Dec 29, 2012 15:32

TheMan wrote:HOW ABOUT A [FORCEFIELD]

*Made of cery clear undestructible glass.
*It can reduce griefing.






COULD THIS BE DONE?

Isn't that just making a new glass with a 0 in the area that determines durability?
Sometimes, it's harder to think up a mod than it is to create it.
Mods: Orichalcum Stonebricks Extra Chests
 

User avatar
kaeza
Member
 
Posts: 2141
Joined: Thu Oct 18, 2012 05:00
GitHub: kaeza
IRC: kaeza diemartin blaaaaargh
In-game: kaeza

by kaeza » Sat Dec 29, 2012 15:42

TheMan wrote:HOW ABOUT A [FORCEFIELD]

*Made of cery clear undestructible glass.
*It can reduce griefing.






COULD THIS BE DONE?

That has already been done. See this topic, in particular the "full clip".
Your signature is not the place for a blog post. Please keep it as concise as possible. Thank you!

Check out my stuff! | Donations greatly appreciated! PayPal | BTC: 1DFZAa5VtNG7Levux4oP6BuUzr1e83pJK2
 

User avatar
cactuz_pl
Member
 
Posts: 874
Joined: Tue Jun 05, 2012 16:34

by cactuz_pl » Sun Dec 30, 2012 08:36

PilzAdam wrote:This is untested code:
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
future_ban_list = {}

minetest.register_chatcommand("future_ban", {
    params = "<playername> | leave playername out to see the future ban list",
    description = "The player will be banned when trying to join",
    privs = {ban=true},
    func = function(name, param)
        if param == "" then
            minetest.chat_send_player(name, "Future ban list: " .. dump(future_ban_list))
            return
        end
        if not minetest.env:get_player_by_name(param) then
            table.insert(future_ban_list, param)
            minetest.chat_send_player(name, desc .. " to future ban list added.")  <----LUA ERROR
            minetest.log("action", name .. " added " .. desc .. " to future ban list.")  <---- LUAERROR

            return
        end
        if not minetest.ban_player(param) then
            table.insert(future_ban_list, param)
            minetest.chat_send_player(name, desc .. " to future ban list added.")
            minetest.log("action", name .. " added " .. desc .. " to future ban list.")
        else
            local desc = minetest.get_ban_description(param)
            minetest.chat_send_player(name, "Banned " .. desc .. ".")
            minetest.log("action", name .. " bans " .. desc .. ".")
        end
    end
})

minetest.register_on_joinplayer(function(player)
    local name = player:get_player_name()
    for _,n in ipairs(future_ban_list) do
        if n == name then
            if not minetest.ban_player(name) then
                minetest.chat_send_player(name, "Failed to ban player " .. name .. " (from future ban list).")
            else
                local desc = minetest.get_ban_description(name)
                minetest.log("action", desc .. " banned (from future ban list).")
            end
        end
    end
end)



Thanks, this code almost works.

There are two errors in 14 and 15 line, I don't know how to fix them so I removed them.

Mod is working(adding to list and banning on join) but when turn off my local server, mod forgets "future_ban_list" (no new files are created).
Nope
 

User avatar
PilzAdam
Member
 
Posts: 4026
Joined: Fri Jul 20, 2012 16:19
GitHub: PilzAdam
IRC: PilzAdam

by PilzAdam » Sun Dec 30, 2012 12:12

cactuz_pl wrote:
PilzAdam wrote:This is untested code:
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
future_ban_list = {}

minetest.register_chatcommand("future_ban", {
    params = "<playername> | leave playername out to see the future ban list",
    description = "The player will be banned when trying to join",
    privs = {ban=true},
    func = function(name, param)
        if param == "" then
            minetest.chat_send_player(name, "Future ban list: " .. dump(future_ban_list))
            return
        end
        if not minetest.env:get_player_by_name(param) then
            table.insert(future_ban_list, param)
            minetest.chat_send_player(name, desc .. " to future ban list added.")  <----LUA ERROR
            minetest.log("action", name .. " added " .. desc .. " to future ban list.")  <---- LUAERROR

            return
        end
        if not minetest.ban_player(param) then
            table.insert(future_ban_list, param)
            minetest.chat_send_player(name, desc .. " to future ban list added.")
            minetest.log("action", name .. " added " .. desc .. " to future ban list.")
        else
            local desc = minetest.get_ban_description(param)
            minetest.chat_send_player(name, "Banned " .. desc .. ".")
            minetest.log("action", name .. " bans " .. desc .. ".")
        end
    end
})

minetest.register_on_joinplayer(function(player)
    local name = player:get_player_name()
    for _,n in ipairs(future_ban_list) do
        if n == name then
            if not minetest.ban_player(name) then
                minetest.chat_send_player(name, "Failed to ban player " .. name .. " (from future ban list).")
            else
                local desc = minetest.get_ban_description(name)
                minetest.log("action", desc .. " banned (from future ban list).")
            end
        end
    end
end)



Thanks, this code almost works.

There are two errors in 14 and 15 line, I don't know how to fix them so I removed them.

Mod is working(adding to list and banning on join) but when turn off my local server, mod forgets "future_ban_list" (no new files are created).

Fixed line 14 and 15 (change desc to param):
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
        if not minetest.env:get_player_by_name(param) then
            table.insert(future_ban_list, param)
            minetest.chat_send_player(name, param .. " to future ban list added.") -- Fixed
            minetest.log("action", name .. " added " .. param .. " to future ban list.") -- Fixed

            return
        end


This version saves the future ban list and also removes players that are banned form the list (again untested):
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
future_ban_list = {}

local file = io.open(minetest.get_worldpath().."/future_banlist.txt")
if file then
    future_ban_list = minetest.deserialize(file:read("*all"))
    file:close()
end

minetest.register_chatcommand("future_ban", {
    params = "<playername> | leave playername out to see the future ban list",
    description = "The player will be banned when trying to join",
    privs = {ban=true},
    func = function(name, param)
        if param == "" then
            minetest.chat_send_player(name, "Future ban list: " .. dump(future_ban_list))
            return
        end
        if not minetest.env:get_player_by_name(param) then
            table.insert(future_ban_list, param)
            minetest.chat_send_player(name, param .. " to future ban list added.")
            minetest.log("action", name .. " added " .. param .. " to future ban list.")
            local file = io.open(minetest.get_worldpath().."/future_banlist.txt")
            if file then
                file:write(minetest.serialize(future_ban_list))
                file:close()
            end

            return
        end
        if not minetest.ban_player(param) then
            table.insert(future_ban_list, param)
            local file = io.open(minetest.get_worldpath().."/future_banlist.txt")
            if file then
                file:write(minetest.serialize(future_ban_list))
                file:close()
            end
            minetest.chat_send_player(name, desc .. " to future ban list added.")
            minetest.log("action", name .. " added " .. desc .. " to future ban list.")
        else
            local desc = minetest.get_ban_description(param)
            minetest.chat_send_player(name, "Banned " .. desc .. ".")
            minetest.log("action", name .. " bans " .. desc .. ".")
        end
    end
})

minetest.register_on_joinplayer(function(player)
    local name = player:get_player_name()
    for i,n in ipairs(future_ban_list) do
        if n == name then
            if not minetest.ban_player(name) then
                minetest.chat_send_player(name, "Failed to ban player " .. name .. " (from future ban list).")
            else
                local desc = minetest.get_ban_description(name)
                minetest.log("action", desc .. " banned (from future ban list).")
                table.remove(future_ban_list, i)
            end
        end
    end
end)
 

User avatar
cactuz_pl
Member
 
Posts: 874
Joined: Tue Jun 05, 2012 16:34

by cactuz_pl » Sun Dec 30, 2012 18:32

Still it doesn't remember list, future_banlist.txt doesn't exist (in world folder). But server starts.

When I created future_banlist.txt in world folder, I can see on server start:

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
Server: error:
...(path to mod folder)/init.lua:49: bad argument #1 to


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_on_joinplayer(function(player)
    local name = player:get_player_name()
    for i,n in ipairs(future_ban_list) do             <------------------------------ 49th line
        if n == name then
            if not minetest.ban_player(name) then
                minetest.chat_send_player(name, "Failed to ban player " .. name .. " (from future ban list).")
            else
                local desc = minetest.get_ban_description(name)
                minetest.log("action", desc .. " banned (from future ban list).")
                table.remove(future_ban_list, i)
            end
        end
    end
end)


Thanks
Last edited by cactuz_pl on Sun Dec 30, 2012 18:36, edited 1 time in total.
Nope
 

PreviousNext

Return to Modding Discussion

Who is online

Users browsing this forum: Google [Bot] and 8 guests

cron