Renamed "shopping" to CardGen

Fixed some word wrapping and off the end run
Added font choices
Added tech for changing background colour eventually
master
silverwizard 4 years ago
parent f88e2bc339
commit 6383e25554
  1. 17
      CardGen.pl
  2. 337
      shopping.yml

@ -5,24 +5,25 @@ use Text::Wrap;
$Text::Wrap::columns = 30; $Text::Wrap::columns = 30;
my $cards = LoadFile('shopping.yml'); my $cards = LoadFile('shopping.yml');
my @card_table; $bgcolour = $cards->{Deck}->{Background};
foreach my $card (keys %{$cards->{Cards}}){ $mainfont = $cards->{Deck}->{Font};
foreach my $card (keys %{$cards->{Deck}->{Cards}}){
my $image = Image::Magick->new(size=>'600x825'); my $image = Image::Magick->new(size=>'600x825');
$image->ReadImage('canvas:white'); $image->ReadImage('canvas:white');
$image->Draw(stroke=>'red', fill => 'none', strokewidth=>1, primitive=>'rectangle', points=>'38,38 562,787'); $image->Draw(stroke=>'red', fill => 'none', strokewidth=>1, primitive=>'rectangle', points=>'38,38 562,787');
my $surface = Image::Magick->new; my $surface = Image::Magick->new;
$surface->ReadImage('surface-p17.jpg');
$surface->Rotate(90); $surface->Rotate(90);
$surface->Resize('600x825!'); $surface->Resize('600x825!');
$image->Composite(compose => 'over', image => $surface, x => 0, y => 0); $image->Composite(compose => 'over', image => $surface, x => 0, y => 0);
$image->Annotate(text => $card, font => 'Courier.ttf', y => -275, fill => 'black', pointsize => 70, gravity => 'Center');
my $text; my $text;
$image->Set(font => 'Courier', pointsize => 25); $image->Set(font => $mainfont, pointsize => 25);
foreach my $line (@{$cards->{Cards}->{$card}}){ foreach my $line (@{$cards->{Deck}->{Cards}->{$card}}){
$text = $text . wrap('', '', $line) . "\n"; $text = $text . wrap('', '', $line) . "\n";
} }
$image->Annotate(text => $card, x => 50, y => 100, font => 'Courier', fill => 'black', pointsize => 35); $image->Annotate(text => $card, x => 50, y => 100, font => $mainfont, fill => 'black', pointsize => 60);
$image->Annotate(text => $text, x => 50, y => 600, font => 'Courier', fill => 'black', pointsize => 25); my $newlines = () = $text =~ /(\n)/g;
$image->Annotate(text => $text, x => 50, y => (750-(25*$newlines)), font => $mainfont, fill => 'black', pointsize => 25);
$image->Write($card . '.png'); $image->Write($card . '.png');
} }

@ -1,168 +1,169 @@
Cards: Deck:
Leg Boost: Background: White
- Grants +1d6 when jumping Font: Courier
- Cyber Cards:
Finger Blade: Leg Boost:
- Adds +1d4 damage - Grants +1d6 when jumping
- Cyber - Cyber
Subcutaenous Mic: Finger Blade:
- Allows speaking while sneaking - Adds +1d4 damage
- Cyber - Cyber
Cyberarm: Subcutaenous Mic:
- Adds +1d8 damage - Allows speaking while sneaking
- Lifting tests are 1d10 - Cyber
- Cyber Cyberarm:
Light Pistol: - Adds +1d8 damage
- 1d10 to hit - Lifting tests are 1d10
- 1d8 damage - Cyber
- Gun Light Pistol:
Heavy Pistol: - 1d10 to hit
- 1d8 to hit - 1d8 damage
- 1d10 damage - Gun
- Gun Heavy Pistol:
Rifle: - 1d8 to hit
- Opponents get +1d4 in Melee - 1d10 damage
- 1d10 to hit - Gun
- 1d10 damage Rifle:
- Gun - Opponents get +1d4 in Melee
Sniper Rifle: - 1d10 to hit
- Opponents get +1d10 to hit in Melee - 1d10 damage
- 1d12 to hit - Gun
- 1d12 damage Sniper Rifle:
- Double damage when you have surprise - Opponents get +1d10 to hit in Melee
- Gun - 1d12 to hit
Heavy Jacket: - 1d12 damage
- Subtract 1d6 from incoming damage - Double damage when you have surprise
- Armour - Gun
Riot Armour: Heavy Jacket:
- Subtracts 1d8 from incoming damage - Subtract 1d6 from incoming damage
- Adds 1d4 to opponent's melee attacks - Armour
- Armour Riot Armour:
Adrenal Boost: - Subtracts 1d8 from incoming damage
- Subtracts 1d4 from incoming melee attacks - Adds 1d4 to opponent's melee attacks
- Cyber, Armour - Armour
Subcutaneous Plating: Adrenal Boost:
- Subtacts 1d4 from incoming damage - Subtracts 1d4 from incoming melee attacks
- Cyber, Armour - Cyber, Armour
Cyberdeck: Subcutaneous Plating:
- 1d8 to all hacking rolls - Subtacts 1d4 from incoming damage
- Computer - Cyber, Armour
Candy Wrapper: Cyberdeck:
- 1d10 to stealth while hacking - 1d8 to all hacking rolls
- Program - Computer
Commlink: Candy Wrapper:
- Computer - 1d10 to stealth while hacking
Common Handgun: - Program
- Gun Commlink:
Hammer: - Computer
- 1d10 damage while hacking Common Handgun:
- Program - Gun
Ammo: Hammer:
- Can only be used with one gun at a time - 1d10 damage while hacking
- If you roll all 1s (after specialties), you have run out of ammo. - Program
- Ammo Ammo:
Nice Suit: - Can only be used with one gun at a time
- +1d4 to social rolls with people who care about dress - If you roll all 1s (after specialties), you have run out of ammo.
- Destroyed if you take 3 or more damage - Ammo
- Armour Nice Suit:
Nice Meal: - +1d4 to social rolls with people who care about dress
- Can be eaten in place of one paste - Destroyed if you take 3 or more damage
- Can be spent for its value in paste - Armour
- +1d4 to any social roll when you spend this (even if you are getting its value) Nice Meal:
- Food - Can be eaten in place of one paste
First Aid Kit: - Can be spent for its value in paste
- Allows bandaging rolls - +1d4 to any social roll when you spend this (even if you are getting its value)
Stim Pack: - Food
- Heals 1d4 HP, which are removed after two hours First Aid Kit:
- Losing these HP can drop you below 0 - Allows bandaging rolls
Medical Bench: Stim Pack:
- Requires an hour of work - Heals 1d4 HP, which are removed after two hours
- Recovers 1d4 HP (specialities can apply to this roll) - Losing these HP can drop you below 0
Drug Injector: Medical Bench:
- Allows drug injection without an action - Requires an hour of work
- Cyber - Recovers 1d4 HP (specialities can apply to this roll)
Targetting Coprocessor: Drug Injector:
- Steps up the die to hit for guns - Allows drug injection without an action
- Cyber - Cyber
Soy Processor: Targetting Coprocessor:
- Flavours and shapes food to mimic real meals - Steps up the die to hit for guns
Food Additives: - Cyber
- Flavours soy Soy Processor:
- 5 uses - Flavours and shapes food to mimic real meals
Marijuana: Food Additives:
- Smoked or used in soy processor - Flavours soy
- One use - 5 uses
- Use to ignore pain for a scene, or get +1d8 to social rolls with anyone you share this with Marijuana:
- Subtract 1d4 from anything that requires attention - Smoked or used in soy processor
- Drug - One use
PCP: - Use to ignore pain for a scene, or get +1d8 to social rolls with anyone you share this with
- One use - Subtract 1d4 from anything that requires attention
- Snorted - Drug
- Gain +1d4 on attacks PCP:
- Incoming attacks subtract 1d4 - One use
- Drug - Snorted
Tobacco: - Gain +1d4 on attacks
- One Use - Incoming attacks subtract 1d4
- Smoked - Drug
- Use to add +1 to any test which requires concentration Tobacco:
- Drug - One Use
Heroine: - Smoked
- One Use - Use to add +1 to any test which requires concentration
- Injected - Drug
- Ignore pain, -4 from anything that requires concentration Heroine:
- Drug - One Use
Injection Rounds: - Injected
- Loads a drug, and applies its effect as well as damage - Ignore pain, -4 from anything that requires concentration
- Ammo - Drug
Dark Clothing: Injection Rounds:
- 1d8 to Stealth checks - Loads a drug, and applies its effect as well as damage
- Armour - Ammo
Stealth Suit: Dark Clothing:
- 1d10 to Stealth checks - 1d8 to Stealth checks
- Reactive camoflague - Armour
- Armour Stealth Suit:
Optical Camoflague: - 1d10 to Stealth checks
- 1d12 to Stealth checks - Reactive camoflague
- Armour - Armour
Goggles: Optical Camoflague:
- 1d8 to visual notice rolls - 1d12 to Stealth checks
Binoculours: - Armour
- 1d10 to distance notice rolls Goggles:
Parabolic Mic: - 1d8 to visual notice rolls
- 1d10 to distance notice rolls Binoculours:
Keycard Copier: - 1d10 to distance notice rolls
- Allows copying a keycard (swipe or tap) with a sleight of hand roll Parabolic Mic:
- Can store unlimited cards - 1d10 to distance notice rolls
Gas Mask: Keycard Copier:
- Ignore gas in an area - Allows copying a keycard (swipe or tap) with a sleight of hand roll
Rebreather: - Can store unlimited cards
- Ignore gas in an area Gas Mask:
- Go without air for up to an hour - Ignore gas in an area
Sword: Rebreather:
- 1d8 damage - Ignore gas in an area
- Melee - Go without air for up to an hour
Sword:
- 1d8 damage
Common Cards: - Melee
Heavy Chain: Common Cards:
- 1d8 damage Heavy Chain:
- Melee - 1d8 damage
Leathers: - Melee
- Subtracts one from melee damage Leathers:
Cobbled Together First Aid Kit: - Subtracts one from melee damage
- Subtracts 1 from medical tests when using it Cobbled Together First Aid Kit:
- Allows bandaging rolls - Subtracts 1 from medical tests when using it
Tattoo: - Allows bandaging rolls
- Adds 1d4 to social rolls with affiliated gangs Tattoo:
- Subtracts 1d4 from social rolls with unaffilated gangs - Adds 1d4 to social rolls with affiliated gangs
- Roll 1d8 intimidation against barrens rats affiliated with smaller gangs or no gang - Subtracts 1d4 from social rolls with unaffilated gangs
- Cyber - Roll 1d8 intimidation against barrens rats affiliated with smaller gangs or no gang
Knife: - Cyber
- 1d4 damage Knife:
- 1d10 to hit - 1d4 damage
- Melee - 1d10 to hit
Moltov: - Melee
- One use Moltov:
- 1d8 damage - One use
- 2 damage until the person hit by it stops drops and rolls - 1d8 damage
- Thrown Weapon - 2 damage until the person hit by it stops drops and rolls
- Thrown Weapon

Loading…
Cancel
Save