Using mouse in SCI.

Eigen In the beginning of Larry 3 there you can select right/wrong answers with you mouse cursor. How can I make that. :P



-Eigen
jrfritz I belive you move the mouse over the answers and click them with the left button.
Eigen No I mean how can I make thing like that in my own game.




-Eigen
Lightfoot Here is a rough copy of what I use...


(class Options of Dialog
(properties
Active FALSE
bDialog 0
)
(method(draw)
(var hDialog, hIcon)
= hDialog (Dialog:new())
(send hDialog:
text("Options")
)
= hIcon (DIcon:new())
(send hIcon:
value(OPT_EXIT)
)
(send hDialog:add(hIcon) setSize() open(nwNORMAL 15)
= Active TRUE
= bDialog hDialog
)
(method(hide)
(send bDialog:dispose())
= Active FALSE
)
(method(handleEvent pEvent)
(var temp0, temp1)
= temp0 (send bDialog:first())
(while(temp0)
= temp1 NodeValue(temp0)
(if( (<= (send pEvent:x) (send temp1:nsRight)) and (< (send temp1:nsLeft) (send pEvent:x)) and (<= (send pEvent:y) (send temp1:nsBottom)) and (< (send temp1:nsTop) (send pEvent:y)) )
(self:doAction( (send temp1:value) )
)
= temp0 (send bDialog:next(temp0))
)
)
(method(doAction action)
(switch(action)
(case OPT_EXIT
(self:hide())
)
)
)
)


Keep in mind this code I typed from my memory with no reference, so if it doesn't work exactly that's why. All of my game is at home where I have no internet connection, none of this code is available to me here, at work.