Results 1 to 1 of 1

Thread: WoW Skinning

  1. #1
    Rep Whore

    CoreCoins User

    Rayz's Avatar
    Reputation
    670
    Join Date
    Apr 2007
    Location
    The Matrix
    Posts
    597
    CoreCoins
    1162

    Trade Feedbacks

    Status
    n/a
    Positive
    0 (0%)
    Negative
    0 (0%)

    WoW Skinning



    Donate to Remove Ads, Get ShoutBawx - Elite Forum Access
    World of Warcraft Skinning Info/Tutorial
    Written by Troll Paxton

    Part 1: The Blizzard File System
    Blizzard stores its assets (all the textures, models, sounds, etc) in what they call MPQ files. All of the MPQ files are in the [WoW]\Data directory. [Throughout this I will refer to the WoW directory as [WoW]. If you installed to the default directory, [WoW] = C:\Program Files\World Of Warcraft.] MPQ files have directories, just like hard drives or ZIP files. [Directory is just another word for Folder.] This is important because when WoW goes to load a file, it looks for it within a specific "directory" within an MPQ file.
    Blizzard finds MPQ files handy to use for various reasons, but they have one big drawback. Lets say that in a given patch they just want to change a few files within a big MPQ file. They would have to include the whole MPQ in their patch download, and that is bad because several of these MPQs are very large. So, Bliz came up with a clever system for getting around this problem, which works like this. When WoW goes to load an asset, it first looks in the MPQ it expects it to be in. It then looks for other, patch MPQs with given names, and if it finds them it loads them one by one and searches for the asset in them. If it finds a version of the asset in a patch MPQ it uses it instead of the regular version.
    Patch MPQs are all named "Patch-$.mpq", where $ is a number 1-9 or a letter a-z. WoW will actually look for the patch MPQs in that order, and whenever it finds a file in a patch MPQ it uses it instead of any previous versions it found, we can use that system to prioritize our MPQs. For example, a given texture in Patch-a.mpq gets ignored if it is found in Patch-z.mpq. We are getting ahead of ourselves a little bit, though...
    In a nutshell, the patch MPQ system is what allows us to "change" game textures without actually changing the game MPQs, which would be slow and potentially dangerous. We can take our textures and put them into a new MPQ and, if we've named everything correctly, WoW will load it.
    Important historical note : Prior to patch 1.11 or so, the patch system actually would search your local directories after searching for patch MPQs. All you had to do to replace a game texture was just put the file into the proper subdirectory and WoW would load it. Why do I mention this after they've taken it out? Because this is how WoWModelViewer [I'll abbreviate this to WMV from here on out] reads local files. We'll learn why that program rocks in a little bit.
    Example time! Lets say that we've got a modified version of a Night Elf skin and we want to put it into a custom MPQ. The original texture is in Texture.mpq, like so:
    [Texture.mpq] Character\NightElf\Female\NightElfFemaleSkin00_00.blp
    For this example, let's say we installed WoW to the default folder. If we want to preview our modified version of this skin in WMV, then we'd need to put it here:
    C:\Program Files\World of Warcraft\Data\Character\NightElf\Female\NightElfFemaleSkin00_00.blp
    Finally, if we want to see the texture in the game, we'd make a new MPQ file [I'll explain how later] using the patch naming convention and put in our texture, making sure to keep the same directory structure:
    [Patch-a.mpq] Character\NightElf\Female\NightElfFemaleSkin00_00.blp
    Part 2: Working With MPQ files
    Now that we know what MPQ files are and how WoW loads assets from them, lets talk about what tools are available that we can use to work with them.
    For reading MPQ files , nothing compares to MyWarcraftStudio [MWS] because if you select a texture it shows you what the texture is! That and the author is very good at updating it when Blizzard decides to make a change to the MPQ format (which is pretty often). The best place to download this program is from from the author's blog: 平民程序 - linghuye's blog - IT博客网.
    For writing/creating MPQ files , MWS will work but there is also another great tool called WinMPQ. WinMPQ's big advantage over MWS is that you can write scripts to automate the creation of MPQs. There are several versions of WinMPQ floating about. I get the one called "MyWinMPQ" from http://www.wowinterface.com/.
    Before we go on, we need to cover one really important point. The MPQ file format supports a few different types of file compression. Our tools don't necessarily support them all! Specifically, MWS *does* let you use compression when creating new MPQs, but WinMPQ doesn't. Luckily, WoW doesn't seem to care either way, so your safest bet when creating new MPQs is to find out how to disable compression with whatever tool you are using.
    Example time! Lets write a script for WinMPQ that creates a MPQ for our NElf texture, and a batch file to run it for us. First, the script. It's pretty basic stuff: one line to define that you are creating a new MPQ, and then one line for each of the files you want to add to it. The x line at the end just tells WinMPQ to exit when it is done. One of the cool things about this system is that if you run your script from the [WoW]\Data directory, not only will the relative path ("Character\NightElf\Female\") define where WinMPQ is to find the texture, it will also create that directory structure in the MPQ. (Remember that we need to keep the directory structure for our files or WoW won't find them.) Here is the script:
    --- Patch-a.txt ---
    n patch-a.mpq
    a "Character\NightElf\Female\NightElfFemaleSkin00_00.blp"
    x
    ------------------------
    You can open WinMPQ and load script files manually using the UI, but its easier to write a batch file to do it. Lets say we installed WinMPQ to C:\WinMPQ. Make this batch file and put it in your WoW Data directory:
    --- MakePatchA.bat ---
    C:\WinMPQ\WinMPQ.exe s patch-a.txt
    --------------------------------
    Now all you have to do is run the batch file and your modified texture will be visible in-game!
    *****
    If you do not want to make a batch file - you can open up mywinmpq and go to File --> Run MoPaQ 2000 Script
    Under, File Type switch it to All Files (*.*) and select teh text fiel you wrote
    *****
    Part 3: How WoW Draws Characters
    The first thing draw on a character model is the base Skin texture, ex. NightElfFemaleSkin00_00.blp. This is a Barbie-doll texture: no naughty-bits. Different skin tones are different numbers, ex. NightElfFemaleSkin00_01.blp, NightElfFemaleSkin00_02.blp, etc. WoW will only be able to draw base skins correctly if they are palettized textures without alpha. You should be aware that the number of different skin textures is defined by a number somewhere else (I'm not sure where), and so just adding new textures with incremented numbers will not give you more skin color options.
    If your character isn't wearing any chest armor, WoW draws another texture on top of the model's chest that has underwear on it, ex. NightElfFemaleNakedTorsoSkin00_00.blp. etc. If no pants, Character\NightElf\Female\NightElfFemaleNakedPelvisSkin00_00.blp. (This basically means that characters only wear underwear when they aren't wearing other clothes. Kinky.) These underwear textures also must be palettized without alpha, which presents a problem for people who modify skins. If you want to make an underwear-less skin for a character with naughty-bits, not only must you add the naughty bits to the base skin, but you must then make versions of the underwear textures that don't have underwear and that have the naughty bits.
    Clothing textures are a bit more complicated. Clothing textures need to be palettized, and they can optionally (usually) have an alpha channel. These textures are drawn on top of the base skin. Clothing textures are broken into a number of different regions on character's bodies. A single piece of armor can have many different textures. For example, a long sleeve shirt would require a TorsoUpper, TorsoLower, ArmUpper, and ArmLower texture. In addition, each of these textures can have different versions for male and female players, or can be unisex.
    The last paragraph was a lot of information so lets look at an example. These are the textures that make up "Padded Armor" (a cloth chestpiece) when worn on a female character:
    Item\TextureComponents\TorsoUpperTexture\Cloth_B_01Brown_Chest_TU_F.blp
    Item\TextureComponents\TorsoLowerTexture\Cloth_B_01Brown_Chest_TL_F.blp
    Item\TextureComponents\ArmUpperTexture\Cloth_B_01Brown_Chest_AU_U.blp
    There are several things to notice about these. First, each texture region has its own subdirectory. Second, this armor is short-sleeved: no ArmLower component. Third, two of these textures have male/female versions, but one is used for both sexes. You can tell by the last letter of the texture: F for "female" and U for "unisex" (and M for "male"). Important: this "sex suffix" is only a naming convention, it doesn't define what the game looks for. We players don't have any control over whether or not a given texture is male/female/both--that is defined elsewhere. (This is why clothing packs that make armor specifically for one sex often end up making that armor look terrible for the other sex.)
    Part 4: BLP Files
    So far we've covered how to get the files we want and how to make it so WoW loads our own versions of them. However, there are no programs which let you edit these textures directly because they are in Blizzard's proprietary BLP format. Thus, we need a converter that will convert BLP files into something common and back.
    First, though, a little bit about the different BLP formats that are available to us. Basically, there are two main options: whether or not a texture is palettized, and whether or not it has alpha. BLP files can handle all 4 cases, but WoW often expects a given texture to have a particular format. For example, character skins must be palettized and have no alpha.
    Back to BLP converters. There are a few BLP converters out there but I'm only going to mention the one called BLPConverter. (BLPConverter | World of Warcraft Tools | World of Warcraft @ Curse.com) Other ones exist but this one gives you the most options and feedback about what it is doing. BLPConverter only converts between BLP and PNG files, so you will need a texture editor that handles PNG. Most good ones do. If you need a good texture editor I recommend using The Gimp, as it is pretty good and totally free! (GIMP - The GNU Image Manipulation Program)
    Converting files is the single thing that people get caught up on the most, so it deserves to spoken about in greater detail. Basically, the problem is that the set of capabilities of the BLP file format doesn't exactly match the capabilities of the PNG format. (Or any other, for that matter.) This means that converter programs have to do some guessing, and can never handle 100% of the possible cases. However, if you follow a simple rule you'll (probably) not have any problems at all. That rule is: never create new PNGs from scratch, but instead create copy other ones that were converted from BLPs. Lets say for example we want to make a brand new character skin that is scaly. I may not want to use the source texture at all, but if I start with the PNG created by converting the original texture I insure two things. First, the texture will be the right size. Second, the PNG will obviously be in a format that the converter knows how to use--it created it! So long as I don't change the PNG format within my graphics program I shouldn't have any trouble converting it into a BLP that the game likes.
    *****
    Note: Latest version of blpconverter (7.1) is already setup to use teh better conversion type - just drag you png (doesnt need to be index) on to the .exe file and it will generate the blp files
    *****
    Tool Links:
    MyWarcraftStudio
    WoW Model Viewer
    BLPConverter
    WinMPQ (Kodo's "myWinMPQ" version)

 

 

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
All times are GMT -4. The time now is 02:31 PM. Powered by vBulletin® Version 4.2.0
Copyright © 2014 vBulletin Solutions, Inc. All rights reserved.
Content Relevant URLs by vBSEO Resources saved on this page: MySQL 5.88%
vBulletin Optimisation provided by vB Optimise (Pro) - vBulletin Mods & Addons Copyright © 2014 DragonByte Technologies Ltd.
Digital Point modules: Sphinx-based search

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160