chiark / gitweb /
red book
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Thu, 3 Dec 2020 16:51:14 +0000 (16:51 +0000)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Thu, 3 Dec 2020 16:51:14 +0000 (16:51 +0000)
pumpkin-books.ps.pl

index a2bbc73cc8e5c88597bd77db816fdb842fe01676..2834d28b686c2cc8ee4d369bdab6d63dc933a459 100755 (executable)
@@ -6,6 +6,7 @@ our $black = '0 0 0 1 setcmykcolor';
 
 my $pumpkin = ["0 .50 0 1.00 0", "0 0 0 1"];
 my $green = ["1 0 1 0", "0 0 0 0"];
+my $red = ["0 1 1 0", "0 0 0 1"];
 
 sub chip ($$) {
   my ($cary, $pips) = @_; # put in a gsave translate
@@ -156,9 +157,31 @@ END
 
   $o .= exposition(<<END);
 For each pumpkin in the last 3 chips,
-but not more than the number of
-green chips in your pot,
 receive 1 ruby.
+But, not more rubies than the number
+of green chips in your pot.
+END
+
+  $o;
+}
+  
+sub red_book () {
+  my $o = general_book($red, [qw(4 9 16)]);
+
+  $o .= <<END;
+gsave 0.35 0.30 dc translate ${\ chip($pumpkin,0) } grestore
+
+/Times-Bold findfont
+  15 scalefont setfont
+  0.50 0.24 dc moveto (+1) show
+
+END
+
+  $o .= exposition(<<END);
+The next 1/2/4 pumpkins you place are
+each moved one extra space.
+(After applying any other special effects;
+one extra space no matter how many reds)
 END
 
   $o;
@@ -239,8 +262,5 @@ END
 
 print tile(
           green_book(),
-          green_book(),
-          green_book(),
-          green_book(),
-          green_book(),
+          red_book(),
          ) or die $! if 1;