Post your modding questions here

lunisol
Member
 
Posts: 18
Joined: Wed Aug 07, 2013 04:45

by lunisol » Fri Aug 09, 2013 06:56

LionsDen wrote:
That looks right to me. Are you using a recent version of minetest? I wonder if mesecons has changes to it that requires the latest git or something. I haven't used mesecons, pipeworks or technic for a while now because my system is just too slow for all of the abms and such.

As far as i know I have the latest version it says minetest-c55 0.4.3 in the credits

edit:
Ah, I just looked and I see that I dont have the latest version, latest build is 0.4.7. But i could have sworn I downloaded it straight from minetest.net just a couple weeks ago

edit again: I just downloaded the lastest version. I feel like such an idiot now, everything seems to work just fine now. thank you so much lionsden! I feel like I should facepalm for my ignorance at forgetting to double check for lastest build.
Last edited by lunisol on Fri Aug 09, 2013 07:08, edited 1 time in total.
[CENTER]Image[/CENTER]
 

User avatar
Zane
Member
 
Posts: 122
Joined: Fri Apr 19, 2013 20:28
In-game: Zane

by Zane » Fri Aug 09, 2013 13:45

hey can somone make a halo mod?
home of a+ent.
note:
hi everyone im Zane and im the
creator of the sunrisetest stories.
and for a bonus im learning BASIC programing language.sunrisetest doesn't exist anymore so im planning to replace the server
replacement's name:new sunrisetest
 

Exilyth
Member
 
Posts: 60
Joined: Sun Jul 28, 2013 18:46

by Exilyth » Fri Aug 09, 2013 16:32

Zane wrote:hey can somone make a halo mod?


Have you tried [slabrealm]? See https://forum.minetest.net/viewtopic.php?id=5686
I'm running 0.4.13 stable with [technic][carts][farming_plus][biome_lib][unified_inventory] and a few other mods.
 

User avatar
addi
Member
 
Posts: 605
Joined: Thu Sep 20, 2012 03:16

by addi » Sat Aug 10, 2013 14:54

a fast question:

what is the counterpart of player:get_player_name() ?

i want to get the playerobject from the playername string.
 

Exilyth
Member
 
Posts: 60
Joined: Sun Jul 28, 2013 18:46

by Exilyth » Sat Aug 10, 2013 15:08

addi wrote:a fast question:

what is the counterpart of player:get_player_name() ?

i want to get the playerobject from the playername string.


http://dev.minetest.net/minetest.get_connected_players gives you a list of players. You'd have to compare the player name with the names of the players in this list.
I'm running 0.4.13 stable with [technic][carts][farming_plus][biome_lib][unified_inventory] and a few other mods.
 

User avatar
stu
Member
 
Posts: 737
Joined: Sat Feb 02, 2013 02:51
GitHub: stujones11

by stu » Sat Aug 10, 2013 15:17

addi wrote:a fast question:

what is the counterpart of player:get_player_name() ?

i want to get the playerobject from the playername string.


See: get_player_by_name() http://dev.minetest.net/EnvRef
 

User avatar
addi
Member
 
Posts: 605
Joined: Thu Sep 20, 2012 03:16

by addi » Sat Aug 10, 2013 15:37

stu wrote:
addi wrote:a fast question:

what is the counterpart of player:get_player_name() ?

i want to get the playerobject from the playername string.


See: get_player_by_name() http://dev.minetest.net/EnvRef


this is what i mean. lot of thanks :)
 

User avatar
philipbenr
Member
 
Posts: 1665
Joined: Fri Jun 14, 2013 01:56
GitHub: philipbenr
IRC: philipbenr
In-game: WisdomFire or philipbenr

by philipbenr » Tue Aug 13, 2013 23:40

how do you have a craftitem heal some hearts?

I know how to satiate health, but not healing.

reason: I am making a complex food mod with over 15 desserts, and 5 drinks and many foods. I am making medicine right now, so I need to know how to restore health.
Last edited by philipbenr on Tue Aug 13, 2013 23:40, edited 1 time in total.
"The Foot is down!"
 

paramat
Member
 
Posts: 2662
Joined: Sun Oct 28, 2012 00:05
GitHub: paramat

by paramat » Wed Aug 14, 2013 00:46

Zane wrote:hey can somone make a halo mod?

Also slabworld mod is a mini-ringworld generator https://forum.minetest.net/viewtopic.php?id=6726
Wow you have a choice of 2!
I rely on donations to help provide an income https://forum.minetest.net/viewtopic.php?f=3&t=14935
 

User avatar
philipbenr
Member
 
Posts: 1665
Joined: Fri Jun 14, 2013 01:56
GitHub: philipbenr
IRC: philipbenr
In-game: WisdomFire or philipbenr

by philipbenr » Wed Aug 14, 2013 03:56

philipbenr wrote:how do you have a craftitem heal some hearts?

I know how to satiate health, but not healing.

reason: I am making a complex food mod with over 15 desserts, and 5 drinks and many foods. I am making medicine right now, so I need to know how to restore health.


scratch that, I want to know how to help hunger.

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
    on_use = minetest.item_eat(5.5),


Isn't that how to satiate hunger? In my game, it recover hearts, not hunger
"The Foot is down!"
 

User avatar
Mossmanikin
Member
 
Posts: 599
Joined: Sun May 19, 2013 16:26

by Mossmanikin » Wed Aug 14, 2013 05:16

philipbenr wrote:I want to know how to help hunger.

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
    on_use = minetest.item_eat(5.5),


Isn't that how to satiate hunger? In my game, it recover hearts, not hunger


AFAIK minetest.item_eat() is only (or at least primarily) about health.
Maybe you should take a closer look at the code of BlockMen's Better HUD (and hunger) mod.

Noob 4 life!
My stuff
 

User avatar
philipbenr
Member
 
Posts: 1665
Joined: Fri Jun 14, 2013 01:56
GitHub: philipbenr
IRC: philipbenr
In-game: WisdomFire or philipbenr

by philipbenr » Wed Aug 14, 2013 18:45

I'll try...
"The Foot is down!"
 

User avatar
CaptainCanti
Member
 
Posts: 29
Joined: Thu Jul 18, 2013 05:31

by CaptainCanti » Tue Aug 20, 2013 01:37

Could someone look at my LUA, and tell me what it's problem is? I can't get the mod to load.

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
-- Blocks

minetest.register_node("coloredwood:white_wood", {
    description = S("White Wood"),
    tiles = {"white_wood.png", "white_wood.png", "white_wood.png", "white_wood.png", "white_wood.png^[transformR90", "white_wood.png^[transformR90"},
    paramtype2 = "facedir",
    groups = {snappy=1,choppy=2,oddly_breakable_by_hand=2,flammable=3},
    sounds = default.node_sound_wood_defaults(),
})

minetest.register_node("coloredwood:black_wood", {
    description = S{"Black Wood"),
    tiles = {"black_wood.png", "black_wood.png", "black_wood.png", "black_wood.png", "black_wood.png^[transformR90", "black_wood.png^[transformR90"},
    paramtype2 = "facedir",
    groups = {snappy=1,choppy=2,oddly_breakable_by_hand=2,flammable=3},
    sounds = default.node_sound_wood_defaults(),
})

minetest.register_node("coloredwood:red_wood", {
    description = S{"Red Wood"),
    tiles = {"red_wood.png", "red_wood.png", "red_wood.png", "red_wood.png", "red_wood.png^[transformR90", "red_wood.png^[transformR90"},
    paramtype2 = "facedir",
    groups = {snappy=1,choppy=2,oddly_breakable_by_hand=2,flammable=3},
    sounds = default.node_sound_wood_defaults(),
})
I may seem like an asshole, but that's only because I'm an asshole. :^)

Shit you probs don't care about.
 

User avatar
Evergreen
Member
 
Posts: 2131
Joined: Sun Jan 06, 2013 01:22
GitHub: 4Evergreen4
IRC: EvergreenTree
In-game: Evergreen

by Evergreen » Tue Aug 20, 2013 02:05

CaptainCanti wrote:Could someone look at my LUA, and tell me what it's problem is? I can't get the mod to load.

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
-- Blocks

minetest.register_node("coloredwood:white_wood", {
    description = S("White Wood"),
    tiles = {"white_wood.png", "white_wood.png", "white_wood.png", "white_wood.png", "white_wood.png^[transformR90", "white_wood.png^[transformR90"},
    paramtype2 = "facedir",
    groups = {snappy=1,choppy=2,oddly_breakable_by_hand=2,flammable=3},
    sounds = default.node_sound_wood_defaults(),
})

minetest.register_node("coloredwood:black_wood", {
    description = S{"Black Wood"),
    tiles = {"black_wood.png", "black_wood.png", "black_wood.png", "black_wood.png", "black_wood.png^[transformR90", "black_wood.png^[transformR90"},
    paramtype2 = "facedir",
    groups = {snappy=1,choppy=2,oddly_breakable_by_hand=2,flammable=3},
    sounds = default.node_sound_wood_defaults(),
})

minetest.register_node("coloredwood:red_wood", {
    description = S{"Red Wood"),
    tiles = {"red_wood.png", "red_wood.png", "red_wood.png", "red_wood.png", "red_wood.png^[transformR90", "red_wood.png^[transformR90"},
    paramtype2 = "facedir",
    groups = {snappy=1,choppy=2,oddly_breakable_by_hand=2,flammable=3},
    sounds = default.node_sound_wood_defaults(),
})
Someone actually made a colored wood mod already, but I don't have time atm to check the code.
"Help! I searched for a mod but I couldn't find it!"
http://krock-works.16mb.com/MTstuff/modSearch.php
 

User avatar
Mossmanikin
Member
 
Posts: 599
Joined: Sun May 19, 2013 16:26

by Mossmanikin » Tue Aug 20, 2013 02:16

CaptainCanti wrote:Could someone look at my LUA, and tell me what it's problem is? I can't get the mod to load.

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
-- Blocks

minetest.register_node("coloredwood:white_wood", {
    description = S("White Wood"),
    tiles = {"white_wood.png", "white_wood.png", "white_wood.png", "white_wood.png", "white_wood.png^[transformR90", "white_wood.png^[transformR90"},
    paramtype2 = "facedir",
    groups = {snappy=1,choppy=2,oddly_breakable_by_hand=2,flammable=3},
    sounds = default.node_sound_wood_defaults(),
})

minetest.register_node("coloredwood:black_wood", {
    description = S{"Black Wood"),
    tiles = {"black_wood.png", "black_wood.png", "black_wood.png", "black_wood.png", "black_wood.png^[transformR90", "black_wood.png^[transformR90"},
    paramtype2 = "facedir",
    groups = {snappy=1,choppy=2,oddly_breakable_by_hand=2,flammable=3},
    sounds = default.node_sound_wood_defaults(),
})

minetest.register_node("coloredwood:red_wood", {
    description = S{"Red Wood"),
    tiles = {"red_wood.png", "red_wood.png", "red_wood.png", "red_wood.png", "red_wood.png^[transformR90", "red_wood.png^[transformR90"},
    paramtype2 = "facedir",
    groups = {snappy=1,choppy=2,oddly_breakable_by_hand=2,flammable=3},
    sounds = default.node_sound_wood_defaults(),
})


Looks like there's something wrong with the descriptions.
A simple string should do it in this case, for example:
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
description = "White Wood",

Noob 4 life!
My stuff
 

User avatar
Dan Duncombe
Member
 
Posts: 904
Joined: Thu May 09, 2013 21:11

by Dan Duncombe » Tue Aug 20, 2013 09:45

CaptainCanti wrote:Could someone look at my LUA, and tell me what it's problem is? I can't get the mod to load.

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
-- Blocks

minetest.register_node("coloredwood:white_wood", {
    description = S("White Wood"),
    tiles = {"white_wood.png", "white_wood.png", "white_wood.png", "white_wood.png", "white_wood.png^[transformR90", "white_wood.png^[transformR90"},
    paramtype2 = "facedir",
    groups = {snappy=1,choppy=2,oddly_breakable_by_hand=2,flammable=3},
    sounds = default.node_sound_wood_defaults(),
})

minetest.register_node("coloredwood:black_wood", {
    description = S{"Black Wood"),
    tiles = {"black_wood.png", "black_wood.png", "black_wood.png", "black_wood.png", "black_wood.png^[transformR90", "black_wood.png^[transformR90"},
    paramtype2 = "facedir",
    groups = {snappy=1,choppy=2,oddly_breakable_by_hand=2,flammable=3},
    sounds = default.node_sound_wood_defaults(),
})

minetest.register_node("coloredwood:red_wood", {
    description = S{"Red Wood"),
    tiles = {"red_wood.png", "red_wood.png", "red_wood.png", "red_wood.png", "red_wood.png^[transformR90", "red_wood.png^[transformR90"},
    paramtype2 = "facedir",
    groups = {snappy=1,choppy=2,oddly_breakable_by_hand=2,flammable=3},
    sounds = default.node_sound_wood_defaults(),
})


Have you added 'default' to the depends.txt? It won't work if not.
Some Mods: Castles Prefab Camouflage
My Games: Nostalgia Realtest Revamped
Servers: See above games.
 

User avatar
webdesigner97
Member
 
Posts: 1307
Joined: Mon Jul 30, 2012 19:16
GitHub: webD97
IRC: webdesigner97
In-game: webdesigner97

by webdesigner97 » Tue Aug 20, 2013 19:59

No, this is the problem:

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
 description = S{"Red Wood"),


It has to be:

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
 description = S("Red Wood"),


Edit: replace the { after S with (
Last edited by webdesigner97 on Tue Aug 20, 2013 20:00, edited 1 time in total.
 

User avatar
philipbenr
Member
 
Posts: 1665
Joined: Fri Jun 14, 2013 01:56
GitHub: philipbenr
IRC: philipbenr
In-game: WisdomFire or philipbenr

by philipbenr » Wed Aug 21, 2013 17:00

Mossmanikin wrote:
philipbenr wrote:I want to know how to help hunger.

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
    on_use = minetest.item_eat(5.5),


Isn't that how to satiate hunger? In my game, it recover hearts, not hunger


AFAIK minetest.item_eat() is only (or at least primarily) about health.
Maybe you should take a closer look at the code of BlockMen's Better HUD (and hunger) mod.


Well, I did and I can't find anything... I copied the hunger points out of Pilz-Adam's farming mod from his bread.
"The Foot is down!"
 

EllisGL
New member
 
Posts: 1
Joined: Wed Aug 21, 2013 18:05

by EllisGL » Wed Aug 21, 2013 18:08

Hey all,

Probably a stupid question, but how do you use cURL in mods? I have a cURL enabled build, tried the docs for LUA_cURL, but to no avail.
 

User avatar
Likwid H-Craft
Member
 
Posts: 1113
Joined: Sun Jan 06, 2013 14:20

by Likwid H-Craft » Thu Aug 22, 2013 23:19

What would I, do make the nodebox size, same like Minecraft Heads?

I keep ending up with odd, sizes.
My Domain's/others:
http://likwidtest.hj.cx/ (Not Done)
 

User avatar
Gambit
Member
 
Posts: 452
Joined: Sat Oct 29, 2011 19:31

by Gambit » Fri Aug 23, 2013 21:27

I've been playing with the idea of cobwebs spawning in caves that could drop string. However, I've been wondering how to regulate the amount it spawns in an area. During testing I've come across too many (I feel) and was wondering how to make them less common. Any suggestions?

Here's my small 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
minetest.register_node("test:webspawn", {
    description = "Cobweb",
    drawtype = "plantlike",
    tiles = {"test_web.png"},
    inventory_image = "test_web.png",
    buildable_to = true,
    visual_scale = 1.0,
    paramtype = "light",
    walkable = false,
    groups = {snappy=2,dig_immediate=3,flammable=2,attached_node=1},
    drop = 'farming:string',
})

minetest.register_ore({
    ore_type       = "scatter",
    ore            = "test:webspawn",
    clust_scarcity = 9*9*9,
    clust_num_ores = 4,
    clust_size     = 3,
    height_min     = -630000,
    height_max     = -16,
})
Last edited by Gambit on Fri Aug 23, 2013 21:28, edited 1 time in total.
Current Projects: MineToon | PixelBOX
Gambit's Checkmate Server - 43.65.296.232 - port: 30001
 

User avatar
Evergreen
Member
 
Posts: 2131
Joined: Sun Jan 06, 2013 01:22
GitHub: 4Evergreen4
IRC: EvergreenTree
In-game: Evergreen

by Evergreen » Fri Aug 23, 2013 21:54

Gambit wrote:I've been playing with the idea of cobwebs spawning in caves that could drop string. However, I've been wondering how to regulate the amount it spawns in an area. During testing I've come across too many (I feel) and was wondering how to make them less common. Any suggestions?

Here's my small 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
minetest.register_node("test:webspawn", {
    description = "Cobweb",
    drawtype = "plantlike",
    tiles = {"test_web.png"},
    inventory_image = "test_web.png",
    buildable_to = true,
    visual_scale = 1.0,
    paramtype = "light",
    walkable = false,
    groups = {snappy=2,dig_immediate=3,flammable=2,attached_node=1},
    drop = 'farming:string',
})

minetest.register_ore({
    ore_type       = "scatter",
    ore            = "test:webspawn",
    clust_scarcity = 9*9*9,
    clust_num_ores = 4,
    clust_size     = 3,
    height_min     = -630000,
    height_max     = -16,
})
I think the way you would do that is just make them rarer. Lower the clust_size, maybe grow the clust_scarcity, stuff like that.
"Help! I searched for a mod but I couldn't find it!"
http://krock-works.16mb.com/MTstuff/modSearch.php
 

User avatar
PenguinDad
Member
 
Posts: 122
Joined: Wed Apr 10, 2013 16:46
GitHub: PenguinDad
IRC: PenguinDad GhostDoge
In-game: PenguinDad

by PenguinDad » Mon Aug 26, 2013 16:15

How do I make a node that has a formspec that is equivalent to the creative inventory?
<Cyndra> Programming properly in C++ feels like putting together a jigsaw puzzle
<Cyndra> where the peices don't fit and the picture doesn't matter.
 

User avatar
ch98
Member
 
Posts: 463
Joined: Wed Jan 02, 2013 06:14

by ch98 » Tue Aug 27, 2013 18:54

Can you change an texture of node in game? Also, can you change texture of an liquid?
Last edited by ch98 on Tue Aug 27, 2013 19:04, edited 1 time in total.
Mudslide mod Click Here
 

User avatar
Evergreen
Member
 
Posts: 2131
Joined: Sun Jan 06, 2013 01:22
GitHub: 4Evergreen4
IRC: EvergreenTree
In-game: Evergreen

by Evergreen » Tue Aug 27, 2013 19:08

ch98 wrote:Can you change an texture of node in game? Also, can you change texture of an liquid?
No, sadly you can't change the texture of a node while in game. (unless it is an animation) And what exactly do you mean by changing the texture of a liquid?
"Help! I searched for a mod but I couldn't find it!"
http://krock-works.16mb.com/MTstuff/modSearch.php
 

User avatar
ch98
Member
 
Posts: 463
Joined: Wed Jan 02, 2013 06:14

by ch98 » Tue Aug 27, 2013 19:36

Evergreen wrote:
ch98 wrote:Can you change an texture of node in game? Also, can you change texture of an liquid?
No, sadly you can't change the texture of a node while in game. (unless it is an animation) And what exactly do you mean by changing the texture of a liquid?

example is to make lava suddenly look like water. Also, I want to know if it is possible to add/remove very small amount of liquid, and make, read, and write text files on world folder.
Last edited by ch98 on Wed Aug 28, 2013 05:11, edited 1 time in total.
Mudslide mod Click Here
 

playzooki
Member
 
Posts: 232
Joined: Wed Oct 24, 2012 18:58

by playzooki » Sun Sep 01, 2013 19:41

help please

wont load

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
dofile(minetest.get_modpath("default").."/functions.lua")

minetest.register_node("rickroll:rickroll", {
    description = "You just got Rickrolled!",
    tiles = {"rickroll.png"},
    is_ground_content = true,
    groups = {hot=3, cracky=2},
    drop = 'rickroll:rickroll',
    legacy_mineral = true,
    sounds = default.node_sound_rick_defaults(),
    walkable = false,
    damage_per_second = 8*2
})
bad signature is bad
 

User avatar
Dan Duncombe
Member
 
Posts: 904
Joined: Thu May 09, 2013 21:11

by Dan Duncombe » Sun Sep 01, 2013 19:43

playzooki wrote:help please

wont load

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
dofile(minetest.get_modpath("default").."/functions.lua")

minetest.register_node("rickroll:rickroll", {
    description = "You just got Rickrolled!",
    tiles = {"rickroll.png"},
    is_ground_content = true,
    groups = {hot=3, cracky=2},
    drop = 'rickroll:rickroll',
    legacy_mineral = true,
    sounds = default.node_sound_rick_defaults(),
    walkable = false,
    damage_per_second = 8*2
})


Try adding a comma after damage_per_second = 8*2
Some Mods: Castles Prefab Camouflage
My Games: Nostalgia Realtest Revamped
Servers: See above games.
 

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

by kaeza » Sun Sep 01, 2013 19:47

playzooki wrote:sounds = default.node_sound_rick_defaults(),

This line is wrong. There's no function with that name.
You probably want one of those:
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
default.node_sound_wood_defaults(),
default.node_sound_grass_defaults(),
default.node_sound_glass_defaults(),
default.node_sound_stone_defaults(),
default.node_sound_dirt_defaults(),
default.node_sound_leaves_defaults(),
default.node_sound_sand_defaults(),
Last edited by kaeza on Sun Sep 01, 2013 19:50, 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
Dan Duncombe
Member
 
Posts: 904
Joined: Thu May 09, 2013 21:11

by Dan Duncombe » Sun Sep 01, 2013 19:53

kaeza wrote:
playzooki wrote:sounds = default.node_sound_rick_defaults(),

This line is wrong. There's no function with that name.
You probably want one of those:
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
default.node_sound_wood_defaults(),
default.node_sound_grass_defaults(),
default.node_sound_glass_defaults(),
default.node_sound_stone_defaults(),
default.node_sound_dirt_defaults(),
default.node_sound_leaves_defaults(),
default.node_sound_sand_defaults(),

Also, you need default as a dependency to use these
Some Mods: Castles Prefab Camouflage
My Games: Nostalgia Realtest Revamped
Servers: See above games.
 

PreviousNext

Return to Modding Discussion

Who is online

Users browsing this forum: No registered users and 17 guests

cron