Rev 15179 | Details | Compare with Previous | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
4122 | bpr | 1 | type=game |
13715 | obado | 2 | textarea="data instruction" |
3 | iEdit="instruction" |
||
4122 | bpr | 4 | |
4148 | bpr | 5 | :Write the events in chronological order. |
13477 | obado | 6 | <p class="wims_credits"> |
15179 | lemaire | 7 | Author of the model: <a href="mailto:bernadette.m.riou@orange.fr">Bernadette Perrin-Riou</a> |
4122 | bpr | 8 | </p> |
9 | :%%%%%%%%%%%%%%%%% ATTENTION %%%%%%%%%%%%%%%%%%%% |
||
10 | |||
4136 | bpr | 11 | Remove the above header if you destroy the model tags i.e. the lines starting |
12 | with a ':'. Otherwise the exercise might not be recognised by Createxo. |
||
4122 | bpr | 13 | |
14 | :%%%%%%%% Example parameters to be redefined %%%%%%%%%%%%%%%%% |
||
4148 | bpr | 15 | :\title{Timeline} |
5147 | bpr | 16 | :\author{Csilla, Ducrocq} |
5724 | bpr | 17 | :\email{} |
18 | :\credits{} |
||
13477 | obado | 19 | |
4135 | bpr | 20 | :Instruction |
13477 | obado | 21 | \text{instruction=Write the dates in the bottom line and the matching events in the top line.} |
4122 | bpr | 22 | |
4135 | bpr | 23 | :Maximum 10 dates will be presented to the learner at a time. |
24 | These will be drawn randomly from the entire list (Main data) provided. |
||
4122 | bpr | 25 | \text{N=5} |
13477 | obado | 26 | |
7167 | bpr | 27 | :Color of the arrow |
4122 | bpr | 28 | \text{couleur=orange} |
13477 | obado | 29 | |
4122 | bpr | 30 | :Width of labels |
31 | \text{facteur=100} |
||
13477 | obado | 32 | |
4122 | bpr | 33 | :Height of labels |
34 | \integer{height=100} |
||
13477 | obado | 35 | |
5744 | bpr | 36 | :Width of the arrow |
37 | Choose an integer between 1 and 3 |
||
38 | \integer{wi=1} |
||
13477 | obado | 39 | |
13704 | obado | 40 | :Option: use both the items of the main data (0), only the first column (1), only the second column (2) |
4122 | bpr | 41 | \text{choix=0} |
13477 | obado | 42 | |
4122 | bpr | 43 | :Main data. |
44 | \text{data=1492,Christopher Columbus discovers America |
||
45 | 1607,the first English settlements |
||
46 | 1776,Declaration of Independence |
||
47 | 1789,First constitution of the USA |
||
48 | 1860,Abraham lincoln becomes president |
||
49 | 1917,the USA joins the 1st World War |
||
50 | 1929,the Wall street Crash |
||
51 | 1941,Pearl harbor |
||
52 | 1945,End of World War 2} |
||
53 | |||
11544 | obado | 54 | :Embraced random items |
7167 | bpr | 55 | $embraced_randitem |
56 | \text{accolade=item(1,1 yes, |
||
57 | 2 no)} |
||
8512 | bpr | 58 | |
4122 | bpr | 59 | :%%%%%%%%%%%%%% Rien à modifier ensuite %%%%%%%%%%%%%%%% |
7167 | bpr | 60 | \text{accolade=wims(word 1 of \accolade)} |
8512 | bpr | 61 | \real{M=\N-0.3} |
4122 | bpr | 62 | \text{xrange=-1,\N+1} |
7167 | bpr | 63 | \text{yrange=\choix iswordof 0 ? -5,5:-2,5} |
4122 | bpr | 64 | \text{yrange=\choix=1 ? -5,2} |
7167 | bpr | 65 | \text{yrange=\choix=3 ? -5,4} |
4122 | bpr | 66 | \text{cnt=rows(\data)} |
67 | \text{shu=shuffle(\cnt)} |
||
68 | \text{shu=\shu[1..\N]} |
||
69 | \text{shu=wims(sort numeric item \shu)} |
||
70 | \text{data=row([\shu],\data)} |
||
7167 | bpr | 71 | \text{data=\accolade=1 ? wims(embraced randitem \data)} |
4122 | bpr | 72 | \matrix{rep=\data} |
73 | \integer{size=(1.5*\facteur)*(\M+1)} |
||
74 | \integer{height2=4*\height} |
||
75 | \text{size=\size,\height2} |
||
76 | \text{fleche=xrange \xrange |
||
77 | yrange \yrange |
||
18080 | bpr | 78 | polyline \couleur,\M,\wi/2,-1,\wi/2,-1,-\wi/2,\M,-\wi/2,\M,-\wi,\N+0.5,0,\M,\wi,\M,\wi/2 |
7167 | bpr | 79 | fill 0,0,\couleur |
4122 | bpr | 80 | } |
81 | |||
82 | \text{STEP=\choix=0 ? wims(values x for x=1 to 2*\N)} |
||
83 | \text{STEP=\choix=1 ? wims(values 2*x-1 for x=1 to \N)} |
||
7167 | bpr | 84 | \text{STEP=\choix=2 or \choix=3? wims(values 2*x for x=1 to \N)} |
4122 | bpr | 85 | \text{STEP=wims(makelist r x for x in \STEP)} |
86 | \steps{\STEP} |
||
87 | \text{positionbas=} |
||
88 | \text{positionhaut=} |
||
7167 | bpr | 89 | \text{positionbas2=} |
4122 | bpr | 90 | \for{j=0 to \N-1}{ |
7167 | bpr | 91 | \text{fleche=\choix=0 or \choix=1 or \choix=3 ? \fleche |
18080 | bpr | 92 | segment \j-0.1,-\wi/2,\j-0.1,-2*\wi,\couleur} |
7167 | bpr | 93 | \text{fleche=\choix=0 or \choix=2 or \choix=3? \fleche |
18080 | bpr | 94 | segment \j-0.1,\wi/2,\j-0.1,2*\wi,\couleur} |
4122 | bpr | 95 | \text{ans=pari([2*\j+1,2*\j+2])} |
7167 | bpr | 96 | \text{v=slib(draw/convpixel \j-0.5,-2,\size,\xrange,\yrange,0,pixels)} |
97 | \text{positionbas=\positionbas |
||
98 | r\ans[1],\v[1] x \v[2]} |
||
4122 | bpr | 99 | \text{v=slib(draw/convpixel \j-0.5,-2,\size,\xrange,\yrange,0,pixels)} |
7167 | bpr | 100 | \text{positionbas2=\positionbas2 |
101 | r\ans[2],\v[1] x \v[2]} |
||
102 | \text{v=slib(draw/convpixel \j-0.5,4,\size,\xrange,\yrange,0,pixels)} |
||
103 | \text{positionhaut=\positionhaut |
||
4122 | bpr | 104 | r\ans[2],\v[1] x \v[2]} |
7167 | bpr | 105 | |
106 | \text{fleche=\choix=3? \fleche |
||
107 | text black, \j-0.2,3,medium,\data[\j+1;1]} |
||
4122 | bpr | 108 | } |
7167 | bpr | 109 | \text{position=\choix=1 or \choix=0? \positionbas} |
110 | \text{position=\choix=2 or \choix=0? \position |
||
4122 | bpr | 111 | \positionhaut} |
7167 | bpr | 112 | \text{position=\choix=3? \positionbas2} |
4122 | bpr | 113 | \text{urlfleche=draw(\size |
114 | \fleche)} |
||
7167 | bpr | 115 | \statement{ |
116 | \instruction |
||
5744 | bpr | 117 | <div class="wimscenter"> |
4122 | bpr | 118 | \special{imagefill \urlfleche,\size[1]x\size[2],\facteur x \height |
119 | \position} |
||
5744 | bpr | 120 | </div> |
4122 | bpr | 121 | } |
122 | |||
123 | \answer{}{\rep[1;1]}{type=clickfill}{option=shuffle} |
||
124 | \answer{}{\rep[1;2]}{type=clickfill}{option=shuffle} |
||
125 | \answer{}{\rep[2;1]}{type=clickfill}{option=shuffle} |
||
126 | \answer{}{\rep[2;2]}{type=clickfill}{option=shuffle} |
||
127 | \answer{}{\rep[3;1]}{type=clickfill}{option=shuffle} |
||
128 | \answer{}{\rep[3;2]}{type=clickfill}{option=shuffle} |
||
129 | \answer{}{\rep[4;1]}{type=clickfill}{option=shuffle} |
||
130 | \answer{}{\rep[4;2]}{type=clickfill}{option=shuffle} |
||
131 | \answer{}{\rep[5;1]}{type=clickfill}{option=shuffle} |
||
132 | \answer{}{\rep[5;2]}{type=clickfill}{option=shuffle} |
||
133 | \answer{}{\rep[6;1]}{type=clickfill}{option=shuffle} |
||
134 | \answer{}{\rep[6;2]}{type=clickfill}{option=shuffle} |
||
135 | \answer{}{\rep[7;1]}{type=clickfill}{option=shuffle} |
||
136 | \answer{}{\rep[7;2]}{type=clickfill}{option=shuffle} |
||
137 | \answer{}{\rep[8;1]}{type=clickfill}{option=shuffle} |
||
138 | \answer{}{\rep[8;2]}{type=clickfill}{option=shuffle} |
||
139 | \answer{}{\rep[9;1]}{type=clickfill}{option=shuffle} |
||
140 | \answer{}{\rep[9;2]}{type=clickfill}{option=shuffle} |
||
141 | \answer{}{\rep[10;1]}{type=clickfill}{option=shuffle} |
||
7167 | bpr | 142 | \answer{}{\rep[10;2]}{type=clickfill}{option=shuffle} |