Axe Software Forums
  Quest Developer Forum
  Library by AlanBambton

Post New Topic  
profile | register | faq

Author Topic:   Library by AlanBambton
gamer1962 posted 02-06-2003 22:44 BST   Click Here to See the Profile for gamer1962   Click Here to Email gamer1962  
I am using the type library by A.Bambton. The take script does not seem to work with the Library. If I check "takeable" and then add the script it will not perform the script. It appears to not recognize the "takeable" script once you have checked the "regular object" on the basics tab. I have tried various ways like not checking the regular object but I cant get it to work. Any one have any ideas?
MaDbRiT posted 03-06-2003 08:59 BST     Click Here to See the Profile for MaDbRiT  Click Here to Email MaDbRiT     
Hi Gamer

At the moment I don't quite understand what you mean by the above.

If you can send me your ASL file I should be able to see what's wrong for you.

Al Bampton (a.k.a. MaDbRiT)

MaDbRiT posted 03-06-2003 12:48 BST     Click Here to See the Profile for MaDbRiT  Click Here to Email MaDbRiT     
Hi again,

D' Oh! The 'penny dropped' as to what you meant just after posting my last reply, you are quite correct, the inbuilt QDK 'takeable / action' script won't work if you use typelib.qlb This is because my typelib provides a default take action for regular objects, so any script will automatically be overridden.

This isn't actually a problem, once you realise that to alter the library's default behaviour you just have to provide an alternative take action rather than specify a take script. (basically you have to write exactly the same code, but in a different place.)

This is down to the way Quest supports inheritance, but I'll avoid the temptation of trying to explain O.O.P. in the forum :-).

Anyways, here's a cut n' paste example of using an 'action' to override the library code, hope this solves your problem.

quote:

' "TEST"
' Created with QDK Pro 3.12

!include <Typelib.qlb>

define game <TEST>
asl-version <311>
start <start>
game author <MaDbRiT>
game version <.001>
game copyright <© Al Bampton>
game info <Created with QDK Pro 3.12>
end define

define synonyms
end define

define room <start>
alias <only room>
prefix <the>

define object <widget>
type <TLTobject>
action <take> msg <use an action to override the library!>
end define

end define

define text <intro>

end define

define text <win>

end define

define text <lose>

end define


Post New Topic  Post Reply
Hop to:


Contact Us | Axe Software

Powered by: Ultimate Bulletin Board, Freeware Version 2000a
Purchase our Licensed Version- which adds many more features!
© Infopop Corporation (formerly Madrona Park, Inc.), 1998 - 2000.