[Mod] Deploy Nodes [deploy_nodes] nodes that turn into big structures
-
- Member
- Posts: 844
- Joined: Wed Jul 11, 2012 15:02
-
- Member
- Posts: 844
- Joined: Wed Jul 11, 2012 15:02
-
- Member
- Posts: 844
- Joined: Wed Jul 11, 2012 15:02
It seems the OS detection script I have is not working.
Can you please run a simple test to see the output:
my_mod/init.lua
Can you please run a simple test to see the output:
my_mod/init.lua
Code: Select all
print("HOME is: "..os.getenv('HOME'))
print("home is: "..os.getenv('home'))
same problem on the last opesuse, the os detection apparently works but the popen results unsupported
also the command for linux and mac seems wrong at least on linux it will give file not found, tried it in bash
i've tried also to rebuid minetest from the sources because the standalone lua interpreter supports io.popen so i thinked it could be a problem of the package but it does not change from wat i see it seems to be an engine rather that a mod problem
these are my 2 cents as a noob
also the command for linux and mac seems wrong at least on linux it will give file not found, tried it in bash
i've tried also to rebuid minetest from the sources because the standalone lua interpreter supports io.popen so i thinked it could be a problem of the package but it does not change from wat i see it seems to be an engine rather that a mod problem
these are my 2 cents as a noob
-
- Member
- Posts: 844
- Joined: Wed Jul 11, 2012 15:02
If you are running in linux, and the OS detection works, it should never call io.popen(). Instead it should call os.execute('\ls -a ...... ").
Can you paste the exact command you ran from bash which gave file not found?
Can you paste the exact command you ran from bash which gave file not found?
Last edited by cornernote on Tue Oct 09, 2012 03:18, edited 1 time in total.
here is the code that i have
adding a print instruction for the command i get
ls -a "/home/baltar/MINE/celeron55-minetest-9696ed3/bin/../games/minetest_game/mods/deploy_nodes/deploy_building/buildings/small/*.we"
that returns
ls: impossibile accedere a /home/baltar/MINE/celeron55-minetest-9696ed3/bin/../games/minetest_game/mods/deploy_nodes/deploy_building/buildings/small/*.we: File o directory non esistente
that means cannot access file .... file or directory does not exist
i also have redownloaded it so i think it should be the last version
Code: Select all
-- get_files
deploy_building.get_files = function(size)
local directory = minetest.get_modpath("deploy_building").."/buildings/"..size
local command = 'dir "'..directory..'\\*.we" /b' -- windows
if os.getenv('home')~=nil then
command = 'ls -a "'..directory..'/*.we"' -- linux/mac
end
local i, t, popen = 0, {}, io.popen
for filename in popen(command):lines() do
i = i + 1
t[i] = filename
end
return t
end
ls -a "/home/baltar/MINE/celeron55-minetest-9696ed3/bin/../games/minetest_game/mods/deploy_nodes/deploy_building/buildings/small/*.we"
that returns
ls: impossibile accedere a /home/baltar/MINE/celeron55-minetest-9696ed3/bin/../games/minetest_game/mods/deploy_nodes/deploy_building/buildings/small/*.we: File o directory non esistente
that means cannot access file .... file or directory does not exist
i also have redownloaded it so i think it should be the last version
-
- Member
- Posts: 844
- Joined: Wed Jul 11, 2012 15:02
ok, i am getting mods confused, sec.. i'll fix this now..
Last edited by cornernote on Tue Oct 09, 2012 04:11, edited 1 time in total.
-
- Member
- Posts: 844
- Joined: Wed Jul 11, 2012 15:02
-
- Member
- Posts: 4290
- Joined: Sun Sep 09, 2012 17:31
- GitHub: Sokomine
- IRC: Sokomine
- In-game: Sokomine
Just for the record: The os detection didn't work for me. Lua complained about popen missing. When I had a look at the code it was obvious that the popen part was not relevant for my Debian system. Changing the if-condition to always true (or false - don't remember) and thus disabling os detection solved the issue for me.
A list of my mods can be found here.
- Neuromancer
- Member
- Posts: 964
- Joined: Tue Jun 12, 2012 22:28
- GitHub: Neuromancer56
I had an idea that I thought I'd run by you. What if when you placed a cylinder node, sphere node, etc, that they did nothing, until you placed a block on top of the special node. So if you placed a sand node on top of the pyramid node, it would build a sand pyramid. That way you would only need 1 special node for each shape, and the users could build out of whatever node they wanted, from any mod.
For cylinders, if a cactus node was placed on the right of the cylinder node, a cactus cylinder would be generated to the right. If the brick was placed on top of the cylinder node, a brick cylinder would grow upward. Thus a cylinder could grow in 5 directions.
For cylinders, if a cactus node was placed on the right of the cylinder node, a cactus cylinder would be generated to the right. If the brick was placed on top of the cylinder node, a brick cylinder would grow upward. Thus a cylinder could grow in 5 directions.
Mods:Immersive Sounds
Phonics
Eden Game Natural Beauty Textures
Try out dropbox and get me free space: https://db.tt/JjjTr7fl
Phonics
Eden Game Natural Beauty Textures
Try out dropbox and get me free space: https://db.tt/JjjTr7fl
-
- Member
- Posts: 844
- Joined: Wed Jul 11, 2012 15:02
-
- Member
- Posts: 844
- Joined: Wed Jul 11, 2012 15:02
I think thats a cool idea! Unfortunately I don't have a lot of time upcoming. Feel free to fork my code and have a crack at putting this in.Neuromancer wrote:I had an idea that I thought I'd run by you. What if when you placed a cylinder node, sphere node, etc, that they did nothing, until you placed a block on top of the special node. So if you placed a sand node on top of the pyramid node, it would build a sand pyramid. That way you would only need 1 special node for each shape, and the users could build out of whatever node they wanted, from any mod.
For cylinders, if a cactus node was placed on the right of the cylinder node, a cactus cylinder would be generated to the right. If the brick was placed on top of the cylinder node, a brick cylinder would grow upward. Thus a cylinder could grow in 5 directions.
-
- Member
- Posts: 844
- Joined: Wed Jul 11, 2012 15:02
I tried it out and got it working.
0. You need (one of) the latest minetest builds (0.4.3, celeron55-minetest-25cf375 for example)
1.a Did you put the mod in the right place? I use Lubuntu (Linux) and have minetest installed local. My folder structure looks like this:
/home/TOPYWO/celeron55-minetest-8c3ffa3-test 1/mods/minetest/cornernote-minetest-deploy_nodes-47c2e9b
1.b. Linux system wide and Windows: http://c55.me/minetest/wiki/doku.php?id=installing_mods
2. You do not need to rename cornernote-minetest-deploy_nodes-47c2e9b, because it's a modpack (with a modpack.txt in it).
3. You need PilzAdam's throwing mod in mods/minetest, because deploy nodes depends on it. Rename the folder/directory to throwing. Example: /home/TOPYWO/celeron55-minetest-8c3ffa3-test 1/mods/minetest/throwing
Download the the one under Download http://minetest.net/forum/viewtopic.php?id=2805
4. You also need PilzAdam's farming mod in mods/minetest, because throwing depends on it.. Rename it to farming. Example: /home/TOPYWO/celeron55-minetest-8c3ffa3-test 1/mods/minetest/farming
Download the the one under Download http://minetest.net/forum/viewtopic.php?id=2787
I hope it works.
0. You need (one of) the latest minetest builds (0.4.3, celeron55-minetest-25cf375 for example)
1.a Did you put the mod in the right place? I use Lubuntu (Linux) and have minetest installed local. My folder structure looks like this:
/home/TOPYWO/celeron55-minetest-8c3ffa3-test 1/mods/minetest/cornernote-minetest-deploy_nodes-47c2e9b
1.b. Linux system wide and Windows: http://c55.me/minetest/wiki/doku.php?id=installing_mods
2. You do not need to rename cornernote-minetest-deploy_nodes-47c2e9b, because it's a modpack (with a modpack.txt in it).
3. You need PilzAdam's throwing mod in mods/minetest, because deploy nodes depends on it. Rename the folder/directory to throwing. Example: /home/TOPYWO/celeron55-minetest-8c3ffa3-test 1/mods/minetest/throwing
Download the the one under Download http://minetest.net/forum/viewtopic.php?id=2805
4. You also need PilzAdam's farming mod in mods/minetest, because throwing depends on it.. Rename it to farming. Example: /home/TOPYWO/celeron55-minetest-8c3ffa3-test 1/mods/minetest/farming
Download the the one under Download http://minetest.net/forum/viewtopic.php?id=2787
I hope it works.
Who is online
Users browsing this forum: No registered users and 35 guests