This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- how to add your own textures to the wardrobe; | |
--[[ | |
Make sure your textures are in greyscale, eg, from black to white in 0-255 steps | |
The engine prefers this colour as it is easier to look right once a player has | |
set their colour preferences for a specific piece of clothing. | |
The only non-colourable texture is the mouth, as that either lightly shades the mouth area or |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
minetest.register_entity("wardrobe:dummy", { | |
collisionbox = {-0.35,-0.5,-0.35,0.35,1.2,0.35}, | |
visual = "mesh", | |
mesh = "wardrobe_dummy.x", | |
textures = { | |
"ptextures_transparent.png", | |
--"stm.png^[mask:stm.png^[multiply:#e3c0a3^eyewhite.png^eyepupil.png^[mask:test.png^[multiply:#00ff00", | |
"(stm.png^[multiply:#e3c0a3)^(eyewhite.png)^(eyepupil.png^[multiply:#0055ff)^(sam_plaid.png^[multiply:#64e034)", | |
"ptextures_transparent.png", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
print(string.match(fields.skintone, "[0-9a-fA-F][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]")) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- how to add your own textures to the wardrobe; | |
--[[ | |
Make sure your textures are in greyscale, eg, from black to white in 0-255 steps | |
The engine prefers this colour as it is easier to look right once a player has | |
set their colour preferences for a specific piece of clothing. | |
The only non-colourable texture is the mouth, as that either lightly shades the mouth area or |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
bucket = {} | |
bucket.place = {} -- list of liquids to place | |
bucket.fill = {} -- list of liquids to loop over and set to air | |
bucket.name = {} -- list of bucket names to return after using the empty bucket | |
function bucket.give_filled(user, ltype) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- wardrobe formspec | |
wardrobe = {} | |
wardrobe.player_materials = {} | |
wardrobe.formspec_selections = {} | |
wardrobe.formspec_selections_rgb = {} | |
wardrobe.formspec_selections["singleplayer"] = {1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2017-02-12 14:28:08: ACTION[Server]: singleplayer places node wardrobe:node at (-7,4,3) | |
2017-02-12 14:28:08: ERROR[Main]: ServerError: AsyncErr: ServerThread::run Lua: Runtime error from mod 'wardrobe' in callback item_OnPlace(): ...st-0.4.15\bin\..\games\great_farm\mods\wardrobe\init.lua:86: attempt to concatenate local 'hairrgb' (a nil value) | |
2017-02-12 14:28:08: ERROR[Main]: stack traceback: | |
2017-02-12 14:28:08: ERROR[Main]: ...st-0.4.15\bin\..\games\great_farm\mods\wardrobe\init.lua:86: in function 'formspec_meta' | |
2017-02-12 14:28:08: ERROR[Main]: ...st-0.4.15\bin\..\games\great_farm\mods\wardrobe\init.lua:101: in function 'after_place_node' | |
2017-02-12 14:28:08: ERROR[Main]: ...rda\Desktop\minetest-0.4.15\bin\..\builtin\game\item.lua:304: in function <...rda\Desktop\minetest-0.4.15\bin\..\builtin\game\item.lua:207> | |
2017-02-12 14:28:08: ACTION[Server]: singleplayer leaves game. List of players: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- wardrobe formspec | |
wardrobe = {} | |
wardrobe.player_materials = {} | |
wardrobe.formspec_selections = {} | |
wardrobe.formspec_selections_rgb = {} | |
wardrobe.formspec_selections["singleplayer"] = {1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- wardrobe formspec | |
wardrobe = {} | |
wardrobe.player_materials = {} | |
wardrobe.formspec_selections = {} | |
wardrobe.formspec_selections["singleplayer"] = {1,1,4,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- wardrobe formspec | |
wardrobe = {} | |
wardrobe.player_materials = {} | |
wardrobe.formspec_selections = {} | |
wardrobe.formspec_selections["singleplayer"] = {1,1,3,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1} |