It is currently 01 Aug 2025, 12:37
   
Text Size

【25/09/14】DotP2014 DLC v9.5

Moderator: CCGHQ Admins

Re: 【25/09/14】DotP2014 DLC v9.5

Postby sumomole » 25 Jan 2015, 15:37

God wrote:Wow I'm so dumb, I just realized if I had manually selected (and browsed) the opponent's decks (instead of just choosing random), I would've seen that a bunch of them had Karn's personalities.

I'm gonna try and give them different personality names and images. Maybe sumomole would appreciate it and ask for a copy :B Thanks for teaching me how to, Xander9009.
yes yes, the reason that use the same picture is to reduce the file size, not lazy. :lol: and if you want to make the different personalities, I am very happy to use it as a separate patch.
User avatar
sumomole
Programmer
 
Posts: 611
Joined: 07 Jun 2011, 08:34
Has thanked: 51 times
Been thanked: 234 times

Re: 【25/09/14】DotP2014 DLC v9.5

Postby God » 25 Jan 2015, 16:10

sumomole wrote:yes yes, the reason that use the same picture is to reduce the file size, not lazy. :lol: and if you want to make the different personalities, I am very happy to use it as a separate patch.
I figured. The original wads are only around 40kb, but the ones with unique personalities are around 300kb. But since it's still all just in kbs, it won't take long to download.

The personality images I'm assigning to them is the same card you used on their deck box. They're not as HD as the other original personalities though. I've finished only 4 so far.

Edit: I have a question. Is it alright if the Deck Identifier number is small. I just chose the "Get the first available ID" so yeah, all the decks are numbered 0, 1, 2, 3, ...
God
 
Posts: 19
Joined: 18 Jan 2015, 04:00
Has thanked: 2 times
Been thanked: 0 time

Re: 【25/09/14】DotP2014 DLC v9.5

Postby xanthics » 26 Jan 2015, 05:08

Simple Python3 script to change all of these decks to use their name plus the deck icon as icon. Gibbed tools, the .wad files you are changing, and this python script should all be in the same directory.

Depends on:

Gibbed tools to pack/unpack - (location in forum, apparently I can't link since new account)

names.txt for mapping names to decks -
Code: Select all
83~MONOBLACK
82~TOKENS
81~FAERIES
80~SKAAB RUINATOR
79~BANT BLINK
78~ESPER HUMAN
77~REANIMATOR
76~PROTEUS COLOSSUS
75~MERFOLKS
74~NORIN RAGE
73~SLAUGHTER GAMES
72~ZOO
71~JUND
70~TWIN EXARCH
68~JUND
67~WU CONTROL
66~RAKDOS AGGRO
65~AD NAUSEAM TENDRILS
64~HIGH TIDE
63~MONO-GREEN DEVOTION
62~MONO-WHITE DEVOTION
61~RED DECK WINS
60~MONO-RED DEVOTION
59~MONO-BLUE DEVOTION
58~SELESNYA AGGRO
57~MONO-BLACK DEVOTION
56~UB CONTROL
55~WOLF RUN RAMP
54~ESPER CONTROL
53~BALANCE
52~MR.GREED
51~SUMMER BLOOM
50~BLINK TOUCH
49~HAAKON CONTROL
48~CAW BLADE
47~WURM'S DESCENDANTS
46~GIANT NUMBERS
45~ROCK CONTROL
44~IMMORTAL SERVITUDE
43~CURSES
42~RECLUSIVE DEMON
41~AURAS ACI
40~BWR MIDRANGE
39~THE ARISTOCRATS
38~MIRROR-MA MILL
37~SEANCE
36~PYRODRIVER REVOLT
35~PIF COMBO
34~SCREECHING RATS
33~AZORIUS CONTROL
32~SCEPTER SILENCE
31~WUR MIDRANGE
30~APOSTLE HUSTLE
29~MARKET DAY
28~ALL ALLIES
27~IMPERIUS
26~DO IT AGAIN
25~THE ROYAL SCAM
24~TURBO FOG
23~NAYA SHAMAN
22~DESTRUCTIVE FORCE
21~SECOND BREAKFAST
20~ALL SPELLS
19~VINTAGE
18~BUBBLE HULK
17~STONE BLADE
16~LIFE PARTICLES
15~BATTLEDRIVER BURN
14~ATTACK ON HYDRA
13~PRIME SPEAKER BANT
12~LOAM VENGEANCE
11~ASTRAL SLIDE
10~DREDGEVINE
09~LANDS
08~WALKING DEAD
07~MANALESS DREDGE
06~GIFT SCAPESHIFT
05~GRIXIS CONTROL
04~ENTER THE DREAM
03~METAL PHOENIX
02~TURBO GRINDING
01~REPLENISH
Python3 code for unpacking, creating and modifying necessary files, then repacking -
Code: Select all
import glob, os, subprocess, shutil

names = {}
with open('names.txt', 'r') as f:
    for i in f:
        t = i.strip().split('~')
        if not t[0].isdigit():
            t[0] = '83'
        names[t[0]] = t[1].title()

for fn in glob.glob("*62*.wad"):
    subprocess.call(['Gibbed.Duels.Unpack.exe', '{}'.format(fn)])
    root = '{0}_unpacked\\{0}\\DATA_ALL_PLATFORMS'.format(fn.split('.')[0])
    aiRoot = root + '\\AI_PERSONALITIES'
    name = fn.split('.')[0][-2:]
    personality = '{}\\D0{}_{}.xml'.format(aiRoot, name, names[name].replace(' ', '_'))
    planeswalkerGraphic = root + '\\ART_ASSETS\\TEXTURES'
    print(names[name])
    if not os.path.exists(aiRoot):
        os.mkdir(aiRoot)
    with open(personality, 'w') as f:
        f.write('''<CONFIG>
  <PLANESWALKER_NAME_TAG string="{1}" />
  <LARGE_AVATAR_IMAGE string="M{0}_{1}" />
  <MEDIUM_AVATAR_IMAGE string="M{0}_{1}" />
  <SMALL_AVATAR_IMAGE string="M{0}_{1}" />
  <SMALL_AVATAR_IMAGE_LOCKED string="M{0}_{1}" />
  <LOBBY_IMAGE string="M{0}_{1}" />
  <MUSIC string="" />
</CONFIG>'''.format(name, names[name].replace(' ', '_')))
    image = os.listdir(planeswalkerGraphic+'\\DECKS')[0]
    if not os.path.exists(planeswalkerGraphic+'\\PLANESWALKERS'):
        os.mkdir(planeswalkerGraphic+'\\PLANESWALKERS')
    shutil.copy2(planeswalkerGraphic+'\\DECKS\\'+image, planeswalkerGraphic+'\\PLANESWALKERS\\M{0}_{1}.tdx'.format(name, names[name].replace(' ', '_')))
    deckText = open(root+'\\DECKS\\{}'.format(os.listdir(root+'\\DECKS')[0]), 'r').readlines()
    t = deckText[0].split('personality="')
    t[1] = t[1].split('"', 1)[1]
    deckText[0] = 'personality="D0{}_{}.xml"'.join(t).format(name, names[name].replace(' ', '_'))
    with open(root+'\\DECKS\\{}'.format(os.listdir(root+'\\DECKS')[0]), 'w') as f:
        for i in deckText:
            f.write(i)
    subprocess.call(['Gibbed.Duels.Pack.exe', '{}_unpacked'.format(fn.split('.')[0])])
    os.rename('{}_unpacked.wad'.format(fn.split('.')[0]), '{}_{}.wad'.format(fn.split('.')[0], names[name].replace(' ', '_')))
    shutil.rmtree('{0}_unpacked'.format(fn.split('.')[0]))
Last edited by xanthics on 27 Jan 2015, 10:49, edited 1 time in total.
xanthics
 
Posts: 13
Joined: 26 Jan 2015, 04:57
Has thanked: 2 times
Been thanked: 1 time

Re: 【25/09/14】DotP2014 DLC v9.5

Postby God » 27 Jan 2015, 03:50

That's pretty neat. I might use that if I lose my patience. Right now, I'm trying to do it manually because I'm not literally using the deck image itself, but I (try to) find a hq image of the card on the deck image to use it for the personality.
God
 
Posts: 19
Joined: 18 Jan 2015, 04:00
Has thanked: 2 times
Been thanked: 0 time

Re: 【25/09/14】DotP2014 DLC v9.5

Postby xanthics » 27 Jan 2015, 10:25

Given the image files, I could add that to the script as well. I just discovered that you could play with custom cards/decks about 3 days ago and haven't had a chance to explore beyond the initial fixing of the Karns.
xanthics
 
Posts: 13
Joined: 26 Jan 2015, 04:57
Has thanked: 2 times
Been thanked: 1 time

Re: 【25/09/14】DotP2014 DLC v9.5

Postby God » 27 Jan 2015, 12:52

xanthics wrote:Given the image files, I could add that to the script as well. I just discovered that you could play with custom cards/decks about 3 days ago and haven't had a chance to explore beyond the initial fixing of the Karns.
I could give you the 512x512 card image art for each deck that I've used. I've been using either the same card as the deck image (as I've mentioned) or the mythic rare card of the deck - whichever looks cooler.
God
 
Posts: 19
Joined: 18 Jan 2015, 04:00
Has thanked: 2 times
Been thanked: 0 time

Re: 【25/09/14】DotP2014 DLC v9.5

Postby xanthics » 27 Jan 2015, 19:55

God wrote:
xanthics wrote:...
I could give you the 512x512 card image art for each deck that I've used. I've been using either the same card as the deck image (as I've mentioned) or the mythic rare card of the deck - whichever looks cooler.
Send me an email at gw2crafts [at] live (dot) net and I'll update the Python script so you can just batch it all together. I assume they don't need any cropping for the different views? (Although that can be scripted too).
xanthics
 
Posts: 13
Joined: 26 Jan 2015, 04:57
Has thanked: 2 times
Been thanked: 1 time

Re: 【25/09/14】DotP2014 DLC v9.5

Postby God » 28 Jan 2015, 08:23

xanthics wrote:Send me an email at gw2crafts [at] live (dot) net and I'll update the Python script so you can just batch it all together. I assume they don't need any cropping for the different views? (Although that can be scripted too).
I made it so that the name of the images are corresponding to their deck numbers. Here's the link: http://www.mediafire.com/download/954tj ... 12x512.zip

And here is the list of the deck names, because I noticed there are some typos on the previous list:
Code: Select all
83~Monoblack
82~Tokens
81~Faeries
80~Skaab Ruinator
79~Bant Blink
78~Esper Human
77~Reanimator
76~Proteus Colossus
75~Merfolks
74~Norin Rage
73~Slaughter Games
72~Zoo
71~Jund
70~Twin Exarch
68~Anger of the Gods
67~WU Control
66~Rakdos Aggro
65~Ad Nauseam Tendrils
64~High Tide
63~Mono-Green Devotion
62~Mono-White Devotion
61~Red Deck Wins
60~Mono-Red Devotion
59~Mono-Blue Devotion
58~Selesnya Aggro
57~Mono-Black Devotion
56~UB Control
55~Wolf Run Ramp
54~Esper Control
53~Counter Balance
52~Mr.Greed
51~Summer Bloom
50~Blink Touch
49~Haakon Control
48~Caw Blade
47~Wurm'S Descendants
46~Giant Numbers
45~Rock Control
44~Immortal Servitude
43~Curses!
42~Reclusive Demon
41~Auras Acid
40~BWR Midrange
39~The Aristocrats
38~Mirror-Mad Mill
37~Séance
36~Pyrodriver Revolt
35~PiF Combo
34~Screeching Rats
33~Azorius Control
32~Scepter Silence
31~WUR Midrange
30~Apostle Hustle
29~Market Day
28~Allies
27~Imperius
26~Do It Again
25~The Royal Scam
24~Turbo Fog
23~Naya Shaman
22~Destructive Force
21~Second Breakfast
20~All Spells
19~Vintage
18~Bubble Hulk
17~Stone Blade
16~Life Particles
15~Battledriver Burn
14~Attack On Hydra
13~Prime Speaker Bant
12~Loam Vengeance
11~Astral Slide
10~Dredgevine
09~Lands
08~Walking Dead
07~Manaless Dredge
06~Gift Scapeshift
05~Grixis Control
04~Enter The Dream
03~Metal Phoenix
02~Turbo Grinding
01~Replenish
EDIT: As for the different views, I think the default of their "build image" in reksaii's tool is good enough. No need to zoom in or adjust the x/y positions.
God
 
Posts: 19
Joined: 18 Jan 2015, 04:00
Has thanked: 2 times
Been thanked: 0 time

Re: 【25/09/14】DotP2014 DLC v9.5

Postby xanthics » 29 Jan 2015, 08:00

I got the images imported easy enough, but some resizing will need to be done, as the way it looks in game is :| (see attached)

Looking at the existing Karn images, the ingame file is 256x256 with a ~90 radius circle of image in the middle.
Attachments
2015-01-28_00001.jpg
xanthics
 
Posts: 13
Joined: 26 Jan 2015, 04:57
Has thanked: 2 times
Been thanked: 1 time

Re: 【25/09/14】DotP2014 DLC v9.5

Postby God » 29 Jan 2015, 14:21

xanthics wrote:I got the images imported easy enough, but some resizing will need to be done, as the way it looks in game is :| (see attached)

Looking at the existing Karn images, the ingame file is 256x256 with a ~90 radius circle of image in the middle.
This took awhile to do. I hope I got it right. http://www.mediafire.com/download/kalb2 ... 56x256.zip By the way, I know it's not final yet, but can you use the deck names from the txt I showed above? Instead of the all caps with brackets. Just to make them match the official decks.
God
 
Posts: 19
Joined: 18 Jan 2015, 04:00
Has thanked: 2 times
Been thanked: 0 time

Re: 【25/09/14】DotP2014 DLC v9.5

Postby xanthics » 30 Jan 2015, 05:04

See attached for how these look in game. Turns out the correct names already existed in S62.wad, just needed to point to them instead of Karn.

How to use:
In the same directory as "Modified Gibbed Tools r6_b10 Binaries"
-256x256 folder that contains the ## (Copy).png files
-512x512 folder that contains the ##.png files
names.txt in the base directory
only the 01-83 wads in the base directory(not the s62.wad file, it will break)
run the Python3 script and move the resulting files to your mtg 2014 directory


names.txt to map deck numbers to correct names:
Code: Select all
83~D62_PERSECUTOR
82~D62_TOKENS
81~D62_FAERIE
80~D62_SKAAB
79~D62_BANT
78~D62_ESPERH
77~D62_REANIMATE
76~D62_PROTEUS
75~D62_MERFOLK
74~D62_NORIN
73~D62_ORZHOV
72~D62_ZOO
71~D62_JUNDS
70~D62_TWIN
68~D62_JUND
67~D62_TITANS
66~D62_RAKDOS
65~D62_ANT
64~D62_TIDE
63~D62_NYLEA
62~D62_HELIOD
61~D62_MOGIS
60~D62_PURPHOROS
59~D62_THASSA
58~D62_GWA
57~D62_EREBOS
56~D62_DIMIR
55~D62_RAMP
54~D62_ESPER
53~D62_ENCHANT
52~D62_GREED
51~D62_VIGOR
50~D62_BLINK
49~D62_HAAKON
48~D62_SWORD
47~D62_WURMS
46~D62_GIANTS
45~D62_GBW
44~D62_IMMORTAL
43~D62_CURSES
42~D62_MNB
41~D62_AURAS
40~D62_BWR
39~D62_ARISTOCRATS
38~D62_MIRRORMAD
37~D62_SEANCE
36~D62_PYRODRIVER
35~D62_PYROMANCER
34~D62_RATS
33~D62_PIKE
32~D62_SILENCE
31~D62_WUR
30~D62_SHADOWBORN
29~D62_TRADE
28~D62_ALLIES
27~D62_ANGELS
26~D62_BINDER
25~D62_ASYLUM
24~D62_FOG
23~D62_NAYA
22~D62_FORCE
21~D62_EGG
20~D62_DANCE
19~D62_VINTAGE
18~D62_HULK
17~D62_STONEBLADE
16~D62_LIFE
15~D62_BATTLEDRIVER
14~D62_HYDRA
13~D62_PRIME
12~D62_SEISMIC
11~D62_CYCLING
10~D62_DVINE
09~D62_LANDS
08~D62_VAROLZ
07~D62_DREDGE
06~D62_SCAPESHIFT
05~D62_GRIXIS
04~D62_OMNITELL
03~D62_KULDOTHA
02~D62_GRINDING
01~D62_REPLENISH
Python3 script to pull it all together. Will create the new wad with same name plus n at the end.
Code: Select all
import glob, os, subprocess, shutil
import sys


def main():
    names = {}
    with open('names.txt', 'r') as f:
        for i in f:
            t = i.strip().split('~')
            if not t[0].isdigit():
                t[0] = '83'
            names[t[0]] = t[1]

    for fn in glob.glob("*62*.wad"):
        name = fn.split('.')[0][-2:]
        subprocess.call(['Gibbed.Duels.Unpack.exe', '{}'.format(fn)])

        shutil.copy2("512x512\\{}.png".format(name), '{}.png'.format(name))
        shutil.copy2("256x256\\{} (Copy).png".format(name), '{}s.png'.format(name))

        root = '{0}_unpacked\\{0}\\DATA_ALL_PLATFORMS'.format(fn.split('.')[0])
        aiRoot = root + '\\AI_PERSONALITIES'
        personality = '{}\\D0{}_{}.xml'.format(aiRoot, name, names[name])
        planeswalkerGraphic = root + '\\ART_ASSETS\\TEXTURES\\PLANESWALKERS'
        if not os.path.exists(aiRoot):
            os.mkdir(aiRoot)
        with open(personality, 'w') as f:
            f.write('<CONFIG>\n\t<PLANESWALKER_NAME_TAG string="{1}" />\n\t<LARGE_AVATAR_IMAGE string="M{0}_{1}" />\n\t<MEDIUM_AVATAR_IMAGE string="M{0}_{1}S" />\n\t<SMALL_AVATAR_IMAGE string="M{0}_{1}S" />\n\t<SMALL_AVATAR_IMAGE_LOCKED string="M{0}_{1}S" />\n\t<LOBBY_IMAGE string="M{0}_{1}" />\n\t<MUSIC string="" />\n</CONFIG>'.format(name, names[name]))

        subprocess.call(['Gibbed.Duels.TdxConvert.exe', '--dxt5', '{}.png'.format(name)])
        subprocess.call(['Gibbed.Duels.TdxConvert.exe', '--dxt5', '{}s.png'.format(name)])
        if not os.path.exists(planeswalkerGraphic):
            os.mkdir(planeswalkerGraphic)
        shutil.copy2("{}.TDX".format(name), planeswalkerGraphic+'\\M{0}_{1}.tdx'.format(name, names[name]))
        shutil.copy2("{}s.TDX".format(name), planeswalkerGraphic+'\\M{0}_{1}S.tdx'.format(name, names[name]))
        deckText = open(root+'\\DECKS\\{}'.format(os.listdir(root+'\\DECKS')[0]), 'r').readlines()
        t = deckText[0].split('personality="')
        t[1] = t[1].split('"', 1)[1]
        deckText[0] = 'personality="D0{}_{}.xml"'.join(t).format(name, names[name])
        with open(root+'\\DECKS\\{}'.format(os.listdir(root+'\\DECKS')[0]), 'w') as f:
            for i in deckText:
                f.write(i)
        subprocess.call(['Gibbed.Duels.Pack.exe', '{}_unpacked'.format(fn.split('.')[0])])
        os.rename('{}_unpacked.wad'.format(fn.split('.')[0]), '{}n.wad'.format(fn.split('.')[0], names[name]))

        # cleanup
        shutil.rmtree('{0}_unpacked'.format(fn.split('.')[0]))
        os.remove('{0}.TDX'.format(name))
        os.remove('{0}s.TDX'.format(name))
        os.remove('{0}.png'.format(name))
        os.remove('{0}s.png'.format(name))



if __name__ == "__main__":
    main()
Attachments
2015-01-29_00002.jpg
2015-01-29_00001.jpg
xanthics
 
Posts: 13
Joined: 26 Jan 2015, 04:57
Has thanked: 2 times
Been thanked: 1 time

Re: 【25/09/14】DotP2014 DLC v9.5

Postby God » 30 Jan 2015, 06:24

Should we make another set of images for the deck select screen? (Like on your second screenshot) I don't mind doing it. since we already spent some time for it might as well do it perfectly lool. As long as it's easy for you.
God
 
Posts: 19
Joined: 18 Jan 2015, 04:00
Has thanked: 2 times
Been thanked: 0 time

Re: 【25/09/14】DotP2014 DLC v9.5

Postby xanthics » 30 Jan 2015, 06:35

Feel free to make whatever images you would like. It's rather simple for me to modify the code so that it creates the decks.
xanthics
 
Posts: 13
Joined: 26 Jan 2015, 04:57
Has thanked: 2 times
Been thanked: 1 time

Re: 【25/09/14】DotP2014 DLC v9.5

Postby God » 30 Jan 2015, 07:02

Awesome. I'll do it asap. Btw, Do you use Riiak's deck builder too? Somehow when I view the "Deck Information" of the deck (created by the script you made), it gives an error. D:
God
 
Posts: 19
Joined: 18 Jan 2015, 04:00
Has thanked: 2 times
Been thanked: 0 time

Re: 【25/09/14】DotP2014 DLC v9.5

Postby xanthics » 30 Jan 2015, 07:48

I don't use the deck builder. I'll try it later and see if I can track down what I need to clean up for it to play nice.
xanthics
 
Posts: 13
Joined: 26 Jan 2015, 04:57
Has thanked: 2 times
Been thanked: 1 time

PreviousNext

Return to 2014

Who is online

Users browsing this forum: No registered users and 4 guests

Main Menu

User Menu

Our Partners


Who is online

In total there are 4 users online :: 0 registered, 0 hidden and 4 guests (based on users active over the past 10 minutes)
Most users ever online was 7303 on 15 Jul 2025, 20:46

Users browsing this forum: No registered users and 4 guests

Login Form