Non-deck meta removed from quest dck files. Meta now reads

Name=
Display Name=
Icon=
Deck Type=
Comment=

All quest-related information is fully stored in quests.txt, including AI and human extra cards at match start.

ReadQuest_Assignment assembles all quest information from this file.
Quest_Assignment has getters and setters to handle all information.

QuestUtil updated, most importantly deprecating SetupQuest, which previously held a lot of hard-coded data.
This commit is contained in:
Doublestrike
2011-09-11 04:54:11 +00:00
parent 46a8d9ff4a
commit e5c6d749b8
28 changed files with 674 additions and 1133 deletions

1
.gitattributes vendored
View File

@@ -9112,6 +9112,7 @@ res/pics/icons/LeafIconSmall.png -text svneol=unset#image/png
res/pics/icons/Life.png -text svneol=unset#image/png
res/pics/icons/MapIcon.png -text svneol=unset#image/png
res/pics/icons/MapIconLarge.png -text svneol=unset#image/png
res/pics/icons/Unknown.jpg -text
res/pics/icons/ZeppelinIcon.png -text svneol=unset#image/png
res/pics/icons/notesIcon.png -text svneol=unset#image/png
res/pics_link/card-pictures_a.txt svneol=native#text/plain

BIN
res/pics/icons/Unknown.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 24 KiB

View File

@@ -1,15 +1,7 @@
[metadata]
ID=1
Name=quest1
DisplayName=Dungeon Crawling (White)
Difficulty=Medium
Description=This realm is guarded by a divine entity laying his protecting hand on each living being.
Repeatable=true
NumberWinsRequired=20
CardReward=3 white rares
CreditsReward=100
Icon=Dungeon Crawling White.jpg
AILife=25
Deck Type=constructed
Comment=
[main]
@@ -51,6 +43,3 @@ Comment=
1 Retribution of the Meek
1 Sunlance
[sideboard]
[human_extra_cards]
[ai_extra_cards]
1 Divine Presence

View File

@@ -1,15 +1,7 @@
[metadata]
ID=10
Name=quest10
DisplayName=Zombie Attack!
Difficulty=Hard
Description=The village of Haven is getting attacked by the Zombie horde! Protect the village.
Repeatable=false
NumberWinsRequired=40
CardReward=4 black rares
CreditsReward=200
Icon=Zombie Attack.jpg
AILife=30
Deck Type=constructed
Comment=
[main]
@@ -38,11 +30,3 @@ Comment=
1 Warpath Ghoul
1 Viscera Dragger
[sideboard]
[human_extra_cards]
TOKEN|W|1|1|citizen|creature
TOKEN|W|1|1|citizen|creature
TOKEN|W|1|1|citizen|creature
Wall of Spears
[ai_extra_cards]
Scathe Zombies
Mass of Ghouls

View File

@@ -1,15 +1,7 @@
[metadata]
ID=11
Name=quest11
DisplayName=The King's Contest
Difficulty=Hard
Description=The king is holding a contest. You are invited to participate and compete against other legends of this era.
Repeatable=false
NumberWinsRequired=40
CardReward=3 random rares
CreditsReward=150
Icon=The Kings Contest.jpg
AILife=30
Deck Type=constructed
Comment=
[main]
@@ -58,7 +50,3 @@ Comment=
3 Mountain
1 Tuknir Deathlock
[sideboard]
[human_extra_cards]
Seal of Cleansing
[ai_extra_cards]
Loyal Retainers

View File

@@ -1,15 +1,7 @@
[metadata]
ID=12
Name=quest12
DisplayName=Barroom Brawl
Difficulty=Hard
Description=A drunken giant of a man takes a swing at you, your brew spills and a fight breaks out.
Repeatable=false
NumberWinsRequired=64
CardReward=4 random rares
CreditsReward=250
Icon=Barroom Brawl.jpg
AILife=30
Deck Type=constructed
Comment=
[main]
@@ -35,9 +27,3 @@ Comment=
4 Savannah
4 Wasteland
[sideboard]
[human_extra_cards]
TOKEN|W|1|1|soldier ally|creature|soldier|ally
TOKEN|W|1|1|soldier ally|creature|soldier|ally
TOKEN|W|1|1|soldier ally|creature|soldier|ally
[ai_extra_cards]
Lowland Giant

View File

@@ -1,15 +1,7 @@
[metadata]
ID=13
Name=quest13
DisplayName=The Court Jester
Difficulty=Hard
Description=The Court Jester pulls a prank on you. Will you laugh it off or pay him back?
Repeatable=false
NumberWinsRequired=52
CardReward=4 multi-colored rares
CreditsReward=300
Icon=The Court Jester.jpg
AILife=30
Deck Type=constructed
Comment=
[main]
@@ -36,7 +28,3 @@ Comment=
1 Mox Jet
2 Mountain
[sideboard]
[human_extra_cards]
Sensei's Divining Top
[ai_extra_cards]
Teferi's Puzzle Box

View File

@@ -1,15 +1,7 @@
[metadata]
ID=14
Name=quest14
DisplayName=Ancient Battlefield
Difficulty=Hard
Description=You visit an ancient battlefield at midnight. It is overgrown and dark. You trip on a root, utter a curse and wish that you could see.
Repeatable=false
NumberWinsRequired=64
CardReward=4 random rares
CreditsReward=250
Icon=Ancient Battlefield.jpg
AILife=30
Deck Type=constructed
Comment=
[main]
@@ -32,9 +24,3 @@ Comment=
1 Mox Jet
4 Essence Warden
[sideboard]
[human_extra_cards]
Glasses of Urza
Blight Sickle
[ai_extra_cards]
Bad Moon
Wall of Brambles

View File

@@ -1,15 +1,7 @@
[metadata]
ID=15
Name=quest15
DisplayName=Don't Play With Matches
Difficulty=Hard
Description=The goblins are battling the elves. Those pesky elves, will they ever learn. Do not play with fire!
Repeatable=false
NumberWinsRequired=52
CardReward=4 red rares
CreditsReward=200
Icon=Dont Play With Matches.jpg
AILife=30
Deck Type=constructed
Comment=
[main]
@@ -33,10 +25,3 @@ Comment=
4 Elvish Harbinger
4 Llanowar Elves
[sideboard]
[human_extra_cards]
1 Mudbutton Torchrunner
1 Scuzzback Scrapper
[ai_extra_cards]
1 Heedless One
1 Norwood Archers
1 Wildslayer Elves

View File

@@ -1,15 +1,7 @@
[metadata]
ID=16
Name=quest16
DisplayName=Mines of Kazum Durl
Difficulty=Hard
Description=While exploring a mine with a group of dwarves the mine caves in. You start to dig out and then realize that your group is not alone.
Repeatable=false
NumberWinsRequired=52
CardReward=4 green rares
CreditsReward=250
Icon=Mines of Kazum Durl.jpg
AILife=30
Deck Type=constructed
Comment=
[main]
@@ -37,14 +29,3 @@ Comment=
1 Doubling Season
3 Thelonite Hermit
[sideboard]
[human_extra_cards]
Dwarven Demolition Team
Dwarven Pony
Dwarven Trader
[ai_extra_cards]
Wall of Earth
Wall of Air
Wall of Ice
Wall of Light
Carrion Wall
Steel Wall

View File

@@ -1,15 +1,7 @@
[metadata]
ID=17
Name=quest17
DisplayName=House Party
Difficulty=Hard
Description=Your friends decide to hold a house party at your home tonight. Later that night uninvited guests show up and disrupt the party.
Repeatable=false
NumberWinsRequired=64
CardReward=4 colorless rares
CreditsReward=250
Icon=House Party.jpg
AILife=30
Deck Type=constructed
Comment=
[main]
@@ -37,10 +29,3 @@ Comment=
4 Sprouting Thrinax
1 Mountain
[sideboard]
[human_extra_cards]
Hopping Automaton
Honden of Life's Web
Forbidden Orchard
[ai_extra_cards]
Honden of Infinite Rage
Mikokoro, Center of the Sea

View File

@@ -1,15 +1,7 @@
[metadata]
ID=18
Name=quest18
DisplayName=Crows in the Field
Difficulty=Hard
Description=Crows are eating the seed planted in the local farm fields. The farmers are scared. Those crows are big, you will need some help.
Repeatable=false
NumberWinsRequired=64
CardReward=5 random rares
CreditsReward=300
Icon=Crows in the Field.jpg
AILife=30
Deck Type=constructed
Comment=
[main]
@@ -34,12 +26,3 @@ Comment=
4 Savannah
2 Eldrazi Conscription
[sideboard]
[human_extra_cards]
Straw Soldiers
Femeref Archers
Moonglove Extract
[ai_extra_cards]
Defiant Falcon
Soulcatcher
Storm Crow
Hypnotic Specter

View File

@@ -1,15 +1,7 @@
[metadata]
ID=19
Name=quest19
DisplayName=The Desert Caravan
Difficulty=Hard
Description=A caravan is transporting silk across the desert. While setting up camp for the night you are attacked by thieves. Defend yourself.
Repeatable=false
NumberWinsRequired=80
CardReward=5 random rares
CreditsReward=300
Icon=The Desert Caravan.jpg
AILife=30
Deck Type=constructed
Comment=
[main]
@@ -31,9 +23,3 @@ Comment=
4 Eladamri's Call
4 Savannah
[sideboard]
[human_extra_cards]
Spidersilk Net
Dromad Purebred
[ai_extra_cards]
4 Ambush Party
Gnat Alley Creeper

View File

@@ -1,15 +1,7 @@
[metadata]
ID=2
Name=quest2
DisplayName=Dungeon Crawling (Blue)
Difficulty=Medium
Description=This realm holds knowledge so vast it can overburden the unwary.
Repeatable=true
NumberWinsRequired=20
CardReward=3 blue rares
CreditsReward=100
Icon=Dungeon Crawling Blue.jpg
AILife=25
Deck Type=constructed
Comment=
[main]
@@ -38,7 +30,3 @@ Comment=
1 Fugitive Wizard
1 Grayscaled Gharial
[sideboard]
[human_extra_cards]
1 Quest for Ancient Secrets
[ai_extra_cards]
1 Forced Fruition

View File

@@ -1,15 +1,7 @@
[metadata]
ID=20
Name=quest20
DisplayName=Blood Oath
Difficulty=Hard
Description=A druid saves your life and the two of you take a blood oath. It is now time to fulfill your oath.
Repeatable=false
NumberWinsRequired=80
CardReward=5 colorless rares
CreditsReward=300
Icon=Blood Oath.jpg
AILife=30
Deck Type=constructed
Comment=
[main]
@@ -43,11 +35,3 @@ Comment=
1 Thoughtseize
1 Emrakul, the Aeons Torn
[sideboard]
[human_extra_cards]
Counterbalance
Hatching Plans
Ley Druid
[ai_extra_cards]
Ior Ruin Expedition
Oversold Cemetery
Trapjaw Kelpie

View File

@@ -1,15 +1,7 @@
[metadata]
ID=21
Name=quest21
DisplayName=Private Domain
Difficulty=Expert
Description=During your travels, you accidentally stumble upon the domain of an evil, powerful wizard. A fight to the death ensues.
Repeatable=false
NumberWinsRequired=96
CardReward=6 random rares
CreditsReward=500
Icon=Private Domain.jpg
AILife=50
Deck Type=constructed
Comment=
[main]
@@ -40,11 +32,3 @@ Comment=
1 Mountain
2 Wandering Stream
[sideboard]
[human_extra_cards]
Strip Mine
[ai_extra_cards]
Plains
Island
Mountain
Swamp
Forest

View File

@@ -1,15 +1,7 @@
[metadata]
ID=22
Name=quest22
DisplayName=The Pied Piper
Difficulty=Hard
Description=A mysterious man threatens to flood the land with a relentless stream of hungry rats. Cross his plan before it's too late.
Repeatable=false
NumberWinsRequired=32
CardReward=3 random rares
CreditsReward=150
Icon=The Pied Piper.jpg
AILife=30
Deck Type=constructed
Comment=
[main]
@@ -23,11 +15,3 @@ Comment=
4 Thrumming Stone
29 Relentless Rats
[sideboard]
[human_extra_cards]
1 Volunteer Militia
1 Land Tax
1 Elvish Farmer
1 An-Havva Township
[ai_extra_cards]
1 Darksteel Citadel
1 Relentless Rats

View File

@@ -1,15 +1,7 @@
[metadata]
ID=3
Name=quest3
DisplayName=Dungeon Crawling (Black)
Difficulty=Medium
Description=Guarded by black creatures.
Repeatable=true
NumberWinsRequired=20
CardReward=3 black rares
CreditsReward=100
Icon=Dungeon Crawling Black.jpg
AILife=25
Deck Type=constructed
Comment=
[main]
@@ -41,6 +33,3 @@ Comment=
1 Beacon of Unrest
1 Zombify
[sideboard]
[human_extra_cards]
[ai_extra_cards]
Infernal Genesis

View File

@@ -1,15 +1,7 @@
[metadata]
ID=4
Name=quest4
DisplayName=Dungeon Crawling (Red)
Difficulty=Medium
Description=Guarded by red creatures.
Repeatable=true
NumberWinsRequired=20
CardReward=3 red rares
CreditsReward=100
Icon=Dungeon Crawling Red.jpg
AILife=25
Deck Type=constructed
Comment=
[main]
@@ -96,6 +88,3 @@ Comment=
1 Tarfire
1 Volcanic Hammer
[sideboard]
[human_extra_cards]
[ai_extra_cards]
Furnace of Rath

View File

@@ -1,15 +1,7 @@
[metadata]
ID=5
Name=quest5
DisplayName=Dungeon Crawling (Green)
Difficulty=Medium
Description=Guarded by green creatures.
Repeatable=true
NumberWinsRequired=20
CardReward=3 green rares
CreditsReward=100
Icon=Dungeon Crawling Green.jpg
AILife=25
Deck Type=constructed
Comment=
[main]
@@ -76,8 +68,3 @@ Comment=
1 Woodfall Primus
1 Yavimaya Wurm
[sideboard]
[human_extra_cards]
Defense of the Heart
[ai_extra_cards]
Eladamri's Vineyard
Upwelling

View File

@@ -1,15 +1,7 @@
[metadata]
ID=6
Name=quest6
DisplayName=Dungeon Crawling (Colorless)
Difficulty=Hard
Description=The inhabitants of this plane tread with a light step.
Repeatable=true
NumberWinsRequired=28
CardReward=3 colorless rares
CreditsReward=150
Icon=Dungeon Crawling Colorless.jpg
AILife=30
Deck Type=constructed
Comment=
[main]
@@ -85,6 +77,3 @@ Comment=
1 Whipstitched Zombie
1 Yawgmoth Demon
[sideboard]
[human_extra_cards]
[ai_extra_cards]
3 Eon Hub

View File

@@ -1,15 +1,7 @@
[metadata]
ID=7
Name=quest7
DisplayName=Dungeon Crawling (Gold)
Difficulty=Hard
Description=Guarded by gold creatures.
Repeatable=true
NumberWinsRequired=28
CardReward=3 multi-colored rares
CreditsReward=150
Icon=Dungeon Crawling Gold.jpg
AILife=30
Deck Type=constructed
Comment=
[main]
@@ -48,6 +40,3 @@ Comment=
1 Conflux
1 Maelstrom Nexus
[sideboard]
[human_extra_cards]
[ai_extra_cards]
Darksteel Ingot

View File

@@ -1,15 +1,7 @@
[metadata]
ID=8
Name=quest8
DisplayName=A Wolf in Sheep's Clothing
Difficulty=Medium
Description=The local sheep farm is under attack by a pack of wolves. Kill the wolves, save the sheep!
Repeatable=false
NumberWinsRequired=28
CardReward=3 random rares
CreditsReward=200
Icon=A Wolf in Sheeps Clothing.jpg
AILife=25
Deck Type=constructed
Comment=
[main]
@@ -31,8 +23,3 @@ Comment=
4 Tundra Wolves
4 Savannah
[sideboard]
[human_extra_cards]
TOKEN|G|0|1|sheep|creature|sheep
TOKEN|G|0|1|sheep|creature|sheep
TOKEN|G|0|1|sheep|creature|sheep
[ai_extra_cards]

View File

@@ -1,15 +1,7 @@
[metadata]
ID=9
Name=quest9
DisplayName=Bushwhacked!
Difficulty=Hard
Description=You find yourself surrounded by carnivorous plants and poisonous vines. Cut your way out of this foresty mess and make it home safe.
Repeatable=false
NumberWinsRequired=40
CardReward=4 green rares
CreditsReward=225
Icon=Bushwhacked.jpg
AILife=30
Deck Type=constructed
Comment=
[main]
@@ -32,7 +24,3 @@ Comment=
4 Vine Trellis
1 Overbeing of Myth
[sideboard]
[human_extra_cards]
Trusty Machete
[ai_extra_cards]
3 Wall of Wood

View File

@@ -1,221 +1,315 @@
1
Dungeon Crawling (White)
This realm is guarded by a divine entity laying his protecting hand on each living being.
Medium
Repeatable
20
Three white rares
100
Dungeon Crawling White.jpg
Notes
- A [quest] line triggers a new quest object.
- Properties can be in any order
- IDs are mandatory, and must be sequential.
- Any other property, if empty, will use a default value.
- Both AI and human can have extra legal cards and/or tokens at match start.
2
Dungeon Crawling (Blue)
This realm holds knowledge so vast it can overburden the unwary.
Medium
Repeatable
20
Three blue rares
100
Dungeon Crawling Blue.jpg
[quest]
id=1
Icon=Dungeon Crawling White.jpg
Title=Dungeon Crawling (White)
Desc=This realm is guarded by a divine entity laying his protecting hand on each living being.
Diff=Medium
AILife=25
Repeat=true
Wins=20
Card Reward=3 white rares
Credit Reward=100
HumanExtras=
AIExtras=Divine Presence
3
Dungeon Crawling (Black)
Guarded by black creatures.
Medium
Repeatable
20
Three black rares
100
Dungeon Crawling Black.jpg
[quest]
id=2
Icon=Dungeon Crawling Blue.jpg
Title=Dungeon Crawling (Blue)
Desc=This realm holds knowledge so vast it can overburden the unwary.
Diff=Medium
AILife=25
Repeat=true
Wins=20
Card Reward=3 blue rares
Credit Reward=100
HumanExtras=Quest for Ancient Secrets
AIExtras=Forced Fruition
4
Dungeon Crawling (Red)
Guarded by red creatures.
Medium
Repeatable
20
Three red rares
100
Dungeon Crawling Red.jpg
[quest]
id=3
Icon=Dungeon Crawling Black.jpg
Title=Dungeon Crawling (Black)
Desc=The dead cannot be silenced, and want you to join their ranks.
Diff=Medium
AILife=25
Repeat=true
Wins=20
Card Reward=3 black rares
Credit Reward=100
HumanExtras=
AIExtras=Infernal Genesis
5
Dungeon Crawling (Green)
Guarded by green creatures.
Medium
Repeatable
20
Three green rares
100
Dungeon Crawling Green.jpg
[quest]
id=4
Icon=Dungeon Crawling Red.jpg
Title=Dungeon Crawling (Red)
Desc=Untold treasure awaits you, should you successfully dodge the lightning and lava.
Diff=Medium
AILife=25
Repeat=true
Wins=20
Card Reward=3 red rares
Credit Reward=100
HumanExtras=
AIExtras=Furnace of Rath
6
Dungeon Crawling (Colorless)
The inhabitants of this plane tread with a light step.
Hard
Repeatable
28
Three colorless rares
150
Dungeon Crawling Colorless.jpg
[quest]
id=5
Icon=Dungeon Crawling Green.jpg
Title=Dungeon Crawling (Green)
Desc=Gnarled, twisting, sinister growths slowly rend the walls in twain and try to silence all who cross their path.
Diff=Medium
AILife=25
Repeat=true
Wins=20
Card Reward=3 green rares
Credit Reward=100
HumanExtras=Defense of the Heart
AIExtras=Eladamri's Vineyard|Upwelling
7
Dungeon Crawling (Gold)
Guarded by gold creatures.
Hard
Repeatable
28
Three multi-colored rares
150
Dungeon Crawling Gold.jpg
[quest]
id=6
Icon=Dungeon Crawling Colorless.jpg
Title=Dungeon Crawling (Colorless)
Desc=The inhabitants of this plane tread with a light step.
Diff=Hard
AILife=30
Repeat=true
Wins=28
Card Reward=3 colorless rares
Credit Reward=150
HumanExtras=
AIExtras=Eon Hub|Eon Hub|Eon Hub
8
A Wolf in Sheep's Clothing
The local sheep farm is under attack by a pack of wolves. Kill the wolves, save the sheep!
Medium
Not Repeatable
28
Three random rares
200
A Wolf in Sheeps Clothing.jpg
[quest]
id=7
Icon=Dungeon Crawling Gold.jpg
Title=Dungeon Crawling (Gold)
Desc=Clever sorcerers draw energy from countless sources - can you outwit them?
Diff=Hard
AILife=30
Repeat=true
Wins=28
Card Reward=3 multi-colored rares
Credit Reward=150
HumanExtras=
AIExtras=Darksteel Ingot
9
Bushwhacked!
You find yourself surrounded by carnivorous plants and poisonous vines. Cut your way out of this foresty mess and make it home safe.
Hard
Not Repeatable
40
Four green rares
225
Bushwhacked.jpg
[quest]
id=8
Icon=A Wolf in Sheeps Clothing.jpg
Title=A Wolf in Sheep's Clothing
Desc=The local sheep farm is under attack by a pack of wolves. Kill the wolves, save the sheep!
Diff=Medium
AILife=25
Repeat=false
Wins=28
Card Reward=3 random rares
Credit Reward=200
HumanExtras=TOKEN;G;0;1;Sheep;Creature;Sheep|TOKEN;G;0;1;Sheep;Creature;Sheep|TOKEN;G;0;1;Sheep;Creature;Sheep
AIExtras=
10
Zombie Attack!
The village of Haven is getting attacked by the Zombie horde! Protect the village.
Hard
Not Repeatable
40
Four black rares
200
Zombie Attack.jpg
[quest]
id=9
Icon=Bushwhacked.jpg
Title=Bushwhacked!
Desc=You find yourself surrounded by carnivorous plants and poisonous vines. Cut your way out of this foresty mess and make it home safe.
Diff=Hard
AILife=30
Repeat=false
Wins=40
Card Reward=4 green rares
Credit Reward=225
HumanExtras=Trusty Machete
AIExtras=Wall of Wood|Wall of Wood|Wall of Wood
11
The King's Contest
The king is holding a contest. You are invited to participate and compete against other legends of this era.
Hard
Not Repeatable
40
Three random rares
150
The Kings Contest.jpg
[quest]
id=10
Icon=Zombie Attack.jpg
Title=Zombie Attack!
Desc=The village of Haven is getting attacked by the Zombie horde! Protect the village.
Diff=Hard
AILife=30
Repeat=false
Wins=40
Card Reward=4 black rares
Credit Reward=200
HumanExtras=TOKEN;W;1;1;Citizen;Creature|TOKEN;W;1;1;Citizen;Creature|TOKEN;W;1;1;Citizen;Creature|Wall of Spears
AIExtras=Scathe Zombies|Mass of Ghouls
12
Barroom Brawl
A drunken giant of a man takes a swing at you, your brew spills and a fight breaks out.
Hard
Not Repeatable
64
Four random rares
250
Barroom Brawl.jpg
[quest]
id=11
Icon=The Kings Contest.jpg
Title=The King's Contest
Desc=The king is holding a contest. You are invited to participate and compete against other legends of this era.
Diff=Hard
AILife=30
Repeat=false
Wins=40
Card Reward=3 random rares
Credit Reward=150
HumanExtras=Seal of Cleansing
AIExtras=Loyal Retainers
13
The Court Jester
The Court Jester pulls a prank on you. Will you laugh it off or pay him back?
Hard
Not Repeatable
52
Four multi-colored rares
300
The Court Jester.jpg
[quest]
id=12
Icon=Barroom Brawl.jpg
Title=Barroom Brawl
Desc=A drunken giant of a man takes a swing at you, your brew spills and a fight breaks out.
Diff=Hard
AILife=30
Repeat=false
Wins=64
Card Reward=4 random rares
Credit Reward=250
HumanExtras=TOKEN;W;1;1;Soldier Ally;Creature;Soldier;Ally|TOKEN;W;1;1;Soldier Ally;Creature;Soldier;Ally|TOKEN;W;1;1;Soldier Ally;Creature;Soldier;Ally
AIExtras=Lowland Giant
14
Ancient Battlefield
You visit an ancient battlefield at midnight. It is overgrown and dark. You trip on a root, utter a curse and wish that you could see.
Hard
Not Repeatable
64
Four random rares
250
Ancient Battlefield.jpg
[quest]
id=13
Icon=The Court Jester.jpg
Title=The Court Jester
Desc=The Court Jester pulls a prank on you. Will you laugh it off or pay him back?
Diff=Hard
AILife=30
Repeat=false
Wins=52
Card Reward=4 multi-colored rares
Credit Reward=300
HumanExtras=Sensei's Divining Top
AIExtras=Teferi's Puzzle Box
15
Don't Play With Matches
The goblins are battling the elves. Those pesky elves, will they ever learn. Do not play with fire!
Hard
Not Repeatable
52
Four red rares
200
Dont Play With Matches.jpg
[quest]
id=14
Title=Ancient Battlefield
Desc=You visit an ancient battlefield at midnight. It is overgrown and dark. You trip on a root, utter a curse and wish that you could see.
Diff=Hard
AILife=30
Repeat=false
Wins=64
Card Reward=4 random rares
Credit Reward=250
Icon=Ancient Battlefield.jpg
HumanExtras=Glasses of Urza|Blight Sickle
AIExtras=Bad Moon|Wall of Brambles
16
Mines of Kazum Durl
While exploring a mine with a group of dwarves the mine caves in. You start to dig out and then realize that your group is not alone.
Hard
Not Repeatable
52
Four green rares
250
Mines of Kazum Durl.jpg
[quest]
id=15
Title=Don't Play With Matches
Desc=The goblins are battling the elves. Those pesky elves, will they ever learn. Do not play with fire!
Diff=Hard
AILife=30
Repeat=false
Wins=52
Card Reward=4 red rares
Credit Reward=200
Icon=Dont Play With Matches.jpg
HumanExtras=Mudbutton Torchrunner|Scuzzback Scrapper
AIExtras=Heedless One|Norwood Archers|Wildslayer Elves
17
House Party
Your friends decide to hold a house party at your home tonight. Later that night uninvited guests show up and disrupt the party.
Hard
Not Repeatable
64
Four colorless rares
250
House Party.jpg
[quest]
id=16
Title=Mines of Kazum Durl
Desc=While exploring a mine with a group of dwarves the mine caves in. You start to dig out and then realize that your group is not alone.
Diff=Hard
AILife=30
Repeat=false
Wins=52
Card Reward=4 green rares
Credit Reward=250
Icon=Mines of Kazum Durl.jpg
HumanExtras=Dwarven Demolition Team|Dwarven Pony|Dwarven Trader
AIExtras=Wall of Earth|Wall of Air|Wall of Ice|Wall of Light|Carrion Wall|Steel Wall
18
Crows in the Field
Crows are eating the seed planted in the local farm fields. The farmers are scared. Those crows are big, you will need some help.
Hard
Not Repeatable
64
Five random rares
300
Crows in the Field.jpg
[quest]
id=17
Title=House Party
Desc=Your friends decide to hold a house party at your home tonight. Later that night uninvited guests show up and disrupt the party.
Diff=Hard
AILife=30
Repeat=false
Wins=64
Card Reward=4 colorless rares
Credit Reward=250
Icon=House Party.jpg
HumanExtras=Hopping Automaton|Honden of Life's Web|Forbidden Orchard
AIExtras=Honden of Infinite Rage|Mikokoro, Center of the Sea
19
The Desert Caravan
A caravan is transporting silk across the desert. While setting up camp for the night you are attacked by thieves. Defend yourself.
Hard
Not Repeatable
80
Five random rares
300
The Desert Caravan.jpg
[quest]
id=18
Title=Crows in the Field
Desc=Crows are eating the seed planted in the local farm fields. The farmers are scared. Those crows are big, you will need some help.
Diff=Hard
AILife=30
Repeat=false
Wins=64
Card Reward=5 random rares
Credit Reward=300
Icon=Crows in the Field.jpg
HumanExtras=Straw Soldiers|Femeref Archers|Moonglove Extract
AIExtras=Defiant Falcon|Soulcatcher|Storm Crow|Hypnotic Specter
20
Blood Oath
A druid saves your life and the two of you take a blood oath. It is now time to fulfill your oath.
Hard
Not Repeatable
80
Five colorless rares
300
Blood Oath.jpg
[quest]
id=19
Title=The Desert Caravan
Desc=A caravan is transporting silk across the desert. While setting up camp for the night you are attacked by thieves. Defend yourself.
Diff=Hard
AILife=30
Repeat=false
Wins=80
Card Reward=5 random rares
Credit Reward=300
Icon=The Desert Caravan.jpg
HumanExtras=Spidersilk Net|Dromad Purebred
AIExtras=Ambush Party|Ambush Party|Ambush Party|Ambush Party|Gnat Alley Creeper
21
Private Domain
During your travels, you accidentally stumble upon the domain of an evil, powerful wizard. A fight to the death ensues.
Expert
Not Repeatable
96
Six random rares
500
Private Domain.jpg
22
The Pied Piper
A mysterious man threatens to flood the land with a relentless stream of hungry rats. Cross his plan before it's too late.
Hard
Not Repeatable
32
three random rares
150
The Pied Piper.jpg
[quest]
id=20
Title=Blood Oath
Desc=A druid saves your life and the two of you take a blood oath. It is now time to fulfill your oath.
Diff=Hard
AILife=30
Repeat=false
Wins=80
Card Reward=5 colorless rares
Credit Reward=300
Icon=Blood Oath.jpg
HumanExtras=Counterbalance|Hatching Plans|Ley Druid
AIExtras=Ior Ruin Expedition|Oversold Cemetery|Trapjaw Kelpie
End
[quest]
id=21
Title=Private Domain
Desc=During your travels, you accidentally stumble upon the domain of an evil, powerful wizard. A fight to the death ensues.
Diff=Expert
AILife=50
Repeat=false
Wins=96
Card Reward=6 random rares
Credit Reward=500
Icon=Private Domain.jpg
HumanExtras=Strip Mine
AIExtras=Plains|Island|Mountain|Swamp|Forest
[quest]
id=22
Title=The Pied Piper
Desc=A mysterious man threatens to flood the land with a relentless stream of hungry rats. Cross his plan before it's too late.
Diff=Hard
AILife=30
Repeat=false
Wins=32
Card Reward=3 random rares
Credit Reward=150
Icon=The Pied Piper.jpg
HumanExtras=Volunteer Militia|Land Tax|Elvish Farmer|An-Havva Township
AIExtras=Darksteel Citadel|Relentless Rats

View File

@@ -11,25 +11,25 @@ import forge.card.CardPrinted;
* @version $Id$
*/
public class Quest_Assignment {
private int id;
private int requiredNumberWins;
private int computerLife;
// ID (default -1, should be explicitly set at later time.)
private int id = -1;
private long creditsReward;
private String name;
private String desc;
private String difficulty;
private String cardReward;
private String iconName;
private boolean repeatable;
// Default vals if none provided for this ID in quests.txt.
private int requiredNumberWins = 20;
private int computerLife = 25;
private long creditsReward = 100;
private String name = "Mystery Quest";
private String desc = "";
private String difficulty = "Medium";
private String cardReward = "1 colorless rare";
private String iconName = "Unknown.jpg";
private boolean repeatable = false;
// Other cards used in assignment: starting, and reward.
private CardList humanExtraCards = new CardList();
private CardList aiExtraCards = new CardList();
private ArrayList<CardPrinted> cardRewardList = new ArrayList<CardPrinted>();
private CardList human = new CardList();
private ArrayList<String> compy = new ArrayList<String>();
/**
* <p>Setter for the field <code>id</code>.</p>
*
@@ -211,56 +211,48 @@ public class Quest_Assignment {
}
/**
* <p>Setter for the field <code>human</code>.</p>
* <p>Setter for the field <code>humanExtraCards</code>.</p>
*
* @param humanIn a {@link forge.CardList} object.
* @param s a CardList object.
*/
public final void setHuman(final CardList humanIn) {
this.human = humanIn;
public final void setHumanExtraCards(final CardList cl) {
this.humanExtraCards = cl;
}
/**
* <p>Getter for the field <code>human</code>.</p>
* <p>Getter for the field <code>humanExtraCards</code>.</p>
*
* @return a {@link forge.CardList} object.
*/
public final CardList getHuman() {
return human;
public final CardList getHumanExtraCards() {
return humanExtraCards;
}
/**
* <p>addCompy.</p>
* <p>Setter for the field <code>aiExtraCards</code>.</p>
*
* @param s a {@link java.lang.String} object.
* @param s a CardList object.
*/
public final void addCompy(final String s) {
this.compy.add(s);
public final void setAIExtraCards(final CardList cl) {
this.aiExtraCards = cl;
}
/**
* <p>clearCompy.</p>
*/
public final void clearCompy() {
this.compy.clear();
}
/**
* <p>Getter for the field <code>compy</code>.</p>
*
* @return a {@link java.util.ArrayList} object.
*/
public final ArrayList<String> getCompy() {
return compy;
public final CardList getAIExtraCards() {
return aiExtraCards;
}
/**
* <p>Setter for the field <code>cardRewardList</code>.</p>
*
* @param cardRewardListIn a {@link java.util.ArrayList} object.
* @return a {@link java.util.ArrayList} object.
*/
public final void setCardRewardList(final ArrayList<CardPrinted> cardRewardListIn) {
this.cardRewardList = cardRewardListIn;
public void setCardRewardList(final ArrayList<CardPrinted> cp) {
this.cardRewardList = cp;
}
/**
@@ -271,4 +263,5 @@ public class Quest_Assignment {
public final ArrayList<CardPrinted> getCardRewardList() {
return cardRewardList;
}
}

View File

@@ -2,14 +2,15 @@ package forge;
import forge.error.ErrorViewer;
import forge.properties.NewConstants;
import forge.quest.data.QuestUtil;
import java.io.BufferedReader;
import java.io.File;
import java.io.FileReader;
import java.io.IOException;
import java.util.ArrayList;
import java.util.List;
/**
* <p>ReadQuest_Assignment class.</p>
*
@@ -17,60 +18,31 @@ import java.util.List;
* @version $Id$
*/
public class ReadQuest_Assignment implements Runnable, NewConstants {
private BufferedReader in;
ArrayList<Quest_Assignment> allQuests = new ArrayList<Quest_Assignment>();
ArrayList<Quest_Assignment> allQuests = new ArrayList<Quest_Assignment>();
private ArrayList<Integer> ids = new ArrayList<Integer>();
private BufferedReader br;
private int totalWins;
private List<Integer> completedQuests = new ArrayList<Integer>();
/**
* <p>getQuests.</p>
*
* @return a {@link java.util.List} object.
*/
public List<Quest_Assignment> getQuests() {
return new ArrayList<Quest_Assignment>(allQuests);
}
/**
* <p>getQuestsByIds.</p>
*
* @param availableQuestIds a {@link java.util.List} object.
* @return a {@link java.util.List} object.
*/
public List<Quest_Assignment> getQuestsByIds(List<Integer> availableQuestIds) {
List<Quest_Assignment> quests = new ArrayList<Quest_Assignment>();
for (Quest_Assignment qa : allQuests) {
if (availableQuestIds.contains(qa.getId()))
quests.add(qa);
}
return quests;
}
/**
* <p>getQuestById.</p>
*
* @param i a int.
* @return a {@link forge.Quest_Assignment} object.
*/
public Quest_Assignment getQuestById(int i) {
for (Quest_Assignment qa : allQuests) {
if (qa.getId() == i)
return qa;
}
return null;
}
/*
public Quest_Assignment getQuestById(int id) {
return allQuests.get(id);
}
*/
// Constants, tied to properties in the quests.txt file.
private static final String ID = "id";
private static final String ICON = "Icon";
private static final String TITLE = "Title";
private static final String DESC = "Desc";
private static final String DIFF = "Diff";
private static final String AILIFE = "AILife";
private static final String REPEAT = "Repeat";
private static final String WINS = "Wins";
private static final String CARDS = "Card Reward";
private static final String CREDITS = "Credit Reward";
private static final String HUMANEXTRAS = "HumanExtras";
private static final String AIEXTRAS = "AIExtras";
/**
* <p>Constructor for ReadQuest_Assignment.</p>
* Sets parameters for available quests and prepares buffered reader for quests.txt.
*
* @param filename a {@link java.lang.String} object.
* @param questData a {@link forge.quest.data.QuestData} object.
@@ -81,128 +53,226 @@ public class ReadQuest_Assignment implements Runnable, NewConstants {
/**
* <p>Constructor for ReadQuest_Assignment.</p>
* Sets parameters for available quests and prepares buffered reader for quests.txt.
*
* @param file a {@link java.io.File} object.
* @param questData a {@link forge.quest.data.QuestData} object.
*/
public ReadQuest_Assignment(File file, forge.quest.data.QuestData questData) {
if (questData != null) {
totalWins = questData.getWin();
if (questData.getCompletedQuests() != null)
if (questData.getCompletedQuests() != null) {
completedQuests = questData.getCompletedQuests();
else
}
else {
completedQuests = new ArrayList<Integer>();
}
}
if (!file.exists())
throw new RuntimeException("ReadQuest_Assignment : constructor error -- file not found -- filename is "
+ file.getAbsolutePath());
//makes the checked exception, into an unchecked runtime exception
try {
in = new BufferedReader(new FileReader(file));
br = new BufferedReader(new FileReader(file));
} catch (Exception ex) {
ErrorViewer.showError(ex, "File \"%s\" not found", file.getAbsolutePath());
throw new RuntimeException("ReadQuest_Assignment : constructor error -- file not found -- filename is "
+ file.getPath());
throw new RuntimeException("ReadQuest_Assignment > constructor error: "+
"BufferedReader failed, '"+file.getAbsolutePath()+"' not found.");
}
}//ReadCard()
} // ReadQuest_Assignment()
/* id
* name
* desc
* difficulty
* repeatable
* numberWinsRequired
* cardReward
* creditsReward
/**
* <p>getQuests.</p>
* Returns list of currently available quest objects.
*
* @return a {@link java.util.List} object.
*/
public List<Quest_Assignment> getQuests() {
ArrayList<Quest_Assignment> availableQuests = new ArrayList<Quest_Assignment>();
for(Quest_Assignment qa : allQuests) {
if (qa.getRequiredNumberWins() <= totalWins && !completedQuests.contains(qa.getId())) {
availableQuests.add(qa);
}
}
return availableQuests;
}
/**
* <p>getQuests.</p>
* Returns complete list of all quest objects.
*
* @return a {@link java.util.List} object.
*/
public List<Quest_Assignment> getAllQuests() {
return allQuests;
}
/**
* <p>getQuestsByIds.</p>
*
* @param availableQuestIds a {@link java.util.List} object.
* @return a {@link java.util.List} object.
*/
public List<Quest_Assignment> getQuestsByIds(List<Integer> availableQuestIds) {
List<Quest_Assignment> q = new ArrayList<Quest_Assignment>();
for (Quest_Assignment qa : allQuests) {
if (availableQuestIds.contains(qa.getId())) {
q.add(qa);
}
}
return q;
}
/**
* <p>getQuestById.</p>
*
* @param i a int.
* @return a {@link forge.Quest_Assignment} object.
*/
public Quest_Assignment getQuestById(int id) {
// Error handling for OOB ID?
return allQuests.get(id);
}
/**
* <p>run.</p>
* Assembles Quest_Assignment instances into allQuests.
*/
public void run() {
Quest_Assignment qa;
String s = readLine();
ArrayList<Integer> ids = new ArrayList<Integer>();
Quest_Assignment qa = null;
String line;
int i;
String[] linedata;
while (!s.equals("End")) {
try {
while ((line = br.readLine()) != null) {
if(line.equals("[quest]")) {
qa = new Quest_Assignment();
if (s.equals("")) throw new RuntimeException("ReadQuest_Assignment : run() reading error, id is blank");
int id = Integer.parseInt(s);
qa.setId(id);
s = readLine();
qa.setName(s);
s = readLine();
qa.setDesc(s);
s = readLine();
qa.setDifficulty(s);
if (qa.getDifficulty().equals("Medium"))
qa.setComputerLife(25);
else if (qa.getDifficulty().equals("Hard"))
qa.setComputerLife(30);
else if (qa.getDifficulty().equals("Very Hard"))
qa.setComputerLife(35);
else if (qa.getDifficulty().equals("Expert"))
qa.setComputerLife(50);
else if (qa.getDifficulty().equals("Insane"))
qa.setComputerLife(100);
s = readLine();
qa.setRepeatable(s.equals("Repeatable"));
s = readLine();
int wins = Integer.valueOf(s);
qa.setRequiredNumberWins(wins);
s = readLine();
qa.setCardReward(s);
s = readLine();
long reward = Long.parseLong(s.trim());
qa.setCreditsReward(reward);
s = readLine();
qa.setIconName(s);
//s = readLine();
s = readLine();
if (ids.contains(qa.getId())) {
System.out.println("ReadQuest_Assignment:run() error - duplicate card name: " + qa.getId());
throw new RuntimeException("ReadQuest_Assignment:run() error - duplicate card name: " + qa.getId());
}
ids.add(qa.getId());
if (qa.getRequiredNumberWins() <= totalWins && !completedQuests.contains(qa.getId())) {
forge.quest.data.QuestUtil.setupQuest(qa);
allQuests.add(qa);
}
else if(!line.equals("") && qa != null) {
linedata = line.split("=", 2);
linedata[1] = linedata[1].trim();
//id:
s = readLine();
// If empty data, ignore the line (assignment will use default).
if(linedata[1].equals("")) {
continue;
}
}//run()
/**
* <p>readLine.</p>
*
* @return a {@link java.lang.String} object.
*/
private String readLine() {
//makes the checked exception, into an unchecked runtime exception
try {
String s = in.readLine();
if (s != null) s = s.trim();
return s;
} catch (Exception ex) {
ErrorViewer.showError(ex);
throw new RuntimeException("ReadQuest_Assignment: readLine(Quest_Assignment) error");
// Data OK.
if(linedata[0].equals(ID)) {
i = Integer.parseInt(linedata[1]);
// Duplicate ID check
if(ids.contains(i)) {
throw new RuntimeException("ReadQuest_Assignment > run() error: duplicate quest ID ("+i+")");
}
}//readLine(Quest_Assignment)
// Non-sequential ID check
else if(i != allQuests.size()) {
throw new RuntimeException("ReadQuest_Assignment > run() error: non-sequential quest ID ("+i+")");
}
// ID OK.
else {
ids.add(i);
qa.setId(i);
}
}
else if(linedata[0].equals(ICON)) {
qa.setIconName(linedata[1]);
}
else if(linedata[0].equals(TITLE)) {
qa.setName(linedata[1]);
}
else if(linedata[0].equals(DESC)) {
qa.setDesc(linedata[1]);
}
else if(linedata[0].equals(DIFF)) {
qa.setDifficulty(linedata[1]);
}
else if(linedata[0].equals(REPEAT)) {
qa.setRepeatable(Boolean.parseBoolean(linedata[1]));
}
else if(linedata[0].equals(AILIFE)) {
qa.setComputerLife(Integer.parseInt(linedata[1]));
}
else if(linedata[0].equals(WINS)) {
qa.setRequiredNumberWins(Integer.parseInt(linedata[1]));
}
else if(linedata[0].equals(CREDITS)) {
qa.setCreditsReward(Integer.parseInt(linedata[1]));
}
// Card reward list assembled here.
else if(linedata[0].equals(CARDS)) {
qa.setCardReward(linedata[1]);
qa.setCardRewardList(QuestUtil.generateCardRewardList(linedata[1]));
}
// Human extra card list assembled here.
else if(linedata[0].equals(HUMANEXTRAS)) {
String[] names = linedata[1].split("\\|");
CardList templist = new CardList();
Card tempcard;
for(String s : names) {
// Token card creation
if(s.substring(0,5).equals("TOKEN")) {
tempcard = QuestUtil.createToken(s);
tempcard.addController(AllZone.getHumanPlayer());
tempcard.setOwner(AllZone.getHumanPlayer());
templist.add(tempcard);
}
// Standard card creation
else {
tempcard = AllZone.getCardFactory().getCard(s, AllZone.getHumanPlayer());
tempcard.setCurSetCode(tempcard.getMostRecentSet());
tempcard.setImageFilename(CardUtil.buildFilename(tempcard));
templist.add(tempcard);
}
}
qa.setHumanExtraCards(templist);
}
// AI extra card list assembled here.
else if(linedata[0].equals(AIEXTRAS)) {
String[] names = linedata[1].split("\\|");
CardList templist = new CardList();
Card tempcard;
for(String s : names) {
// Token card creation
if(s.substring(0,5).equals("TOKEN")) {
tempcard = QuestUtil.createToken(s);
tempcard.addController(AllZone.getComputerPlayer());
tempcard.setOwner(AllZone.getComputerPlayer());
templist.add(tempcard);
}
// Standard card creation
else {
tempcard = AllZone.getCardFactory().getCard(s, AllZone.getComputerPlayer());
tempcard.setCurSetCode(tempcard.getMostRecentSet());
tempcard.setImageFilename(CardUtil.buildFilename(tempcard));
templist.add(tempcard);
}
}
qa.setAIExtraCards(templist);
}
} // else if()
} // while()
br.close();
}
catch (IOException e) {
e.printStackTrace();
}
// Confirm that all quests have IDs.
for(Quest_Assignment q : allQuests) {
if(q.getId()==-1) {
throw new RuntimeException("ReadQuest_Assignment > getQuests() error: "+
"Quest ID missing for '"+q.getName()+"'.");
}
}
} // run()
}

View File

@@ -1,6 +1,10 @@
package forge.quest.data;
import forge.*;
import forge.Card;
import forge.CardList;
import forge.Constant;
import forge.Quest_Assignment;
import forge.card.CardPrinted;
import forge.card.CardRarity;
import java.util.ArrayList;
@@ -25,6 +29,7 @@ public class QuestUtil {
/**
* <p>getComputerCreatures.</p>
* Returns extra AI cards in play at start of quest.
*
* @param qd a {@link forge.quest.data.QuestData} object.
* @param qa a {@link forge.Quest_Assignment} object.
@@ -32,23 +37,16 @@ public class QuestUtil {
*/
public static CardList getComputerCreatures(final QuestData qd, Quest_Assignment qa) {
CardList list = new CardList();
if (qa != null) {
ArrayList<String> compCards = qa.getCompy();
for (String s : compCards) {
Card c = AllZone.getCardFactory().getCard(s, AllZone.getComputerPlayer());
c.setCurSetCode(c.getMostRecentSet());
c.setImageFilename(CardUtil.buildFilename(c));
list.add(c);
}
list.addAll(qa.getAIExtraCards());
}
return list;
}
/**
* <p>getHumanPlantAndPet.</p>
* Returns list of current plant/pet configuration.
*
* @param qd a {@link forge.quest.data.QuestData} object.
* @return a {@link forge.CardList} object.
@@ -69,6 +67,8 @@ public class QuestUtil {
/**
* <p>getHumanPlantAndPet.</p>
* Returns extra human cards, including current plant/pet configuration,
* and cards in play at start of quest.
*
* @param qd a {@link forge.quest.data.QuestData} object.
* @param qa a {@link forge.Quest_Assignment} object.
@@ -78,417 +78,101 @@ public class QuestUtil {
CardList list = getHumanPlantAndPet(qd);
if (qa != null) {
list.addAll(qa.getHuman());
list.addAll(qa.getHumanExtraCards());
}
return list;
}
/**
* <p>createToken.</p>
* Creates a card instance for token defined by property string.
*
* @param s Properties string of token (TOKEN;W;1;1;sheep;type;type;type...)
* @return token Card
*/
public static Card createToken(String s) {
String[] properties = s.split(";");;
Card c = new Card();
c.setToken(true);
//c.setManaCost(properties[1]);
c.addColor(properties[1]);
c.setBaseAttack(Integer.parseInt(properties[2]));
c.setBaseDefense(Integer.parseInt(properties[3]));
c.setName(properties[4]);
c.setImageName(
properties[1]+" "+
properties[2]+" "+
properties[3]+" "+
properties[4]
);
int x = 5;
while(x != properties.length) {
c.addType(properties[x++]);
}
return c;
}
/**
* <p>generateCardRewardList.</p>
* Takes a reward list string, parses, and returns list of cards rewarded.
*
* @param s Properties string of reward (97 multicolor rares)
* @return CardList
*/
public static ArrayList<CardPrinted> generateCardRewardList(String s) {
QuestBoosterPack pack = new QuestBoosterPack();
String[] temp = s.split(" ");
int qty = Integer.parseInt(temp[0]);
// Determine rarity
CardRarity rar = CardRarity.Uncommon;
if(temp[1].equals("rare") || temp[1].equals("rares")) {
rar = CardRarity.Rare;
}
// Determine color ("random" defaults to null color)
String col = null;
if(temp[2].toLowerCase().equals("black")) {
col = Constant.Color.Black;
}
else if(temp[2].toLowerCase().equals("blue")) {
col = Constant.Color.Blue;
}
else if(temp[2].toLowerCase().equals("colorless")) {
col = Constant.Color.Colorless;
}
else if(temp[2].toLowerCase().equals("green")) {
col = Constant.Color.Green;
}
else if(temp[2].toLowerCase().equals("multicolor")) {
col = "Multicolor"; // Note: No constant color for this??
}
else if(temp[2].toLowerCase().equals("red")) {
col = Constant.Color.Red;
}
else if(temp[2].toLowerCase().equals("white")) {
col = Constant.Color.White;
}
return pack.generateCards(qty, rar, col);
}
/**
* <p>setupQuest.</p>
* Assembled hard-coded quest options.
* All non-deck-specific handling now takes place in quests.txt.
*
* @param qa a {@link forge.Quest_Assignment} object.
* @deprecated
* @param qa
*/
public static void setupQuest(Quest_Assignment qa) {
QuestBoosterPack pack = new QuestBoosterPack();
qa.clearCompy();
int id = qa.getId();
if (id == 1) //White Dungeon
{
qa.addCompy("Divine Presence");
qa.setCardRewardList(pack.generateCards(3, CardRarity.Rare, Constant.Color.White));
} else if (id == 2) //Blue Dungeon
{
CardList humanList = new CardList();
Card c = AllZone.getCardFactory().getCard("Quest for Ancient Secrets", AllZone.getHumanPlayer());
c.setCurSetCode(c.getMostRecentSet());
c.setImageFilename(CardUtil.buildFilename(c));
humanList.add(c);
qa.setHuman(humanList);
qa.addCompy("Forced Fruition");
qa.setCardRewardList(pack.generateCards(3, CardRarity.Rare, Constant.Color.Blue));
} else if (id == 3) //Black Dungeon
{
qa.addCompy("Infernal Genesis");
qa.setCardRewardList(pack.generateCards(3, CardRarity.Rare, Constant.Color.Black));
} else if (id == 4) //Red Dungeon
{
qa.addCompy("Furnace of Rath");
qa.setCardRewardList(pack.generateCards(3, CardRarity.Rare, Constant.Color.Red));
} else if (id == 5) //Green Dungeon
{
CardList humanList = new CardList();
Card c = AllZone.getCardFactory().getCard("Defense of the Heart", AllZone.getHumanPlayer());
c.setCurSetCode(c.getMostRecentSet());
c.setImageFilename(CardUtil.buildFilename(c));
humanList.add(c);
qa.setHuman(humanList);
qa.addCompy("Eladamri's Vineyard");
qa.addCompy("Upwelling");
qa.setCardRewardList(pack.generateCards(3, CardRarity.Rare, Constant.Color.Green));
} else if (id == 6) //Colorless Dungeon
{
for (int i = 0; i < 3; i++)
qa.addCompy("Eon Hub");
qa.setCardRewardList(pack.generateCards(3, CardRarity.Rare, Constant.Color.Colorless));
} else if (id == 7) //Gold Dungeon
{
qa.addCompy("Darksteel Ingot");
qa.setCardRewardList(pack.generateCards(3, CardRarity.Rare, "Multicolor"));
} else if (id == 8) {
CardList humanList = new CardList();
for (int i = 0; i < 3; i++) {
//CANNOT use makeToken because of WheneverKeyword
Card c = new Card();
c.setName("Sheep");
c.setImageName("G 0 1 Sheep");
c.addController(AllZone.getHumanPlayer());
c.setOwner(AllZone.getHumanPlayer());
//c.setManaCost("G");
c.addColor("G");
c.setToken(true);
c.addType("Creature");
c.addType("Sheep");
c.setBaseAttack(0);
c.setBaseDefense(1);
humanList.add(c);
}
qa.setHuman(humanList);
qa.setCardRewardList(pack.generateCards(3, CardRarity.Rare, null));
} else if (id == 9) {
CardList humanList = new CardList();
Card c = AllZone.getCardFactory().getCard("Trusty Machete", AllZone.getHumanPlayer());
c.setCurSetCode(c.getMostRecentSet());
c.setImageFilename(CardUtil.buildFilename(c));
humanList.add(c);
qa.setHuman(humanList);
for (int i = 0; i < 3; i++)
qa.addCompy("Wall of Wood");
qa.setCardRewardList(pack.generateCards(4, CardRarity.Rare, Constant.Color.Green));
} else if (id == 10) {
CardList humanList = new CardList();
Card crd = AllZone.getCardFactory().getCard("Wall of Spears", AllZone.getHumanPlayer());
crd.setCurSetCode(crd.getMostRecentSet());
crd.setImageFilename(CardUtil.buildFilename(crd));
humanList.add(crd);
for (int i = 0; i < 3; i++) {
Card c = new Card();
c.setName("Citizen");
c.setImageName("W 1 1 Citizen");
c.addController(AllZone.getHumanPlayer());
c.setOwner(AllZone.getHumanPlayer());
c.setManaCost("W");
c.addColor("W");
c.setToken(true);
c.addType("Creature");
c.addType("Citizen");
c.setBaseAttack(1);
c.setBaseDefense(1);
humanList.add(c);
}
qa.setHuman(humanList);
for (int i = 0; i < 3; i++)
qa.addCompy("Scathe Zombies");
qa.addCompy("Mass of Ghouls");
qa.setCardRewardList(pack.generateCards(4, CardRarity.Rare, Constant.Color.Black));
} else if (id == 11) // The King's Contest
{
CardList humanList = new CardList();
Card c = AllZone.getCardFactory().getCard("Seal of Cleansing", AllZone.getHumanPlayer());
c.setCurSetCode(c.getMostRecentSet());
c.setImageFilename(CardUtil.buildFilename(c));
humanList.add(c);
qa.setHuman(humanList);
qa.addCompy("Loyal Retainers");
qa.setCardRewardList(pack.generateCards(3, CardRarity.Rare, null));
} else if (id == 12) // Barroom Brawl
{
CardList humanList = new CardList();
for (int i = 0; i < 3; i++) {
Card c = new Card();
c.setName("Soldier Ally");
c.setImageName("W 1 1 Soldier Ally");
c.addController(AllZone.getHumanPlayer());
c.setOwner(AllZone.getHumanPlayer());
c.setManaCost("W");
c.addColor("W");
c.setToken(true);
c.addType("Creature");
c.addType("Soldier");
c.addType("Ally");
c.setBaseAttack(1);
c.setBaseDefense(1);
humanList.add(c);
}
qa.setHuman(humanList);
qa.addCompy("Lowland Giant");
qa.setCardRewardList(pack.generateCards(4, CardRarity.Rare, null));
} else if (id == 13) // The Court Jester
{
CardList humanList = new CardList();
Card c = AllZone.getCardFactory().getCard("Sensei's Divining Top", AllZone.getHumanPlayer());
c.setCurSetCode(c.getMostRecentSet());
c.setImageFilename(CardUtil.buildFilename(c));
humanList.add(c);
qa.setHuman(humanList);
qa.addCompy("Teferi's Puzzle Box");
qa.setCardRewardList(pack.generateCards(4, CardRarity.Rare, "Multicolor"));
} else if (id == 14) // Ancient Battlefield
{
CardList humanList = new CardList();
String humanSetupCards[] = {"Glasses of Urza", "Blight Sickle"};
for (int i = 0; i < 2; i++) {
Card c = AllZone.getCardFactory().getCard(humanSetupCards[i], AllZone.getHumanPlayer());
c.setCurSetCode(c.getMostRecentSet());
c.setImageFilename(CardUtil.buildFilename(c));
humanList.add(c);
}
qa.setHuman(humanList);
String compySetupCards[] = {"Bad Moon", "Wall of Brambles"};
for (int i = 0; i < 2; i++) {
qa.addCompy(compySetupCards[i]);
}
qa.setCardRewardList(pack.generateCards(4, CardRarity.Rare, null));
} else if (id == 15) // Don't Play With Matches
{
CardList humanList = new CardList();
String humanSetupCards[] = {"Mudbutton Torchrunner", "Scuzzback Scrapper"};
for (int i = 0; i < 2; i++) {
Card c = AllZone.getCardFactory().getCard(humanSetupCards[i], AllZone.getHumanPlayer());
c.setCurSetCode(c.getMostRecentSet());
c.setImageFilename(CardUtil.buildFilename(c));
humanList.add(c);
}
qa.setHuman(humanList);
String compySetupCards[] = {"Heedless One", "Norwood Archers", "Wildslayer Elves"};
for (int i = 0; i < 3; i++) {
qa.addCompy(compySetupCards[i]);
}
qa.setCardRewardList(pack.generateCards(4, CardRarity.Rare, Constant.Color.Red));
} else if (id == 16) // Mines of Kazum Durl
{
CardList humanList = new CardList();
String[] humanSetupCards = {"Dwarven Demolition Team", "Dwarven Pony", "Dwarven Trader"};
for (int i = 0; i < 3; i++) {
Card c = AllZone.getCardFactory().getCard(humanSetupCards[i], AllZone.getHumanPlayer());
c.setCurSetCode(c.getMostRecentSet());
c.setImageFilename(CardUtil.buildFilename(c));
humanList.add(c);
}
qa.setHuman(humanList);
String[] compySetupCards =
{"Wall of Earth", "Wall of Air", "Wall of Ice", "Wall of Light", "Carrion Wall", "Steel Wall"};
for (int i = 0; i < 6; i++) {
qa.addCompy(compySetupCards[i]);
}
qa.setCardRewardList(pack.generateCards(4, CardRarity.Rare, Constant.Color.Green));
} else if (id == 17) // House Party
{
CardList humanList = new CardList();
String[] humanSetupCards = {"Hopping Automaton", "Honden of Life's Web", "Forbidden Orchard"};
for (int i = 0; i < 3; i++) {
Card c = AllZone.getCardFactory().getCard(humanSetupCards[i], AllZone.getHumanPlayer());
c.setCurSetCode(c.getMostRecentSet());
c.setImageFilename(CardUtil.buildFilename(c));
humanList.add(c);
}
qa.setHuman(humanList);
String[] compySetupCards = {"Honden of Infinite Rage", "Mikokoro, Center of the Sea", "Tidehollow Strix"};
for (int i = 0; i < 3; i++) {
qa.addCompy(compySetupCards[i]);
}
qa.setCardRewardList(pack.generateCards(4, CardRarity.Rare, Constant.Color.Colorless));
} else if (id == 18) // Crows in the Field
{
CardList humanList = new CardList();
String[] humanSetupCards = {"Straw Soldiers", "Femeref Archers", "Moonglove Extract"};
for (int i = 0; i < 3; i++) {
Card c = AllZone.getCardFactory().getCard(humanSetupCards[i], AllZone.getHumanPlayer());
c.setCurSetCode(c.getMostRecentSet());
c.setImageFilename(CardUtil.buildFilename(c));
humanList.add(c);
}
qa.setHuman(humanList);
String[] compySetupCards = {"Defiant Falcon", "Soulcatcher", "Storm Crow", "Hypnotic Specter"};
for (int i = 0; i < 4; i++) {
qa.addCompy(compySetupCards[i]);
}
qa.setCardRewardList(pack.generateCards(5, CardRarity.Rare, null));
} else if (id == 19) // The Desert Caravan
{
CardList humanList = new CardList();
String[] humanSetupCards = {"Spidersilk Net", "Dromad Purebred"};
for (int i = 0; i < 2; i++) {
Card c = AllZone.getCardFactory().getCard(humanSetupCards[i], AllZone.getHumanPlayer());
c.setCurSetCode(c.getMostRecentSet());
c.setImageFilename(CardUtil.buildFilename(c));
humanList.add(c);
}
qa.setHuman(humanList);
String[] compySetupCards = {"Ambush Party", "Ambush Party", "Gnat Alley Creeper", "Ambush Party", "Ambush Party"};
for (int i = 0; i < 5; i++) {
qa.addCompy(compySetupCards[i]);
}
qa.setCardRewardList(pack.generateCards(5, CardRarity.Rare, null));
} else if (id == 20) // Blood Oath
{
CardList humanList = new CardList();
String[] humanSetupCards = {"Counterbalance", "Hatching Plans", "Ley Druid"};
for (int i = 0; i < 3; i++) {
Card c = AllZone.getCardFactory().getCard(humanSetupCards[i], AllZone.getHumanPlayer());
c.setCurSetCode(c.getMostRecentSet());
c.setImageFilename(CardUtil.buildFilename(c));
humanList.add(c);
}
qa.setHuman(humanList);
String[] compySetupCards = {"Ior Ruin Expedition", "Oversold Cemetery", "Trapjaw Kelpie"};
for (int i = 0; i < 3; i++) {
qa.addCompy(compySetupCards[i]);
}
qa.setCardRewardList(pack.generateCards(5, CardRarity.Rare, Constant.Color.Colorless));
} else if (id == 21) // Private Domain
{
CardList humanList = new CardList();
Card c = AllZone.getCardFactory().getCard("Strip Mine", AllZone.getHumanPlayer());
c.setCurSetCode(c.getMostRecentSet());
c.setImageFilename(CardUtil.buildFilename(c));
humanList.add(c);
qa.setHuman(humanList);
String[] compySetupCards = {"Plains", "Island", "Swamp", "Mountain", "Forest"};
for (int i = 0; i < 5; i++) {
qa.addCompy(compySetupCards[i]);
}
qa.setCardRewardList(pack.generateCards(6, CardRarity.Rare, null));
} else if (id == 22) // Pied Piper
{
CardList humanList = new CardList();
String[] humanSetupCards = {"Volunteer Militia", "Land Tax", "Elvish Farmer", "An-Havva Township"};
for (int i = 0; i < 4; i++) {
Card c = AllZone.getCardFactory().getCard(humanSetupCards[i], AllZone.getHumanPlayer());
c.setCurSetCode(c.getMostRecentSet());
c.setImageFilename(CardUtil.buildFilename(c));
humanList.add(c);
}
qa.setHuman(humanList);
String[] compySetupCards = {"Darksteel Citadel", "Relentless Rats"};
for (int i = 0; i < 2; i++) {
qa.addCompy(compySetupCards[i]);
}
qa.setCardRewardList(pack.generateCards(3, CardRarity.Rare, null));
}
}