1 ;;----------------------------------------------------------------------------
5 ;;----------------------------------------------------------------------------
6 (kern-mk-sched 'sch_hackle
7 (list 0 0 bole-hackles-hut "idle")
8 (list 2 0 bole-bed-hackle "sleeping")
9 (list 10 0 bole-hackles-hut "idle")
10 (list 20 0 bole-hackles-yard "idle")
13 ;;----------------------------------------------------------------------------
16 ;; Quest flags, etc, go here.
17 ;;----------------------------------------------------------------------------
18 (define (hackle-mk) nil)
20 ;;----------------------------------------------------------------------------
23 ;; Hackle is a female hedge-witch dwelling in Bole.
24 ;; Her mind was shattered by some misadventure with Gazer(s),
25 ;; though she is still capable of serving as a healer.
26 ;;----------------------------------------------------------------------------
27 (define (hackle-trade knpc kpc)
28 (say knpc "She can heal it, or one of its friends. She requires a piece of "
29 "gold for each piece of life! Does it agree?")
31 (say knpc "Which shall she heal?")
32 (let ((kchar (kern-ui-select-party-member)))
34 (say knpc "How else can she help it?")
35 (let* ((gold (kern-player-get-gold))
36 (pts (- (kern-char-get-max-hp kchar)
37 (kern-char-get-hp kchar))))
39 (say knpc "No gold, no life! It is the law of the world!")
42 (say knpc "It is well! She can do nothing for it!")
43 (let ((n (min gold pts)))
44 (say knpc "She heals it!")
45 (kern-obj-heal kchar n)
46 (kern-player-set-gold (- gold n))))
47 (say knpc "Will it heal another?")
48 (if (kern-conv-get-yes-no? kpc)
50 (say knpc "Then something else it wants.")
52 (if (kern-conv-get-yes-no? kpc)
54 (say knpc "Have it its way!")))
60 (define (hackle-default knpc kpc)
61 (say knpc "She cannot help it with that."))
63 (define (hackle-hail knpc kpc)
64 (if (in-player-party? 'ch_mesmeme)
66 (say knpc "[She shrinks back in horror at the sight of Mesmeme] AHHH! It frightens her!")
67 (aside kpc 'ch_mesmeme "No frighten.")
69 (say knpc "[You meet a disheveled, middle-aged woman] It comes to her! "
70 "It wants something!")
73 (define (hackle-name knpc kpc)
74 (say knpc "She is Hackle."))
76 (define (hackle-job knpc kpc)
77 (say knpc "She is mad! But she can heal it!"))
79 (define (hackle-join knpc kpc)
80 (say knpc "She cannot join it! She must mind her sheep!"))
82 (define (hackle-bye knpc kpc)
83 (say knpc "She bids it farewell, but knows it will return!"))
86 ;; other characters & town...
87 (define (hackle-may knpc kpc)
88 (say knpc "It is a hard woman, hard but kind to Hackle!"))
90 (define (hackle-kath knpc kpc)
91 (say knpc "A woman clothed in red! A fiend clothed in woman!"))
93 (define (hackle-bill knpc kpc)
94 (say knpc "It is careless. Yes, the wood gods will have it for supper one "
97 (define (hackle-thud knpc kpc)
98 (say knpc "[She laughs, a surprising, golden sound] That is no toy! They "
99 "called for a servant, but summoned a demon!"))
101 (define (hackle-melv knpc kpc)
102 (say knpc "It is a good soul."))
104 (define (hackle-bole knpc kpc)
105 (say knpc "Not Bole! Hole! The keyhole to the deep! She knows it!"))
108 (define (hackle-mesm knpc kpc)
109 (say knpc "It is only a child. Deaf and dumb it is, to its own kind. "
110 "But the pet will make a pet of its master.")
111 (aside kpc 'ch_mesmeme "No pet")
114 (define (hackle-shee knpc kpc)
115 (say knpc "The sheep hides in wolf's clothing! How it howls when it "
118 (define (hackle-wood knpc kpc)
119 (say knpc "She has seen them sleeping in the old oaks. She wakes them "
120 "not! They do not like us, they do not like anyone! The goblins "
121 "appease them but she does not know the words."))
123 (define (hackle-mad knpc kpc)
124 (say knpc "The gazers caught her as a girl! She escaped, but her mind did "
127 (define (hackle-gaze knpc kpc)
128 (say knpc "If it meets one, it should kill one without question! They know "
129 "the answer to any question, and in the answer lies bondage!")
130 (aside kpc 'ch_mesmeme "[Blinks nervously]")
134 (define (hackle-thie knpc kpc)
135 (say knpc "It is a mighty wrogue indeed that robs a mighty wizard!"))
137 (define (hackle-robs knpc kpc)
138 (say knpc "It robs and runs, down its little mouse-hole!"))
140 (define (hackle-hole knpc kpc)
141 (say knpc "Does it like riddles?\n"
142 " An 'o' has a hole!\n"
143 " And hole has an 'o'!\n"
144 " And a mouse has both!\n"
145 " In the middle of the night\n"
146 " Down it will go!\n"
147 "Does it know what ^c+mreveals^c-?")
148 (if (kern-conv-get-yes-no? kpc)
149 (say knpc "Then let it ^c+mreveal^c- and understand my riddle!")
151 (say knpc "Wis Quas! The Red Bitch has a scroll, but has not the "
155 (define (hackle-reve knpc kpc)
156 (say knpc "The Bill-boy knows where the mouse disappeared! "
157 "Let it ^c+mreveal^c- there!"))
159 (define (hackle-midd knpc kpc)
160 (say knpc "Yes! The middle of the night!"))
164 ;; default if the only "keyword" which may (indeed must!) be longer than
165 ;; 4 characters. The 4-char limit arises from the kernel's practice of
166 ;; truncating all player queries to the first four characters. Default,
167 ;; on the other hand, is a feature of the ifc mechanism (see ifc.scm).
168 (method 'default hackle-default)
169 (method 'hail hackle-hail)
170 (method 'bye hackle-bye)
171 (method 'job hackle-job)
172 (method 'name hackle-name)
173 (method 'join hackle-join)
175 (method 'trad hackle-trade)
176 (method 'buy hackle-trade)
177 (method 'sell hackle-trade)
178 (method 'heal hackle-trade)
180 (method 'bill hackle-bill)
181 (method 'kath hackle-kath)
182 (method 'red hackle-kath)
183 (method 'bitc hackle-kath)
184 (method 'may hackle-may)
185 (method 'melv hackle-melv)
186 (method 'thud hackle-thud)
188 (method 'bole hackle-bole)
189 (method 'gaze hackle-gaze)
190 (method 'god hackle-wood)
191 (method 'gods hackle-wood)
192 (method 'hole hackle-hole)
193 (method 'mad hackle-mad)
194 (method 'mesm hackle-mesm)
195 (method 'migh hackle-robs)
196 (method 'mous hackle-hole)
197 (method 'reve hackle-reve)
198 (method 'rob hackle-robs)
199 (method 'robs hackle-robs)
200 (method 'wrog hackle-robs)
201 (method 'wiza hackle-robs)
202 (method 'shee hackle-shee)
203 (method 'thie hackle-thie)
204 (method 'wood hackle-wood)
205 (method 'midd hackle-midd)
206 (method 'nigh hackle-midd)
209 ;;----------------------------------------------------------------------------
210 ;; First-time constructor
211 ;;----------------------------------------------------------------------------
214 (kern-mk-char 'ch_hackle ; tag
219 faction-men ; starting alignment
223 max-health -1 max-health 0 6 ; hp/xp/mp/AP_per_turn/lvl
227 'townsman-ai ; special ai