;;; Sierra Script 1.0 - (do not remove this comment)
(script# 508)
(include sci.sh)
(use Main)
(use Class_255_0)
(use Cycle)
(use Game)
(use Feature)
(use Obj)

(public
	Forest_Region 0
)

(instance Forest_Region of Rgn
	(properties
		name "Forest Region"
	)
	
	(method (init)
		(if (== (Random 1 5) 4)
			(= gNewAct_4 (Act new:))
			(gNewAct_4
				view: 356
				illegalBits: 0
				ignoreActors:
				setPri: 14
				ignoreHorizon:
				setScript: ravenActions
			)
			(if (== (Random 1 2) 1)
				(gNewAct_4
					posn: 5 30
					setCycle: Fwd
					xStep: 5
					yStep: 4
					setMotion: MoveTo 339 20 gNewAct_4
					init:
				)
			else
				(gNewAct_4
					posn: 314 20
					xStep: 5
					yStep: 4
					setCycle: Fwd
					setMotion: MoveTo -20 40 gNewAct_4
					init:
				)
			)
		)
		(super init:)
	)
	
	(method (handleEvent pEvent)
		(if (pEvent claimed?) (return 1))
		(return
			(if (== (pEvent type?) evSAID)
				(cond 
					((Said 'look>')
						(cond 
							((Said '/boulder') (Print 508 0))
							((or (Said '/dirt') (Said '/down')) (Print 508 1))
							((Said '/grass') (Print 508 2))
							((Said '/bush') (Print 508 3))
							((Said '/flora') (Print 508 4))
							((Said '/blossom') (Print 508 5))
							((Said '/forest') (Print 508 6))
							((Said '/crow,bird,crow')
								(if (gCast contains: gNewAct_4)
									(Print 508 7)
								else
									(Print 508 8)
								)
							)
						)
					)
					((Said 'climb/boulder') (Print 508 9))
					((Said 'get/blossom') (Print 508 10))
					((Said 'climb/forest') (Print 508 11))
					((Said 'converse/crow,bird,crow')
						(if (gCast contains: gNewAct_4)
							(Print 508 12)
						else
							(Print 508 13)
						)
					)
					((Said 'get,capture/crow,bird,crow')
						(if (gCast contains: gNewAct_4)
							(Print 508 14)
						else
							(Print 508 15)
						)
					)
					((Said 'kiss/crow,bird,crow')
						(if (gCast contains: gNewAct_4)
							(Print 508 16)
						else
							(Print 508 15)
						)
					)
				)
			else
				0
			)
		)
	)
)

(instance ravenActions of Script
	(properties)
	
	(method (cue)
		(gNewAct_4 dispose:)
	)
)
