blob: f70f20449025456240f452a966bfd40d9f089799 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
|
-- This script makes the Save Gondolin quest take the player straight
-- to Gondolin instead of the Secret Valley. Many thanks to TheFalcon
-- for the code.
add_loadsave("tolan_count", 0)
function tolan_travel()
if (quest(15).status == QUEST_STATUS_TAKEN) and (tolan_count == 0) then
player.wilderness_x = 3
player.wilderness_y = 11
player.wild_mode = FALSE
player.px = 117
player.py = 25
player.oldpx = player.px
player.oldpy = player.py
dun_level = 0
player.leaving = TRUE
tolan_count = 1
return TRUE
end
end
add_hook_script(HOOK_END_TURN, "tolan_travel", "tolan_travel")
add_hooks
{
[HOOK_BIRTH] = function()
if tolan_count >=1
then tolan_count = 0
else
end
end
}
|