(version 2)
(include "sci.sh")
(exports
    0 leatherVendor
    1 tLeatherTalker
)
(use "Main")
(use "Vendor")
(use "GloryTalker")
(use "View")
(script 235)


(local
    theVendor

)
(instance public leatherVendor of Vendor
    (properties
        noun 3
    )

    (method (dispose param1)
        = goods 0
        (super:dispose(rest param1))
    )


    (method (transact param1 param2)
        = theVendor self
        (switch (param1)
            (case 0
                proc47_3(param1 param2 theVendor)
                (send gOwner:
                    get(15 param2)
                    solvePuzzle(220 3)
                )
                (send gQg3Messager:say(3 6 19 0 self))
            )
            (case 1
                proc47_3(param1 param2 theVendor)
                (send gOwner:
                    get(21 param2)
                    solvePuzzle(219 2)
                )
                (send gQg3Messager:say(3 6 19 0 self))
            )
        )
    )


    (method (doBargain param1)
        (switch (param1)
            (case 1
                (send gQg3Messager:say(3 6 35 0 self))
            )
            (case 2
                (send gQg3Messager:say(3 6 39 0 self))
            )
            (case 3
                (send gQg3Messager:say(3 6 40 0 self))
            )
            (case 4
                (send gQg3Messager:say(3 6 41 0 self))
            )
            (case 5
                (send gQg3Messager:say(3 6 38 0 self))
            )
            (case 6
                (send gQg3Messager:say(3 6 37 0 self))
            )
            (default 
                (self:cue())
            )
        )
    )

)
(instance public tLeatherTalker of GloryTalker
    (properties
        x 200
        y 2
        view 237
        loop 1
        cel 1
        talkWidth 260
        back 57
        textX -175
        textY 150
        backColor 24
    )

    (method (init param1)
        (super:init(leatherBust leatherEyes leatherMouth rest param1))
    )

)
(instance leatherBust of Prop
    (properties
        nsTop 27
        nsLeft 30
        view 237
        loop 3
        cel 1
    )
)
(instance leatherEyes of Prop
    (properties
        nsTop 43
        nsLeft 34
        view 237
        loop 2
    )
)
(instance leatherMouth of Prop
    (properties
        nsTop 55
        nsLeft 32
        view 237
    )
)
