Skip to content

Latest commit

 

History

History
178 lines (134 loc) · 15.4 KB

03_designs_cheat.md

File metadata and controls

178 lines (134 loc) · 15.4 KB

Build Your Own All-In-One Page Cheat Sheet with All 128 MoonCat Designs (0-127) In Original Pixel Size And 3X; Tagged With Pose / Face / Fur / Facing Attributes

Let's build an all-in-one page cheat sheet that lists all 128 MoonCat designs (0 to 127) in original pixel size approaching 24×24¹ and 3x zoom; tagged with the pose (4), face (4), fur (4), facing (2) attributes.

¹: Standing (21×17), sleeping (20×14), pouncing (17×22), stalking (20×21)

Step 1: Generate design images using original size and 3x

Let's loop from 0 to 127 and generate the two image series in a single run. Naming the original series images design-000.png, design-001.png, design-002.png, and so on and the 3x series design-000x3.png, design-001x3.png, design-002x3.png, and so on:

require 'mooncats'

(0..127).each do |design|
  name = 'design-%03d' % design

  cat = Mooncats::Image.new( design: design )
  cat.save( "i/#{name}.png" )

  cat = Mooncats::Image.new( design: design, zoom: 3 )
  cat.save( "i/#{name}x3.png" )
end

Resulting in two 128 image series. Original size:

...

And with 3x zoom factor:

...

Step 2: Generate the all-in-one cheat sheet page

Let's start the page with a header and little intro:

buf =<<TXT
# MoonCat Designs (128)

In original pixel size¹ and 3x zoom;
tagged with pose (4), face (4), fur (4), facing (2) attributes.

¹: Standing (21×17), sleeping (20×14), pouncing (17×22), stalking (20×21)

TXT

And let's group the design images in blocks / slices of four each (that is, Standing / Sleeping / Pouncing / Stalking) and let's number (0 to 127) and tag all designs with the pose (4), face (4), fur (4), and facing (2) attributes.

Note: The script writes out structured text and "ASCII" table using the markdown (.md) formatting conventions:

buf << "| Standing | Sleeping | Pouncing | Stalking |\n"
buf << "|----------|----------|----------|----------|\n"

(0..127).each_slice(4) do |slice|
   buf << "| "
   slice.each do |design|
      design_meta = Mooncats::Metadata::Design.new( design )

      name = "design-%03d" % design

      buf << " ![](i/#{name}.png)"
      buf << " ![](i/#{name}x3.png)"
      buf << " <br> #{design} "
      buf << "#{design_meta.pose}·"
      buf << "#{design_meta.face}·"
      buf << "#{design_meta.fur}·"
      buf << "#{design_meta.facing} "
      buf << "|"
   end
   buf << "\n"
end

puts buf

Resulting in (rendered "inline" in HTML):


MoonCat Designs (128)

In original pixel size¹ and 3x zoom; tagged with pose (4), face (4), fur (4), facing (2) attributes.

¹: Standing (21×17), sleeping (20×14), pouncing (17×22), stalking (20×21)

Standing Sleeping Pouncing Stalking

0 Standing·Smile·Solid·Left

1 Sleeping·Smile·Solid·Left

2 Pouncing·Smile·Solid·Left

3 Stalking·Smile·Solid·Left

4 Standing·Smile·Striped·Left

5 Sleeping·Smile·Striped·Left

6 Pouncing·Smile·Striped·Left

7 Stalking·Smile·Striped·Left

8 Standing·Smile·Eyepatch·Left

9 Sleeping·Smile·Eyepatch·Left

10 Pouncing·Smile·Eyepatch·Left

11 Stalking·Smile·Eyepatch·Left

12 Standing·Smile·Half/Half·Left

13 Sleeping·Smile·Half/Half·Left

14 Pouncing·Smile·Half/Half·Left

15 Stalking·Smile·Half/Half·Left

16 Standing·Frown (Look Down)·Solid·Left

17 Sleeping·Frown (Look Down)·Solid·Left

18 Pouncing·Frown (Look Down)·Solid·Left

19 Stalking·Frown (Look Down)·Solid·Left

20 Standing·Frown (Look Down)·Striped·Left

21 Sleeping·Frown (Look Down)·Striped·Left

22 Pouncing·Frown (Look Down)·Striped·Left

23 Stalking·Frown (Look Down)·Striped·Left

24 Standing·Frown (Look Down)·Eyepatch·Left

25 Sleeping·Frown (Look Down)·Eyepatch·Left

26 Pouncing·Frown (Look Down)·Eyepatch·Left

27 Stalking·Frown (Look Down)·Eyepatch·Left

28 Standing·Frown (Look Down)·Half/Half·Left

29 Sleeping·Frown (Look Down)·Half/Half·Left

30 Pouncing·Frown (Look Down)·Half/Half·Left

31 Stalking·Frown (Look Down)·Half/Half·Left

32 Standing·Frown (Look Up)·Solid·Left

33 Sleeping·Frown (Look Up)·Solid·Left

34 Pouncing·Frown (Look Up)·Solid·Left

35 Stalking·Frown (Look Up)·Solid·Left

36 Standing·Frown (Look Up)·Striped·Left

37 Sleeping·Frown (Look Up)·Striped·Left

38 Pouncing·Frown (Look Up)·Striped·Left

39 Stalking·Frown (Look Up)·Striped·Left

40 Standing·Frown (Look Up)·Eyepatch·Left

41 Sleeping·Frown (Look Up)·Eyepatch·Left

42 Pouncing·Frown (Look Up)·Eyepatch·Left

43 Stalking·Frown (Look Up)·Eyepatch·Left

44 Standing·Frown (Look Up)·Half/Half·Left

45 Sleeping·Frown (Look Up)·Half/Half·Left

46 Pouncing·Frown (Look Up)·Half/Half·Left

47 Stalking·Frown (Look Up)·Half/Half·Left

48 Standing·Flat Whiskers·Solid·Left

49 Sleeping·Flat Whiskers·Solid·Left

50 Pouncing·Flat Whiskers·Solid·Left

51 Stalking·Flat Whiskers·Solid·Left

52 Standing·Flat Whiskers·Striped·Left

53 Sleeping·Flat Whiskers·Striped·Left

54 Pouncing·Flat Whiskers·Striped·Left

55 Stalking·Flat Whiskers·Striped·Left

56 Standing·Flat Whiskers·Eyepatch·Left

57 Sleeping·Flat Whiskers·Eyepatch·Left

58 Pouncing·Flat Whiskers·Eyepatch·Left

59 Stalking·Flat Whiskers·Eyepatch·Left

60 Standing·Flat Whiskers·Half/Half·Left

61 Sleeping·Flat Whiskers·Half/Half·Left

62 Pouncing·Flat Whiskers·Half/Half·Left

63 Stalking·Flat Whiskers·Half/Half·Left

64 Standing·Smile·Solid·Right

65 Sleeping·Smile·Solid·Right

66 Pouncing·Smile·Solid·Right

67 Stalking·Smile·Solid·Right

68 Standing·Smile·Striped·Right

69 Sleeping·Smile·Striped·Right

70 Pouncing·Smile·Striped·Right

71 Stalking·Smile·Striped·Right

72 Standing·Smile·Eyepatch·Right

73 Sleeping·Smile·Eyepatch·Right

74 Pouncing·Smile·Eyepatch·Right

75 Stalking·Smile·Eyepatch·Right

76 Standing·Smile·Half/Half·Right

77 Sleeping·Smile·Half/Half·Right

78 Pouncing·Smile·Half/Half·Right

79 Stalking·Smile·Half/Half·Right

80 Standing·Frown (Look Down)·Solid·Right

81 Sleeping·Frown (Look Down)·Solid·Right

82 Pouncing·Frown (Look Down)·Solid·Right

83 Stalking·Frown (Look Down)·Solid·Right

84 Standing·Frown (Look Down)·Striped·Right

85 Sleeping·Frown (Look Down)·Striped·Right

86 Pouncing·Frown (Look Down)·Striped·Right

87 Stalking·Frown (Look Down)·Striped·Right

88 Standing·Frown (Look Down)·Eyepatch·Right

89 Sleeping·Frown (Look Down)·Eyepatch·Right

90 Pouncing·Frown (Look Down)·Eyepatch·Right

91 Stalking·Frown (Look Down)·Eyepatch·Right

92 Standing·Frown (Look Down)·Half/Half·Right

93 Sleeping·Frown (Look Down)·Half/Half·Right

94 Pouncing·Frown (Look Down)·Half/Half·Right

95 Stalking·Frown (Look Down)·Half/Half·Right

96 Standing·Frown (Look Up)·Solid·Right

97 Sleeping·Frown (Look Up)·Solid·Right

98 Pouncing·Frown (Look Up)·Solid·Right

99 Stalking·Frown (Look Up)·Solid·Right

100 Standing·Frown (Look Up)·Striped·Right

101 Sleeping·Frown (Look Up)·Striped·Right

102 Pouncing·Frown (Look Up)·Striped·Right

103 Stalking·Frown (Look Up)·Striped·Right

104 Standing·Frown (Look Up)·Eyepatch·Right

105 Sleeping·Frown (Look Up)·Eyepatch·Right

106 Pouncing·Frown (Look Up)·Eyepatch·Right

107 Stalking·Frown (Look Up)·Eyepatch·Right

108 Standing·Frown (Look Up)·Half/Half·Right

109 Sleeping·Frown (Look Up)·Half/Half·Right

110 Pouncing·Frown (Look Up)·Half/Half·Right

111 Stalking·Frown (Look Up)·Half/Half·Right

112 Standing·Flat Whiskers·Solid·Right

113 Sleeping·Flat Whiskers·Solid·Right

114 Pouncing·Flat Whiskers·Solid·Right

115 Stalking·Flat Whiskers·Solid·Right

116 Standing·Flat Whiskers·Striped·Right

117 Sleeping·Flat Whiskers·Striped·Right

118 Pouncing·Flat Whiskers·Striped·Right

119 Stalking·Flat Whiskers·Striped·Right

120 Standing·Flat Whiskers·Eyepatch·Right

121 Sleeping·Flat Whiskers·Eyepatch·Right

122 Pouncing·Flat Whiskers·Eyepatch·Right

123 Stalking·Flat Whiskers·Eyepatch·Right

124 Standing·Flat Whiskers·Half/Half·Right

125 Sleeping·Flat Whiskers·Half/Half·Right

126 Pouncing·Flat Whiskers·Half/Half·Right

127 Stalking·Flat Whiskers·Half/Half·Right

And to wrap up let's save the page to DESIGNS.md.

File.open( './DESIGNS.md', 'w:utf-8') { |f| f.write( buf ) }