an acoustic pressure wave propagates through space and can be absorbed or reflected by surfaces, diffracted around corners and through narrow “slits,” and refracted as it passes across the boundary between different transmission media
the intensity of the sound pressure wave it produces falls off with distance, following a 1/r2 law, while pressure follows a 1/r law
Naughty dog uses scheme scripting for dialog:
(define-dialog-line 'line-out-of-ammo
(character 'drake
(lines drk-out-of-ammo-01 ;; "Dammit, I'm out!"
drk-out-of-ammo-02 ;; "Crap, need more bullets."
drk-out-of-ammo-03 ;; "Oh, now I'm REALLY mad."
)
)
(character 'elena
(lines eln-out-of-ammo-01 ;; "Help, I'm out!"
eln-out-of-ammo-02 ;; "Got any more bullets?"
)
)
(character 'pirate-a
(lines pira-out-of-ammo-01 ;; "I'm out!"
pira-out-of-ammo-02 ;; "Need more ammo!"
;; ...
)
)
(character 'pirate-h
(lines pirh-out-of-ammo-01 ;; "I'm out!"
pirh-out-of-ammo-02 ;; "Need more ammo!"
(define-conversation-segment 'conv-searching-for-stuff-01
:rule []
:line 'line-did-you-find-anything ;; "Hey, did you find anything?"
:next-seg 'conv-searching-for-stuff-02
)
(define-conversation-segment 'conv-searching-for-stuff-02
:rule []
:line 'line-nope-not-yet ;; "I've been looking for an hour..."
:next-seg 'conv-searching-for-stuff-03
)
(define-conversation-segment 'conv-searching-for-stuff-03
:rule []
:line 'line-shut-up-keep-looking ;; "Well then shut up and keep looking!"
)
(define-conversation-segment 'conv-player-hit-by-bullet
(
:rule [ ('health < 25) ]
:line 'line-i-need-a-doctor ;; "I'm bleeding bad... need a doctor!"
)
(
:rule [ ('health < 75) ]
:line 'line-im-in-trouble ;; "Now I'm in real trouble."
)
(
:rule [ ] ;; no criteria acts as an "else" case
:line 'line-that-was-close ;; "Ah! Can't let that happen again!"
)
)
(define-conversation-segment 'conv-shot-at--start
(
:rule [ ]
:line 'line-are-you-ok ;; "Are you OK?"
:next-seg 'conv-shot-at--health-check
:next-speaker 'listener ;; \*\*\* see comments below
)
)
(define-conversation-segment 'conv-shot-at--health-check
(
:rule [ (('speaker 'shot-recently) == false) ]
:line 'line-yeah-im-fine ;; "Yeah, I'm fine."
:next-seg 'conv-shot-at--not-hit
:next-speaker 'listener ;; \*\*\* see comments below
)
(
:rule [ (('speaker 'shot-recently) == true) ]
:line 'line-not-exactly ;; "(panting) Not exactly."
:next-seg 'conv-shot-at--hit
:next-speaker 'listener ;; \*\*\* see comments below
)
)