Browse Source

add more examples

Getty Ritter 2 years ago
parent
commit
4c5d707b66
6 changed files with 89 additions and 0 deletions
  1. 18 0
      examples/celestial.matzo
  2. 11 0
      examples/druidic.matzo
  3. 12 0
      examples/giant.matzo
  4. 14 0
      examples/gnoll.matzo
  5. 19 0
      examples/gnomish.matzo
  6. 15 0
      examples/halfling.matzo

+ 18 - 0
examples/celestial.matzo

@@ -0,0 +1,18 @@
+word
+  := syll cons end
+   | init penult end
+   | init syll penult end
+   | init syll syll penult end
+   ;
+
+syll := cons vowel;
+init := 4: cons vowel | 4: vowel | vowel cons vowel;
+penult := cons vowel cons;
+
+end ::= el ael as as as es us us em em um um arm
+        is os os os on at ar or or ir o a a a;
+cons ::= b g t t t d d h v v z z z ch j x c c c
+         l l l m n s s s p f r r r s;
+vowel := 3: 'a'| 2: 'i' | 'u' | 2: 'e' | 'o' | 3: 'æ';
+
+puts word;

+ 11 - 0
examples/druidic.matzo

@@ -0,0 +1,11 @@
+(* Druidic *)
+word := init (rep.<1|2,syll>) end;
+init := 3: vowel | 2: '';
+syll := cons vowel;
+end ::= a e er ir;
+cons ::= b c c c d d f g h j k l m n p qu r
+         s s s š š š t t t ts v w y z;
+vowel ::= a e i o u â ä î ai au äu ea ei eu eai eau ia ie io
+          iu ii oa oi ou uä ui;
+
+puts word;

+ 12 - 0
examples/giant.matzo

@@ -0,0 +1,12 @@
+word := begin rep.<1..3,syll> end;
+syll := vowel cons;
+end := vowel ('n'| 'ns' | 's' | '');
+begin := 2: cons | beginvowel;
+
+cons ::= b c ch d f g gh h j l m n p r s t th v x wh;
+vowel := 3: normalvowel | accentvowel;
+normalvowel ::= a i u e o;
+accentvowel ::= á í ú é ó y;
+beginvowel  ::= a á i u e o;
+
+puts word;

+ 14 - 0
examples/gnoll.matzo

@@ -0,0 +1,14 @@
+word := syll | 4: syll ending | 2: syll syll ending | syll syll syll ending;
+syll := vowel cons | glide vowel cons;
+
+ending := 'in'| 'en' | 'e' | 'än' | 'ën' | 'er' | 'inn' | cons 's'
+        | 'ich' | 'ert' | 'urt' | 'ern' | 'urn';
+cons ::= p b pf m v t d tz n s zr l tsc sc ch y k g h;
+vowel := 3: basevowel | umlvowel | dipth;
+
+basevowel ::= a i u e o;
+umlvowel  ::= ä ï ü ë ö;
+dipth     ::= ei au eu eu äu;
+glide     ::= l r ch t;
+
+puts word;

+ 19 - 0
examples/gnomish.matzo

@@ -0,0 +1,19 @@
+word
+  :=    cons vowel
+   | 3: cons vowel cons vowel
+   | 2: cons vowel cons
+   | 3: cons vowel cons vowel cons vowel
+   | 3: cons vowel cluster vowel
+   | 3: cons vowel cons vowel cluster vowel
+   | 3: cons vowel cluster vowel cons vowel
+   ;
+
+cons ::= p b t d k g ts f v s z sh zh cz m n r l l ch;
+cluster ::=
+  lt ld lk lg lv lf ls lz lsh lzh lcz lm ln
+  rt rd rf rv rsh rzh rcz nd nt ns nz;
+vowel
+  := 2: 'a'| 2: 'i' | 2: 'u' | 2: 'e' | 2: 'o'
+   | 'ya' | 'yi' | 'yu' | 'ye' | 'yo' | 2: 'y';
+
+puts word;

+ 15 - 0
examples/halfling.matzo

@@ -0,0 +1,15 @@
+word := begin rep.<1..4, syll> end;
+syll := cons vowel;
+end := cons vowel final | cons 'é' final | cons 'a' final | 'r' | 'n';
+
+begin := vowel | initcons vowel;
+
+cons ::= b c d d ch d f g g gn h j l l l lh m m m n n n nh
+         p qu r s s s ss ss ss sc sc t t t tg tj tz tz tr rt v z;
+initcons ::= b c d ch d f g gn h j l m n p qu r s sc t v;
+vowel := 4: commonvowel | uncommonvowel;
+commonvowel ::= a i u e é o;
+uncommonvowel ::= à è ó ò í ú;
+final := 's' | 6: '';
+
+puts word;