[Release] Fred's Wardrobe v1.0.2

i can think of a couple ways to do this. unfortunately i think its a bit outside of freds current ability's (no offense fred), if i get some free time i will see if i can get it to work

I take no offense to that comment. :) It IS outside my current ability. Keep in mind I opened up my first mission file less than a month ago and only started working on my own custom scripts about two weeks ago. :p
 
Great work Fr1nk! If you get the time, could you post a quick tutorial for the changes you made. It may come in handy if other players using 2017 decide to download the addon.

Sure thing, can probably do this within a few days. Note that I haven't tried the changes to make skins persist across login sessions yet, so it would just be a guide for the first half of your instructions.
 
I also notice after skin change you cannot perform the summer sault, only in survivor clothes. i know this isnt your issue but it would be nice to have consistency in each skin change.
 
I use both on my server but I just use the admin tools to switch my skin and let the players use the wardrobe. If you wanted to switch skins through the wardrobe and then have your admin tools option come back up you have to add the following code to the bottom of each of the skin files in the skins folder.

Code:
player addaction [("<t color=""#0074E8"">" + ("Tools Menu") +"</t>"),"admintools\Eexcute.sqf","",5,false,true,"",""];

Here is what i did i took that line and added to the bottom. is this right? now i dont see any menu

Code:
if (dayz_combat == 1) then {
titleText ["You can't change clothes while in combat.", "PLAIN DOWN", 3];
sleep 5;
titleFadeOut 1;
} else {
titleText ["Changing Clothes...", "PLAIN DOWN", 3];
sleep 3;
[dayz_playerUID,dayz_characterID,'US_Soldier_EP1'] spawn player_humanityMorph;
sleep 2;
titleText ["...looking good! Wardrobe closed for 4 hours.", "PLAIN DOWN", 3];
sleep 5;
titleFadeOut 1;
 
 
//im thinking it should go here before the wait timer.
 
 
sleep 14400;
player addaction [("<t color=""#ff8810"">" + ("Wardrobe") +"</t>"),"wardrobe\skins_execute.sqf","",5,false,true,"",""];
};
player addaction [("<t color=""#0074E8"">" + ("Tools Menu") +"</t>"),"admintools\Eexcute.sqf","",5,false,true,"",""];
 
try this
Code:
if (dayz_combat == 1) then {
    titleText ["You can't change clothes while in combat.", "PLAIN DOWN", 3];
    sleep 5;
    titleFadeOut 1;
} else {
    titleText ["Changing Clothes...", "PLAIN DOWN", 3];
    sleep 3;
    [dayz_playerUID,dayz_characterID,'US_Soldier_EP1'] spawn player_humanityMorph;
    sleep 2;
    if ((getPlayerUID player) in ["######","######"]) then {
        player addaction [("<t color=""#0074E8"">" + ("Tools Menu") +"</t>"),"admintools\Eexcute.sqf","",5,false,true,"",""];
    };
    titleText ["...looking good! Wardrobe closed for 4 hours.", "PLAIN DOWN", 3];
    sleep 5;
    titleFadeOut 1;
    sleep 14400;
    player addaction [("<t color=""#ff8810"">" + ("Wardrobe") +"</t>"),"wardrobe\skins_execute.sqf","",5,false,true,"",""];
};
you want the tools menu only for admins and you want it before the skins menu "cooldown" so i have placed the code in the correct location with the UID check
 
I'm getting the following error:

skinsmenu\skins_execute.sqf not found

The file in question is indeed in the right place. I don't know what the deal is. I'm trying to make it to where only Admin's have the option to see and use the wardrobe. I copied and pasted the code Fred said to use, but since then I get this error. I'm attaching my .pbo file. Hopefully someone can help me.
 

Attachments

  • dayz_1.chernarus.pbo
    194.7 KB · Views: 2
I'm getting the following error:

skinsmenu\skins_execute.sqf not found

The file in question is indeed in the right place. I don't know what the deal is. I'm trying to make it to where only Admin's have the option to see and use the wardrobe. I copied and pasted the code Fred said to use, but since then I get this error. I'm attaching my .pbo file. Hopefully someone can help me.

looks like u dont have the file skins_execute.sqf inside of skinsmenu folder which should be on your root mission.
 
try this
Code:
if (dayz_combat == 1) then {
    titleText ["You can't change clothes while in combat.", "PLAIN DOWN", 3];
    sleep 5;
    titleFadeOut 1;
} else {
    titleText ["Changing Clothes...", "PLAIN DOWN", 3];
    sleep 3;
    [dayz_playerUID,dayz_characterID,'US_Soldier_EP1'] spawn player_humanityMorph;
    sleep 2;
    if ((getPlayerUID player) in ["######","######"]) then {
        player addaction [("<t color=""#0074E8"">" + ("Tools Menu") +"</t>"),"admintools\Eexcute.sqf","",5,false,true,"",""];
    };
    titleText ["...looking good! Wardrobe closed for 4 hours.", "PLAIN DOWN", 3];
    sleep 5;
    titleFadeOut 1;
    sleep 14400;
    player addaction [("<t color=""#ff8810"">" + ("Wardrobe") +"</t>"),"wardrobe\skins_execute.sqf","",5,false,true,"",""];
};
you want the tools menu only for admins and you want it before the skins menu "cooldown" so i have placed the code in the correct location with the UID check


Hey thanks for all the help, it works but still after skin change through wardrobe it doesnt show tools menu.

im going to go through admintools skin change and see what its missing.
 
I can confirm when I try to do this:

This would remove the menu from everyone besides admins but the other players would still get the Wardrobe scroll wheel selection. The easiest way to make this for admins only would be to go into your skins_activate.sqf and replace the entire thing with this.
Code:
waituntil {!isnull (finddisplay 46)};
sleep 20;
if ((getPlayerUID player) in ["#########","#########"]) then {
skinsmenu = player addaction [("<t color=""#ff8810"">" + ("Wardrobe") +"</t>"),"skinsmenu\skins_execute.sqf","",5,false,true,"",""];
} else {
player removeAction skinsmenu;
};

Then just enter the unique IDs of your admins where it says "########" separated by commas. You can put as many as you want there. This will make it so only the unique IDs you have specified will even receive the scroll wheel option for "Wardrobe".

I get the error I mentioned. I don't know why.
 
Never mind. I fixed the error.

"skinsmenu\skins_execute.sqf" should of been "wardrobe\skins_execute.sqf".
 
For those of you running DayZ 2017 wanting to use only the 2017 skins for Fred's Wardrobe...

Lots of text below, but it's easy to do and I'm just being over-descriptive. Note: please follow Fred's original install instructions first.

In skins_main.sqf:

1) Find:
Code:
SkinsMenuCustom =
[
    ["",true],
        ["Rocket Uniform", [2],  "", -5, [["expression", format[EXECscript1,"rocket.sqf"]]], "1", "1"],
        ["Desert Rocket Uniform", [3],  "", -5, [["expression", format[EXECscript1,"desert_rocket.sqf"]]], "1", "1"],
        ["Desert Camo Clothing", [4],  "", -5, [["expression", format[EXECscript1,"desert_clothes.sqf"]]], "1", "1"],
        ["Desert Soldier Uniform", [5],  "", -5, [["expression", format[EXECscript1,"desert_soldier.sqf"]]], "1", "1"],
        ["Desert Green Uniform", [6],  "", -5, [["expression", format[EXECscript1,"desert_green_soldier.sqf"]]], "1", "1"],
        ["US Soldier Uniform", [7],  "", -5, [["expression", format[EXECscript1,"us_soldier.sqf"]]], "1", "1"],
        ["Czech Soldier Uniform", [8],  "", -5, [["expression", format[EXECscript1,"czech_soldier.sqf"]]], "1", "1"],
        ["", [-1], "", -5, [["expression", ""]], "1", "0"],
            ["Exit", [13], "", -3, [["expression", ""]], "1", "1"]
];

Replace with:
Code:
SkinsMenuCustom =
[
    ["",true],
        ["Alexej", [2],  "", -5, [["expression", format[EXECscript1,"alexej.sqf"]]], "1", "1"],
        ["Czech Norris", [3],  "", -5, [["expression", format[EXECscript1,"Czech_Norris.sqf"]]], "1", "1"],
        ["Dimitry", [4],  "", -5, [["expression", format[EXECscript1,"dimitry.sqf"]]], "1", "1"],
        ["Epic Beard Man", [5],  "", -5, [["expression", format[EXECscript1,"epic_beard_man.sqf"]]], "1", "1"],
        ["Moldy Marek", [6],  "", -5, [["expression", format[EXECscript1,"Moldy_Marek.sqf"]]], "1", "1"],
        ["Scabby Silvestr", [7],  "", -5, [["expression", format[EXECscript1,"Scabby_Silvestr.sqf"]]], "1", "1"],
        ["Stained Stanislav", [8],  "", -5, [["expression", format[EXECscript1,"Stained_Stanislav.sqf"]]], "1", "1"],
        ["", [-1], "", -5, [["expression", ""]], "1", "0"],
            ["Exit", [13], "", -3, [["expression", ""]], "1", "1"]
];

2) Find:
Code:
SkinsMenuDayZ =
[
    ["",true],
        ["Male Suvivor", [2],  "", -5, [["expression", format[EXECscript1,"survivor_male.sqf"]]], "1", "1"],
        ["Female Suvivor", [3],  "", -5, [["expression", format[EXECscript1,"survivor_female.sqf"]]], "1", "1"],
        ["Male Bandit", [4],  "", -5, [["expression", format[EXECscript1,"bandit_male.sqf"]]], "1", "1"],
        ["Female Bandit", [5],  "", -5, [["expression", format[EXECscript1,"bandit_female.sqf"]]], "1", "1"],
        ["Camo Clothing", [6],  "", -5, [["expression", format[EXECscript1,"camo_clothes.sqf"]]], "1", "1"],
        ["Ghillie Suit", [7],  "", -5, [["expression", format[EXECscript1,"ghille.sqf"]]], "1", "1"],
        ["Soldier Uniform", [8],  "", -5, [["expression", format[EXECscript1,"soldier.sqf"]]], "1", "1"],
        ["", [-1], "", -5, [["expression", ""]], "1", "0"],
            ["Exit", [13], "", -3, [["expression", ""]], "1", "1"]
];

Replace with:
Code:
SkinsMenuDayZ =
[
    ["",true],
        ["Alexej", [2],  "", -5, [["expression", format[EXECscript1,"alexej.sqf"]]], "1", "1"],
        ["Czech Norris", [3],  "", -5, [["expression", format[EXECscript1,"Czech_Norris.sqf"]]], "1", "1"],
        ["Dimitry", [4],  "", -5, [["expression", format[EXECscript1,"dimitry.sqf"]]], "1", "1"],
        ["Epic Beard Man", [5],  "", -5, [["expression", format[EXECscript1,"epic_beard_man.sqf"]]], "1", "1"],
        ["Moldy Marek", [6],  "", -5, [["expression", format[EXECscript1,"Moldy_Marek.sqf"]]], "1", "1"],
        ["Scabby Silvestr", [7],  "", -5, [["expression", format[EXECscript1,"Scabby_Silvestr.sqf"]]], "1", "1"],
        ["Stained Stanislav", [8],  "", -5, [["expression", format[EXECscript1,"Stained_Stanislav.sqf"]]], "1", "1"],
        ["", [-1], "", -5, [["expression", ""]], "1", "0"],
            ["Exit", [13], "", -3, [["expression", ""]], "1", "1"]
];

3) Download the attached "skins.zip"
4) Copy all files within "skins.zip" to the SKINS folder. You can keep or delete the skin files that came with Fred's Wardrobe, depending on if you want to use them later or not.

If you want to try out other custom skins, simply create a new SQF skin file, and copy it to the SKINS directory.

Example:
5) Using a text editor like Notepad++, create a new file called EXAMPLE_SKIN.sqf
6) Paste the following into the file:
Code:
if (dayz_combat == 1) then {
titleText ["You can't change clothes while in combat.", "PLAIN DOWN", 3];
sleep 5;
titleFadeOut 1;
} else {
titleText ["Changing Clothes...", "PLAIN DOWN", 3];
sleep 3;
[dayz_playerUID,dayz_characterID,'EXAMPLE_SKIN'] spawn player_humanityMorph;
sleep 2;
titleText ["...looking good! Wardrobe closed for 1 minute.", "PLAIN DOWN", 3];
sleep 5;
titleFadeOut 1;
sleep 55;
player addaction [("<t color=""#ff8810"">" + ("Wardrobe") +"</t>"),"wardrobe\skins_execute.sqf","",5,false,true,"",""];
};

Note: EXAMPLE_SKIN should be the classname of the skin you're trying to add

7) Now, you'll need to add a new menu line for EXAMPLE_SKIN.

In skins_main.sqf, find:
Code:
SkinsMenuCustom =

A few lines below that, you'll find the last skin in the menu:
Code:
["Stained Stanislav", [8],  "", -5, [["expression", format[EXECscript1,"Stained_Stanislav.sqf"]]], "1", "1"],

On the next line immediately below it, paste this:
Code:
["EXAMPLE_SKIN", [8],  "", -5, [["expression", format[EXECscript1,"EXAMPLE_SKIN.sqf"]]], "1", "1"],

Again, EXAMPLE_SKIN should be the classname of the skin you're trying to add

Repeat steps 5-7 for as many skins as you'd like to add.

NOTE: I did the bare minimum to get this working for 2017 skins, so the DayZ and Custom menus are mirrors of each other right now. Sorry if this was a bit difficult to follow, it's late and I'm about to pass out :p
 

Attachments

  • skins.zip
    3.4 KB · Views: 23
realy good work! But cant get this to work. when i have inserted the script my server wouldnt start. have dayz.st and lingor map
 
realy good work! But cant get this to work. when i have inserted the script my server wouldnt start. have dayz.st and lingor map

Did you edit YOUR init.sqf using the tutorial or did you just put the init.sqf I uploaded in your mission folder?
 
Did you edit YOUR init.sqf using the tutorial or did you just put the init.sqf I uploaded in your mission folder?
i edit the init.sqf file. and follow the tutorial. and checked with your init file after. but the server dont start after that. maybe i have done somthing wrong. but dont know what. because it was like yours after i checked. sorry for bad english ;)
 
i edit the init.sqf file. and follow the tutorial. and checked with your init file after. but the server dont start after that. maybe i have done somthing wrong. but dont know what. because it was like yours after i checked. sorry for bad english ;)

Upload your server and mission files and I will take a look when I get home from work.
 
  • Like
Reactions: ray
i installed your script today...
it works so far...
but i noticed when im changing my clothes my char gets hurt in the process...
im not bleeding or losing blood or something... but the screen flashes red... and he moans like he breaks his legs..
the trousers of my new clothes are also red soaked with blood...

any suggestions on this?
 
i installed your script today...
it works so far...
but i noticed when im changing my clothes my char gets hurt in the process...
im not bleeding or losing blood or something... but the screen flashes red... and he moans like he breaks his legs..
the trousers of my new clothes are also red soaked with blood...

any suggestions on this?

That's a DayZ bug that happens often while changing skins. It isn't anything caused by my addon and I'm not sure if there is a fix for it.
 
yeah i noticed this sometimes before... when changing clothes... but it did not appear for a while now...
nevertheless... nice mod =)
 
Back
Top