Help with textures: everything is black

DoctorFool
Member
 
Posts: 20
Joined: Sat May 04, 2013 20:49
GitHub: shamoanjac
IRC: shamoanjac
In-game: shamoanjac

Help with textures: everything is black

by DoctorFool » Fri May 10, 2013 01:44

So, I added nodes and an entity to my mod, and when they are placed in the world, they look all dark like there are no colors. Only "color" that is displayed is transparency. In the inventory the nodes look very correctly Images are saved as *.png, all of them look correctly. After changing some code I saw that this line was 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
drawtype = "allfaces",
but of course, removing it made my node not rendering the way I wanted.
Whole function is here:
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("aluminium_stuff:aluminium_scaffold",
    {
        tiles={"aluminium_stuff_aluminium_scaffold.png"},
        groups={snappy=1, choppy=1, oddly_breakable_by_hand=1, flammable=0},
        drawtype = "allfaces",
        climbable=true
    })

and here:
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("aluminium_stuff:aluminium_glass",
    {
        description = "Aluminium glass",
        tiles = {"aluminium_stuff_aluminium_glass.png"},
        drawtype = "glasslike",
        groups={snappy=1, choppy=1, oddly_breakable_by_hand=1, flammable=0}
    }
)

Same problem happens with my elevator entity, whose properties are:
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
local elevator = {
    physical = false,
    collision_box = {2.0, 2.0, 2.0, 0.0, 0.0, 0.0},
    visual = "mesh",
    mesh = "aluminium_stuff_aluminium_elevator.x",
    visual_size = {x=10, y=10},
    textures="aluminium_stuff_aluminium_elevator_metal.png",

    driver = nil,
    velocity = {x=0, y=0, z=0},
    old_pos = nil,
    old_velocity = nil,
    MAX_V = 15,
}

Any idea? Thanks.
Last edited by DoctorFool on Fri May 10, 2013 01:55, edited 1 time in total.
 

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

by PilzAdam » Fri May 10, 2013 09:11

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
paramtype = "light",
 

DoctorFool
Member
 
Posts: 20
Joined: Sat May 04, 2013 20:49
GitHub: shamoanjac
IRC: shamoanjac
In-game: shamoanjac

by DoctorFool » Fri May 10, 2013 18:40

Thanks, it worked, but only with nodes. My entity is still bugging. I made the elevator with Blender, then exported to the DirectX format. Texture was applied and showed on the Blender render, but on Minetest the elevator is just completely black. Texture is on the same folder as .x file, and is referenced in the materials list of the X file.
 


Return to WIP Mods

Who is online

Users browsing this forum: No registered users and 34 guests

cron