[Mod] Wardrobe [wardrobe]

prestidigitator
Member
 
Posts: 632
Joined: Thu Feb 21, 2013 23:54

[Mod] Wardrobe [wardrobe]

by prestidigitator » Sat Jul 05, 2014 23:52

Note (2014-07-05): Any updates I make to this mod will be announced here, but documentation changes for such updates will be made on its wiki page at http://wiki.minetest.net/Wardrobe

----

This mod provides a very simple way to change the skin on the default charcater mesh. Unlike other skin-changing mods out there, it does not attempt to change the character mesh, does not provide for the old 2D billboard-type character appearance, and does not depend on any kind of inventory extension mods. It also does not rely on running external scripts, downloading skins from a server, or anything of that nature.

Changing skins is done via a new "wardrobe" node, which brings up a form with skin names when you right-click on it (like a chest or furnace). Choosing a skin instantly changes your character's appearance, and this change is kept if you log out (unless the skin is removed from the server, in which case your appearance will revert to the default when you log in).

The list of skins is static and determined when the server starts based on two files: <modsPath>/wardrobe/skins.txt and <worldPath>/skins.txt. Both files have the same syntax (see "Skins File Syntax" below). The simplest way to add a skin is to either drop the image into the <modsPath>/wardrobe/textures directory or add them to a texture pack, then add the simple name of the texture file to one of these skins.txt files.

For convenience, some SVG images have been included with this mod. One ("skinTemplate.svg") shows the exact layout of a Minetest skin for the default character model, and should be useful for creating new skins. This layout is also (mostly?) compatible with Minecraft skins. The others can be used to create higher resolution textures for the wardrobe object, in case you are using a texture pack with resolutions greater than 16x16. Skins too may be higher resolution as long as they have an aspect ratio of 2:1. The author of this mod created a very high resolution version of the default character and it works well (but has not been included to simplify mod licensing).

Screenshots:

Image

Image

Image

Skins File Syntax

A comment line starts with two dashes (like in Lua), but must be the only thing on the line:

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
-- This is a comment and has no effect.


Except for empty lines and comments, each line names a texture (file) and a name, separated by optional whitespace and a colon (:):

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
   texture_file_name.png: My Skin
   skin_other_texture_file_name.png: Other Skin


The first string (e.g. "texture_file_name.png") will be passed to the minetest API just like any other node or item texture. Generally it is simply the whole file name of an image in a mod "texture" directory or texture pack. The second string (e.g. "My Skin") is presented to the player in-world as the name of the texture. If this name is omitted, as in:

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
   texture_file_name.png
   skin_other_texture_file_name.png


Then a name is constructed by removing any ".png" suffix any optional "skin_" or "wardrobe_skin_" prefix, and replacing underscores with spaces. So the above skins would be named "texture file name" and "other texture file name", respectively.

To remove a skin that was added elsewhere (for example, to a remove a skin in a particular world), prepend a minus sign (-) to the line. 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
   -skin_other_texture_file_name.png


would remove the "skin_other_texture_file_name.png" skin no matter where it was specified or what name it was given.

Mod Details

Required Minetest Version: >=0.4.9 (not tested in earlier versions)

Dependencies: default, wool (all included in minetest_game)

Recipies:
  • W - any wood (same kinds you can make a chest from)
  • S - any stick
  • L - any wool

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
wardrobe:
      W S W
      W L W
      W L W


Git Repo: https://github.com/prestidigitator/minetest-mod-wardrobe

Copyright and Licensing

All contents, including source code, documentation, and images, are the original creations of the mod author.

Author: prestidigitator (as registered on forum.minetest.net)
License: WTFPL (all content)

Change History

Version 1.0

  • Released 2014-07-05
  • First working version

Version 1.1

  • Released 2015-04-24
  • Removed farming as a dependency; wool is from wool.
  • Auto-detection of player mesh name (thank you indriApollo).
  • Removed warning caused by access of uninitialized global variale (even though it was just a check for nil).
Last edited by prestidigitator on Fri Apr 24, 2015 21:48, edited 3 times in total.
 

prestidigitator
Member
 
Posts: 632
Joined: Thu Feb 21, 2013 23:54

Re: [Mod] Wardrobe [wardrobe]

by prestidigitator » Sun Jul 06, 2014 00:01

To be clear, the screenshot shows only an example menu as it might appear after you add a bunch of skins. No actual skins are included in (this version of) this mod.
 

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

Re: [Mod] Wardrobe [wardrobe]

by Evergreen » Sun Jul 06, 2014 00:27

This is a very nice way of implementing skin choice. :-)
 

User avatar
Wuzzy
Member
 
Posts: 2161
Joined: Mon Sep 24, 2012 15:01
GitHub: Wuzzy2
IRC: Wuzzy
In-game: Wuzzy

Re: [Mod] Wardrobe [wardrobe]

by Wuzzy » Sun Jul 06, 2014 01:50

Great! I like it. It is a good idea to hide all that complexity in the server and a single node.
Now I just need to find some skins … ;-)
 

prestidigitator
Member
 
Posts: 632
Joined: Thu Feb 21, 2013 23:54

Re: [Mod] Wardrobe [wardrobe]

by prestidigitator » Sun Jul 06, 2014 08:12

I noticed that I listed farming as a dependency, but while farming may be a convenient way to get wool, the actual node definitions are in the wool mod. I've removed wool as a listed dependency here, but it is still in "depends.txt". You can simply remove "farming" from the file if for some reason you use this in a game that doesn't have that mod. The "depends.txt" file will be fixed in any future versions I publish, but I don't think it's important enough to tag on its own.
 

User avatar
Wuzzy
Member
 
Posts: 2161
Joined: Mon Sep 24, 2012 15:01
GitHub: Wuzzy2
IRC: Wuzzy
In-game: Wuzzy

Re: [Mod] Wardrobe [wardrobe]

by Wuzzy » Sun Jul 06, 2014 13:55

I've removed wool as a listed dependency here

Wait, what? You need wool to build a wardrobe …
 

User avatar
Inocudom
Member
 
Posts: 2889
Joined: Sat Sep 29, 2012 01:14
IRC: Inocudom
In-game: Inocudom

Re: [Mod] Wardrobe [wardrobe]

by Inocudom » Sun Jul 06, 2014 16:35

A window that shows previews of the skins would be a good idea.
 

prestidigitator
Member
 
Posts: 632
Joined: Thu Feb 21, 2013 23:54

Re: [Mod] Wardrobe [wardrobe]

by prestidigitator » Sun Jul 06, 2014 19:29

Wuzzy wrote:
I've removed wool as a listed dependency here

Wait, what? You need wool to build a wardrobe …

Yeah. It has lots of costumes in it! See the wardrobe image? Hanging clothes.... ;-)
 

prestidigitator
Member
 
Posts: 632
Joined: Thu Feb 21, 2013 23:54

Re: [Mod] Wardrobe [wardrobe]

by prestidigitator » Sun Jul 06, 2014 19:45

Inocudom wrote:A window that shows previews of the skins would be a good idea.

Yeah, I considered that at first. However, the 2D texture image itself is ugly and doesn't make a good preview, so a decent preview requires one of two things:

  1. The user must supply a preview texture as well as a skin texture, or
  2. A preview must be auto-generated from the skin texture.
The problem with having the user supply a preview texture is that it adds complexity to the configuration, though maybe I could make a preview image optional in a future version (e.g. "textureSpec:previewSpec:imageName"). The problem with auto-generating a preview is that it requires either an external script (which I don't want to do), or generation of a very hacky compound texture. Compound textures do not allow scaling or cropping of layers, so it may not even be possible.

I considered creating an entity that uses the character model to preview the skin in 3D instead, but then I realized with the new 3rd person view, you might as well just put the skin on and see how it looks, then switch to another if you don't like it. I realize that if the texture library gets too big that might not be a good option. Maybe better categorization (e.g. tabs or customizing each wardrobe object to have a different list or remembering which page each player was last on) would help with that....

Above all I just wanted to keep the darned thing simple....
 

dgm5555
Member
 
Posts: 244
Joined: Tue Apr 08, 2014 19:45

Re: [Mod] Wardrobe [wardrobe]

by dgm5555 » Sun Dec 07, 2014 23:26

I've made some modifications to the wardrobe code to enable button images
(and I'm hoping I'm not breaking copyright by showing the images which come from http://www.minecraftskins.net)
The image must be called SKINNAME_btn.png (where SKINNAME is the name of the skin the button correlates to)
Just move it with the original skin.png into the textures directory. The skins.txt file remains unchanged.
Unfortunately currently if you have a skin without a corresponding _btn.png the screen gets cluttered with texture not found messages - my code to check for existance doesn't work for some reason.

Also ignore the restock button, I was thinking it would be nice to be able to restock the wardrobe with all skins in the /textures directory rather than having to manually edit the skins.txt file (unlike @prestidigitator I think this would be a brilliant feature), but it doesn't do anything yet... [see below for a python file to do this semi-automatically]

if you want to make use of the 3 lists you also need 3 other files: skins_favs.txt, skins_recent.txt, skins_all.txt, which will be used to replace the default skins.txt and give a bit more flexibility in having multiple lists.
The toggle favorite button, switches from inactive (toggle) to add (next selected skin will be added to favorites list) to remove (next selected will be removed from favorites)

Image

The following code replaces the current wardrobe.lua, the rest of the wardrobe mod is unchanged
(@prestidigitator feel free to integrate it to the next version if you wish, or ignore it entirely as you noted above you don't really like the idea)

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 FORM_NAME = "wardrobe_wardrobeSkinForm";
local SKIN_BUTTON_SIZE = 2;
local SKIN_BUTTON_SIZE_W = 2.8;
local FORM_X = 15;
local FORM_Y = 10;
local FORM_COLS = math.floor((FORM_X-1)/SKIN_BUTTON_SIZE_W);
local FORM_ROWS = math.floor((FORM_Y-1)/SKIN_BUTTON_SIZE);
local SKINS_PER_PAGE = FORM_COLS*FORM_ROWS;
local curModPath = minetest.get_modpath('wardrobe')
wardrobeSkinFileType=""      -- used to disable sorting of the skin list (for the history)
addtofavorite = ''

local function showForm(player, page)
   local playerName = player:get_player_name();
   if not playerName or playerName == "" then return; end

   local n = #wardrobe.skins;
   if n <= 0 then return; end
   local nPages = math.ceil(n/SKINS_PER_PAGE);

   if not page or page > nPages then page = 1; end
   local pageFirstSlot = SKINS_PER_PAGE*(page-1);   -- the starting slot number for the current page
   local pageLastSlot = math.min(pageFirstSlot+SKINS_PER_PAGE, n);    -- the last slot on the current page (lesser of full page, or last possible slot)

   -- Now set up the form
--   print("Wardrobe: Setting Up Form");
   local fs = "size[15,10]";
--   fs = fs.."label[0,0;Change Into:]";
   -- Loop through the buttons which display the characters
   for curRow = 0, FORM_ROWS do
      for curCol = 1, FORM_COLS do
         curSlot = curRow * FORM_COLS + curCol + pageFirstSlot;
--         print(curSlot);

         if curSlot <= pageLastSlot then   -- don't create more buttons if there are no skins left to populate the form
            local skin = wardrobe.skins[curSlot];
            local skinButton = wardrobe.skins[curSlot]:gsub(".png", "_btn.png");
            local skinName = minetest.formspec_escape(wardrobe.skinNames[skin]);

            -- test for existance of local button texture file (if doesn't exist then use a text button, not an image button
--            local buttonPath = curModPath.."/textures/"..skinButton;
--            print(buttonPath);
--            local f=io.open(buttonPath,"r");
--            if f~=nil then
               local fsButton = "image_button_exit["..((curCol-1)*SKIN_BUTTON_SIZE_W)..","..(curRow*SKIN_BUTTON_SIZE)..";"..SKIN_BUTTON_SIZE_W..","..SKIN_BUTTON_SIZE..";"..skinButton..";s:"..skin..";"..skinName.."]";
--               io.close(f);
--            else
--               local fsButton = "button_exit["..(curCol*SKIN_BUTTON_SIZE-1.5)..","..(curRow*SKIN_BUTTON_SIZE)..";"..SKIN_BUTTON_SIZE..","..SKIN_BUTTON_SIZE..";s:"..skin..";"..skinName.."]";
--            end

            print(fsButton);
            fs = fs..fsButton;
               -- NB "s:skin" is the field name returned by the button. "s" indicates to the on_player_receive_fields function (below) to change player skin
    end
      end
   end
   fs = fs.."label[2,9;Page "..page.."/"..nPages.."]";
   if page > 1 then
      fs = fs.."button[0,9;1,1;n:p"..(page-1)..";prev]";
   end
   if page < nPages then
      fs = fs.."button[4,9;1,1;n:p"..(page+1)..";next]";
   end
   fs = fs.."button[6,8.5;2,1;l:favs;show Favorites]";
   fs = fs.."button[8,8.5;2,1;l:all;show All]";
   fs = fs.."button[10,8.5;2,1;l:recent;show Recent]";
   if addtofavorite == '+' then
      fs = fs.."button[5.5,9.5;3,1;f:remove;add to Favorite]";
   elseif addtofavorite == '-' then
      fs = fs.."button[5.5,9.5;3,1;f:noaction;remove from Favorite]";
   else
      fs = fs.."button[5.5,9.5;3,1;f:add;toggle Favorite]";
   end;

--   print(fs)
   minetest.show_formspec(playerName, FORM_NAME, fs);
end

function file_exists(name)
   local f=io.open(name,"r")
   if f~=nil then io.close(f) return true else return false end
end

minetest.register_on_player_receive_fields(
   function(player, formName, fields)
      if formName ~= FORM_NAME then return; end

      local playerName = player:get_player_name();
      if not playerName or playerName == "" then return; end

      for fieldName in pairs(fields) do
         if #fieldName > 2 then
            local action = string.sub(fieldName, 1, 1);
            local value = string.sub(fieldName, 3);

            if action == "f" then
               if value == "add" then
                  addtofavorite = '+'
               elseif value == "remove" then
                  addtofavorite = '-'
               else
                  addtofavorite = ''
               end;
               showForm(player, 1);
               return;
            elseif action == "n" then
               showForm(player, tonumber(string.sub(value, 2)));
               return;
            elseif action == "l" then   -- switch to another skin list
               local infile = io.open(curModPath..'/skins_'..value..'.txt', "r")
               local instr = infile:read("*a")
               infile:close()

               local outfile = io.open(curModPath..'/skins.txt', "w")
               outfile:write(instr)
               outfile:close()
               wardrobeSkinFileType = value

               wardrobe.storage.loadSkins();
               wardrobe.storage.loadPlayerSkins();

               showForm(player, 1);

               return;
            elseif action == "s" then
               wardrobe.changePlayerSkin(playerName, value);

               -- now save recents list
               -- ideally this should be checked for
               local infile = io.open(curModPath..'/skins_recent.txt', "r")
               local instr = infile:read("*a")
               infile:close()

               instr = instr:gsub(value..'\n', '')   -- remove previous instances of the skin in the list

               -- now overwrite the old file with the new skin then the historical skins
               local outfile = io.open(curModPath..'/skins_recent.txt', "w")
               outfile:write(value..'\n')
               outfile:write(instr)
               outfile:close()

               if addtofavorite == '+' then
                  -- now add the selected skin to the favorites list
                  local outfile = io.open(curModPath..'/skins_favs.txt', "a")
                  outfile:write(value..'\n')
                  outfile:close()
                  addtofavorite = ''
               elseif addtofavorite == '-' then
                  -- now add the selected skin to the favorites list
                  local infile = io.open(curModPath..'/skins_favs.txt', "r")
                  local instr = infile:read("*a")
                  infile:close()

                  instr = instr:gsub(value..'\n', '')   -- remove previous instances of the skin in the list

                  -- now overwrite the old file with the new skin then the historical skins
                  local outfile = io.open(curModPath..'/skins_favs.txt', "w")
                  outfile:write(instr)
                  outfile:close()
                  addtofavorite = ''
               end;

               return;
            end
         end
      end
   end
);


minetest.register_node(
   "wardrobe:wardrobe",
   {
      description = "Wardrobe",
      paramtype2 = "facedir",
      tiles = {
                 "wardrobe_wardrobe_topbottom.png",
                 "wardrobe_wardrobe_topbottom.png",
                 "wardrobe_wardrobe_sides.png",
                 "wardrobe_wardrobe_sides.png",
                 "wardrobe_wardrobe_sides.png",
                 "wardrobe_wardrobe_front.png"
              },
      inventory_image = "wardrobe_wardrobe_front.png",
      sounds = default.node_sound_wood_defaults(),
      groups = { choppy = 3, oddly_breakable_by_hand = 2, flammable = 3 },
      on_rightclick = function(pos, node, player, itemstack, pointedThing)
         showForm(player, 1);
      end
   }
);

minetest.register_craft(
   {
      output = "wardrobe:wardrobe",
      recipe = { { "group:wood", "group:stick", "group:wood" },
                 { "group:wood", "group:wool",  "group:wood" },
                 { "group:wood", "group:wool",  "group:wood" } }
   }
);
Last edited by dgm5555 on Thu Dec 11, 2014 23:17, edited 5 times in total.
 

User avatar
fireuser
Member
 
Posts: 21
Joined: Wed Jul 02, 2014 21:05

Re: [Mod] Wardrobe [wardrobe]

by fireuser » Mon Dec 08, 2014 02:51

The mod is decent. I don't see much of a difference there is between this skin changer and other skin changers. (except the skins) If there is some special feature, could you make it more clear? Aside from that, it is good enough as it is. Keep up the good work! : )
 

dgm5555
Member
 
Posts: 244
Joined: Tue Apr 08, 2014 19:45

Re: [Mod] Wardrobe [wardrobe]

by dgm5555 » Thu Dec 11, 2014 10:03

I've got a python script to download skins from a website, but can't figure out how to target the various skins in the open-minetest skin database.
If anyone can help, here's my code (which works for the 400 or so skins on the more simple minecraftskins.net).
Save the following code as (eg) scrapeSkins.py and run it from the wardrobe textures directory.
It downloads the skins and the buttons, and automatically lists them to skins_all.txt (which can be renamed to skins.txt to be automatically loaded and shown by wardrobe).
BTW does anyone know why the mouse recentres on the wardrobe form when it's redrawn? [figured this out, it's behaviour of the button_exit]

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
import urllib2
import re

#connect to a URL
rooturl = "http://www.minecraftskins.net/"
category = ['movies', 'tv', 'games', 'people', 'fantasy', 'mobs', 'other']

#http://www.minecraftskins.net/category/other
#http://www.minecraftskins.net/category/other/2
#http://www.minecraftskins.net/category/other/3



#http://www.minecraftskins.net/toothless         - 'overview' page
#http://www.minecraftskins.net/static/preview/toothless.png   - preview image
#www.minecraftskins.net/toothless/download         - model texture



allskins = open('skins_all.txt','wb')

for cats in range(0, len(category)):
   # step through all categories and up to (10) subpages
   for pages in range(1,10):
      url = 'http://www.minecraftskins.net/category/'+ category[cats]
      if pages > 1:
         url = url+ str(pages)
      try:
         website = urllib2.urlopen(url)

         #read html code
         html = website.read()

         #use re.findall to get all the links
         #links = re.findall('"((http|ftp)s?://.*?)"', html)
         #<a href="/starlord">

         links = re.findall(r'href="/(.*?)">', html)

         for i in range(0, len(links)):
            links[i] = re.findall('^([\w]+)',links[i])

         #   print links
         #   print links[15][0]


            try:
               print rooturl+ links[i][0]+ '/download'
               skinfile = urllib2.urlopen(rooturl+ links[i][0]+ '/download')
               output = open(links[i][0]+'.png','wb')
               output.write(skinfile.read())
               output.close()

               print rooturl+ 'static/preview/'+ links[i][0]+ '.png'
               btnfile = urllib2.urlopen(rooturl+ 'static/preview/'+ links[i][0]+ '.png')
               output = open(links[i][0]+'_btn.png','wb')
               output.write(btnfile.read())
               output.close()

               allskins.write(links[i][0]+ '.png'+ '\n')
            except:
               pass
      except:
         pass

allskins.close()
 

dgm5555
Member
 
Posts: 244
Joined: Tue Apr 08, 2014 19:45

Re: [Mod] Wardrobe [wardrobe]

by dgm5555 » Thu Dec 11, 2014 23:15

I've just edited it a bit more to include storing favorites (from the form rather than having to edit the .txt file) and history of recent skins. Updated the code in my above post https://forum.minetest.net/viewtopic.php?p=163872#p163872
 

User avatar
Don
Member
 
Posts: 1641
Joined: Sat May 17, 2014 18:40
GitHub: DonBatman
IRC: Batman
In-game: Batman

Re: [Mod] Wardrobe [wardrobe]

by Don » Sat Dec 13, 2014 14:06

I like this mod. The kids will love it for roleplay.
Many of my mods are now a part of Minetest-mods. A place where you know they are maintained!

A list of my mods can be found here
 

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

Re: [Mod] Wardrobe [wardrobe]

by addi » Sat Dec 13, 2014 19:11

@dgm5555
to load the skins from the skin db just check out the api.

Krock has already written an python script for the mod u_skins wich downloads the skins from skin db. You can ask him.

Using skins from minecraftskins.net is maybe a bit problematic, because there is no license given, and so all rights, belongs to the author. you are maybe not alowed to use it.
 

User avatar
Krock
Member
 
Posts: 3598
Joined: Thu Oct 03, 2013 07:48
GitHub: SmallJoker

Re: [Mod] Wardrobe [wardrobe]

by Krock » Sat Dec 13, 2014 19:36

addi wrote:Krock has already written an python script for the mod u_skins wich downloads the skins from skin db. You can ask him.

Using skins from minecraftskins.net is maybe a bit problematic, because there is no license given, and so all rights, belongs to the author. you are maybe not alowed to use it.

I did not write the python script - i only edited the source from dmonty.

Yes. You're only allowed to use those skins when the author allows it.
Newest Win32 builds - Find a mod - All my mods
ALL YOUR DONATION ARE BELONG TO PARAMAT (Please support him and Minetest)
New DuckDuckGo !bang: !mtmod <keyword here>
 

sofar
Member
 
Posts: 781
Joined: Fri Jan 16, 2015 07:31
GitHub: sofar
IRC: sofar
In-game: sofar

Re: [Mod] Wardrobe [wardrobe]

by sofar » Sun Mar 01, 2015 03:09

dgm5555 wrote:I've made some modifications to the wardrobe code to enable button images


Great modification. Could you please consider maintaining a github fork of this project with your changes in it? That would make it easier for people to update if there are changes, and will help you maintain the diff easier as well.
 

sofar
Member
 
Posts: 781
Joined: Fri Jan 16, 2015 07:31
GitHub: sofar
IRC: sofar
In-game: sofar

Re: [Mod] Wardrobe [wardrobe]

by sofar » Sun Mar 01, 2015 18:51

sofar wrote:
dgm5555 wrote:I've made some modifications to the wardrobe code to enable button images


Great modification. Could you please consider maintaining a github fork of this project with your changes in it? That would make it easier for people to update if there are changes, and will help you maintain the diff easier as well.


On closer examination, I'm seeing that the skins constantly reset to default. Any idea what could be causing this? I do have unified_inventory and 3d_armor.

Edit: It seems "wieldview" from 3d_armor causes the model update and reverts the skin back to normal.
 

User avatar
lightonflux
Member
 
Posts: 384
Joined: Mon Nov 11, 2013 07:22
In-game: lof

Re: [Mod] Wardrobe [wardrobe]

by lightonflux » Mon Apr 20, 2015 16:14

One block is a bit small for a wardrobe, it should be possible to make one two blocks high, or maybe even 2x2.

Connected_chests does this to create bigger chests with more storage. The wardrobe doesn't need more storage, but it would look nicer if there were bigger wardrobes with the exact same functionality.

The code
 

User avatar
indriApollo
Member
 
Posts: 144
Joined: Fri Sep 26, 2014 11:34
GitHub: indriApollo
IRC: indriApollo
In-game: SudoAptGetPlay

Re: [Mod] Wardrobe [wardrobe]

by indriApollo » Fri Apr 24, 2015 14:15

I've issued a pull request to make this mod compatible with the latest minetest_game.
 

prestidigitator
Member
 
Posts: 632
Joined: Thu Feb 21, 2013 23:54

Re: [Mod] Wardrobe [wardrobe]

by prestidigitator » Fri Apr 24, 2015 21:50

indriApollo wrote:I've issued a pull request to make this mod compatible with the latest minetest_game.

Merged. Then I changed it to auto-detect the name of the player model. It works in 0.4.12. Hopefully it's working in dev latest too. Please let me know if there are any issues. Thank you indriApollo.

(Released version 1.1; see first post.)
 

User avatar
indriApollo
Member
 
Posts: 144
Joined: Fri Sep 26, 2014 11:34
GitHub: indriApollo
IRC: indriApollo
In-game: SudoAptGetPlay

Re: [Mod] Wardrobe [wardrobe]

by indriApollo » Sat Apr 25, 2015 12:46

I've issued an new pull request . This time it adds support for 3d_armor :)

Ain't it pretty :
Image
 

User avatar
indriApollo
Member
 
Posts: 144
Joined: Fri Sep 26, 2014 11:34
GitHub: indriApollo
IRC: indriApollo
In-game: SudoAptGetPlay

Re: [Mod] Wardrobe [wardrobe]

by indriApollo » Wed Apr 29, 2015 08:50

For those who wish to use the wardrobe mod in combination with the latest 3d_armor, you can use https://github.com/indriApollo/minetest-mod-wardrobe
 

sofar
Member
 
Posts: 781
Joined: Fri Jan 16, 2015 07:31
GitHub: sofar
IRC: sofar
In-game: sofar

Re: [Mod] Wardrobe [wardrobe]

by sofar » Wed Apr 29, 2015 22:05

indriApollo wrote:For those who wish to use the wardrobe mod in combination with the latest 3d_armor, you can use https://github.com/indriApollo/minetest-mod-wardrobe


nice, that's awesome - looking forward to testing this out later today!

(edit) so far, so good!
 

prestidigitator
Member
 
Posts: 632
Joined: Thu Feb 21, 2013 23:54

Re: [Mod] Wardrobe [wardrobe]

by prestidigitator » Thu May 21, 2015 23:16

indriApollo wrote:I've issued an new pull request . This time it adds support for 3d_armor :)

Sorry I didn't see this earlier. Pull request merged. I made some changes to make it a little more generic in terms of integration with other mods. If someone could test whether the newest master branch version still works with 3d_armor and report, I'll tag and release a new version. Thanks IndriApollo!
 

KCoombes
Member
 
Posts: 278
Joined: Thu Jun 11, 2015 23:19
In-game: Knatt or Rudilyn

Re: [Mod] Wardrobe [wardrobe]

by KCoombes » Mon Jun 29, 2015 03:49

Hi - I can report your Wardrobe 1.1 does not work with the 3d Armor-Multiskin at this time. I downloaded both of these mods tonight, as it seemed I might have missed an update in the last month or so. I also have the Skins mod, along with the skin files included in that mod.

debug shown

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
Unified Inventory. inventory size: 1172
Irrlicht log: PNG warning: Unknown iTXt compression type or method
Irrlicht log: PNG warning: Interlace handling should be turned on when using png_read_image
23:38:10: ERROR[main]: generateImage(): Could not load image "small_mithril_ore.png" while building texture
23:38:10: ERROR[main]: generateImage(): Creating a dummy image for "small_mithril_ore.png"
23:38:22: ACTION[ServerThread]: singleplayer [127.0.0.1] joins game.
23:38:22: ACTION[ServerThread]: singleplayer joins game. List of players: singleplayer
23:38:22: WARNING: Assignment to undeclared global "name" inside a function at ...inetest\minetest-0.4.12\bin\..\mods\skins\skins\init.lua:30.
23:38:23: ERROR[main]: generateImage(): Could not load image "character_1.png" while building texture
23:38:23: ERROR[main]: generateImage(): Creating a dummy image for "character_1.png"
23:38:31: ERROR[main]: ServerError: C:\Minetest\minetest-0.4.12\bin\..\mods\wardrobe\init.lua:80: attempt to call method 'update_player_visuals' (a nil value)
23:38:31: ERROR[main]: stack traceback:
23:38:31: ERROR[main]:    C:\Minetest\minetest-0.4.12\bin\..\mods\wardrobe\init.lua:80: in function 'changePlayerSkin'
23:38:31: ERROR[main]:    ...netest\minetest-0.4.12\bin\..\mods\wardrobe/wardrobe.lua:53: in function <...netest\minetest-0.4.12\bin\..\mods\wardrobe/wardrobe.lua:38>
23:38:31: ERROR[main]:    ...inetest\minetest-0.4.12\bin\..\builtin\game\register.lua:341: in function <...inetest\minetest-0.4.12\bin\..\builtin\game\register.lua:329>
 

User avatar
indriApollo
Member
 
Posts: 144
Joined: Fri Sep 26, 2014 11:34
GitHub: indriApollo
IRC: indriApollo
In-game: SudoAptGetPlay

Re: [Mod] Wardrobe [wardrobe]

by indriApollo » Mon Jun 29, 2015 17:18

Did you also install the base 3d_armor mod ?
 

KCoombes
Member
 
Posts: 278
Joined: Thu Jun 11, 2015 23:19
In-game: Knatt or Rudilyn

Re: [Mod] Wardrobe [wardrobe]

by KCoombes » Mon Jun 29, 2015 20:04

Yes, I have the 3d_armor modpack, with 3d_armor, multiskin, shields, technic_armor and wieldview installed.
 

User avatar
indriApollo
Member
 
Posts: 144
Joined: Fri Sep 26, 2014 11:34
GitHub: indriApollo
IRC: indriApollo
In-game: SudoAptGetPlay

Re: [Mod] Wardrobe [wardrobe]

by indriApollo » Tue Jun 30, 2015 10:56

 

KCoombes
Member
 
Posts: 278
Joined: Thu Jun 11, 2015 23:19
In-game: Knatt or Rudilyn

Re: [Mod] Wardrobe [wardrobe]

by KCoombes » Tue Jun 30, 2015 13:41

Nope, unless it's installed differently than other mods.

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
Irrlicht log: Irrlicht Engine version 1.8.1
Irrlicht log: Microsoft Windows XP Professional Service Pack 3 (Build 2600)
Irrlicht log: Using renderer: OpenGL 2.1.7976
Irrlicht log: ATI Radeon X300/X550/X1050 Series: ATI Technologies Inc.
Irrlicht log: OpenGL driver version is 1.2 or better.
Irrlicht log: GLSL version: 1.2
Irrlicht log: Resizing window (800 600)
09:40:03: ERROR[main]: ========== ERROR FROM LUA ===========
09:40:03: ERROR[main]: Failed to load and run script from
09:40:03: ERROR[main]: C:\Minetest\minetest-0.4.12\bin\..\mods\gist8a8669d12b2d2c69400c\init.lua:
09:40:03: ERROR[main]: cannot open C:\Minetest\minetest-0.4.12\bin\..\mods\gist8a8669d12b2d2c69400c\init.lua: No such file or directory
09:40:03: ERROR[main]: ======= END OF ERROR FROM LUA ========
09:40:03: ERROR[main]: Server: Failed to load and run C:\Minetest\minetest-0.4.12\bin\..\mods\gist8a8669d12b2d2c69400c\init.lua
09:40:03: ERROR[main]: ModError: ModError: Failed to load and run C:\Minetest\minetest-0.4.12\bin\..\mods\gist8a8669d12b2d2c69400c\init.lua
 

Next

Return to WIP Mods

Who is online

Users browsing this forum: No registered users and 22 guests

cron