home *** CD-ROM | disk | FTP | other *** search
- on mouseUp
- global RecipeNum, StartingLine, Choice
- if the visible of sprite 21 then
- set x to the mouseH
- set y to the mouseV
- set lineNum to integer((y - 156) / 21) + 1
- set richLine to line lineNum + StartingLine of the text of member ("recipe" & RecipeNum) of castLib "recipes2"
- set checkWord to word 1 of richLine
- repeat with i = 1 to the number of lines in field ("fieldRecipe" & RecipeNum)
- if word 1 of line i of field ("fieldRecipe" & RecipeNum) = checkWord then
- set actualLine to line i of field ("fieldRecipe" & RecipeNum)
- set l1 to the number of lines in field "shop1"
- if the text of field "shop1" = 0 then
- set l1 to 0
- end if
- set l2 to the number of lines in field "shop2"
- if the text of field "shop2" = 0 then
- set l2 to 0
- end if
- put Choice into line l1 + 1 of field "shop1"
- put actualLine into line l2 + 1 of field "shop2"
- set the text of field "shop1temp" to line 1 to 10 of field "shop1"
- set the text of field "shop2temp" to line 1 to 10 of field "shop2"
- end if
- end repeat
- end if
- end
-