home *** CD-ROM | disk | FTP | other *** search
- on help_init
- global hp_itm01, hp_itm02, hp_itm03, hp_itm04, hp_itm05, hp_itm06, hp_itm07, hp_itm08, hp_itm09, hp_itm10, hp_itm11, hp_itm12, hp_itm13, hp_r, hp_l, hp_x, hp_page, hp_max
- set hp_page to -1
- set hp_bas to 74
- set hp_step to 28
- set nx1 to 11
- set nx2 to 203
- set hp_max to 12
- set hp_itm01 to rect(nx1, hp_bas + (hp_step * 0), nx2, hp_bas + ((hp_step * 1) - 2))
- set hp_itm02 to rect(nx1, hp_bas + (hp_step * 1), nx2, hp_bas + ((hp_step * 2) - 2))
- set hp_itm03 to rect(nx1, hp_bas + (hp_step * 2), nx2, hp_bas + ((hp_step * 3) - 2))
- set hp_itm04 to rect(nx1, hp_bas + (hp_step * 3), nx2, hp_bas + ((hp_step * 4) - 2))
- set hp_itm05 to rect(nx1, hp_bas + (hp_step * 4), nx2, hp_bas + ((hp_step * 5) - 2))
- set hp_itm06 to rect(nx1, hp_bas + (hp_step * 5), nx2, hp_bas + ((hp_step * 6) - 2))
- set hp_itm07 to rect(nx1, hp_bas + (hp_step * 6), nx2, hp_bas + ((hp_step * 7) - 2))
- set hp_itm08 to rect(nx1, hp_bas + (hp_step * 7), nx2, hp_bas + ((hp_step * 8) - 2))
- set hp_itm09 to rect(nx1, hp_bas + (hp_step * 8), nx2, hp_bas + ((hp_step * 9) - 2))
- set hp_itm10 to rect(nx1, hp_bas + (hp_step * 9), nx2, hp_bas + ((hp_step * 10) - 2))
- set hp_itm11 to rect(nx1, hp_bas + (hp_step * 10), nx2, hp_bas + ((hp_step * 11) - 2))
- set hp_itm12 to rect(nx1, hp_bas + (hp_step * 11), nx2, hp_bas + ((hp_step * 12) - 2))
- set hp_l to rect(0, 449, 60, 479)
- set hp_r to rect(156, 449, 219, 479)
- set hp_x to rect(61, 449, 155, 479)
- end
-
- on help_open page
- global fcommand, acwin, spritecount, scommand, up_lang, hp_r, hp_l, hp_x, hp_page, hp_max, hp_item, sp_help, up_load
- set fcommand to EMPTY
- cur_busy()
- if hp_page >= 0 then
- help_close()
- end if
- put "help_open>" & page
- set hp_page to page
- set hp_item to 0
- set fcommand to "HPOP"
- end
-
- on help_close
- global fcommand, acwin, spritecount, scommand, hp_r, hp_l, hp_x, hp_page, hp_item, hp_max, sp_help, up_load
- set fcommand to EMPTY
- set sp_help to 47
- cur_busy()
- put "help_close>" & hp_page
- if hp_page >= 0 then
- if the number of cast "HP" <= 0 then
- else
- puppetTransition(2, 1, 5)
- sprite_show(sp_help, 1500, 1500)
- puppetSprite(sp_help, 0)
- end if
- end if
- set hp_page to -1
- cur_on()
- end
-
- on help_X
- global hp_r, hp_l, hp_x, hp_page, hp_max
- help_close()
- end
-
- on help_R
- global hp_page, hp_max, hp_item, fcommand
- set hp_old to hp_page
- if hp_page >= 0 then
- help_close()
- end if
- if (hp_item + 1) < 9 then
- set hp_item to hp_item + 1
- else
- set hp_item to 0
- end if
- if chkfis(help_name(hp_old, hp_item)) then
- set hp_page to hp_old
- else
- set hp_page to hp_old + 1
- set hp_item to 0
- end if
- if hp_page > hp_max then
- set hp_page to 0
- end if
- set fcommand to "HPOP"
- end
-
- on help_L
- global fcommand, hp_page, hp_max, hp_item
- put "help_L>" & hp_page
- set hp_old to hp_page
- if hp_page >= 0 then
- help_close()
- end if
- if (hp_item - 1) < 0 then
- set hp_item to 0
- set hp_page to hp_old - 1
- else
- set hp_item to hp_item - 1
- if chkfis(help_name(hp_old, hp_item)) then
- set hp_page to hp_old
- else
- set hp_page to hp_old - 1
- set hp_item to 0
- end if
- end if
- if hp_page < 0 then
- set hp_page to hp_max
- end if
- set fcommand to "HPOP"
- end
-
- on help_load page
- global fcommand, acwin, spritecount, scommand, up_lang, hp_r, hp_l, hp_x, hp_page, hp_item, hp_max, sp_help, player, up_load, demo
- set fcommand to EMPTY
- set helpcast to "HP"
- duplicate(cast "EMPTY", cast 59)
- set the name of cast 59 to helpcast
- set helpcastn to 59
- set hp_file to help_name(page, hp_item)
- importFileInto(cast helpcast, hp_file)
- if up_lang = 2 then
- set langchar to "G"
- else
- set langchar to "E"
- end if
- if the colorDepth >= 16 then
- if demo then
- set hlphlp to "08"
- else
- set hlphlp to "16"
- end if
- else
- set hlphlp to "08"
- end if
- set helpcast to hlphlp & langchar & "_" & lzero(page) & string(hp_item) & ".pic"
- if the name of cast helpcastn <> helpcast then
- alertrd("Can`t find help page:" & RETURN & helpcast, "Hilfeseite nicht gefunden: " & RETURN & helpcast)
- else
- set the name of cast helpcast to "HP"
- set sp_help to 47
- set helpcast to "HP"
- set hp_page to page
- puppetTransition(1, 1, 5)
- set the castNum of sprite sp_help to the number of cast "HP"
- set the scriptText of cast "HP" to the text of cast "SC_MAIN"
- set the ink of sprite sp_help to 0
- if not player then
- sprite_show(sp_help, 0, 0)
- else
- sprite_show(sp_help, 108, 239)
- end if
- puppetSprite(sp_help, 1)
- end if
- cur_on()
- updateStage()
- end
-
- on help_name page, itemhp
- global up_lang, demo
- if up_lang = 2 then
- set langchar to "G"
- else
- set langchar to "E"
- end if
- if the colorDepth >= 16 then
- if demo then
- set hlphlp to "08"
- else
- set hlphlp to "16"
- end if
- else
- set hlphlp to "08"
- end if
- if the machineType = 256 then
- set hp_file to the pathName & "HELP" & langchar & "\" & hlphlp & langchar & "_" & lzero(page) & string(itemhp) & ".pic"
- else
- set hp_file to the pathName & "HELP" & langchar & ":" & hlphlp & langchar & "_" & lzero(page) & string(itemhp) & ".pic"
- end if
- return hp_file
- end
-