Differnet container/surface stuff
paul_one
30 Apr 2007, 15:30Right,
so I do try and do bits to my game when I can.. I think the start looks quite nice myself.
Rounding off the edges to try and get a nice polished effect...
.. Except, I have a surface (stump), and an object(bottle). When no object is on the surface it prints out the message "durr", while putting the bottle onto the table produces: "It contains: a bottle".
I don't know about you, but I think a more general "You see #objects# on the #quest.thing#" or "on the #quest.thing# you see #objects#".
(ie 'You see a bottle on the table' or 'On the table you see a bottle')
Is there any was I can do the second without parsing the #quest.command# variable and getting the object name.. and then getting the alias?
How about the first - without having to parse all the objects in the room and check if their parent property is the surface?
I would prefer to use the built-in quest functionality rather then try to botch my own and end up rewriting the whole container substructure myself.
Alex - any opinions on the matter, or perhaps knowledge on Quest which I may be looking in the wrong place for?
so I do try and do bits to my game when I can.. I think the start looks quite nice myself.
Rounding off the edges to try and get a nice polished effect...
.. Except, I have a surface (stump), and an object(bottle). When no object is on the surface it prints out the message "durr", while putting the bottle onto the table produces: "It contains: a bottle".
I don't know about you, but I think a more general "You see #objects# on the #quest.thing#" or "on the #quest.thing# you see #objects#".
(ie 'You see a bottle on the table' or 'On the table you see a bottle')
Is there any was I can do the second without parsing the #quest.command# variable and getting the object name.. and then getting the alias?
How about the first - without having to parse all the objects in the room and check if their parent property is the surface?
I would prefer to use the built-in quest functionality rather then try to botch my own and end up rewriting the whole container substructure myself.
Alex - any opinions on the matter, or perhaps knowledge on Quest which I may be looking in the wrong place for?
paul_one
30 Apr 2007, 16:06oops..
I thought I had posted something which was a mistake - but it wasn't...
Still I deleted it, so I'll have to re-type the gist of it:
command <look on #@object#> exec <look on #@object#;normal>
^^ works
list <#object# contains :>
simply outputs;
" contains ..."
I guess I'm doing a "list <script>" then...
I thought I had posted something which was a mistake - but it wasn't...
Still I deleted it, so I'll have to re-type the gist of it:
command <look on #@object#> exec <look on #@object#;normal>
^^ works
list <#object# contains :>
simply outputs;
" contains ..."
I guess I'm doing a "list <script>" then...
paul_one
01 May 2007, 11:30Do types work with surfaces?
When you try to 'put obj2 on obj1' it returns saying it cannot be done.
When you try to 'look on obj1' it returns saying "a table" - and nothing else.
Oh, and the list empty works fine the way it is because while 'obj3' is on 'obj1#'.. It is invisible and the list /would/ be empty.. I like this operation because you can have cool things - like mats etc which /are/ objects and are easy to define as objects - but you wouldn't want to show up in a list etc.
======DISASTER OVERTED=======
Seems that you need to add "container" into the type definition while not for object blocks (it's applied automatically to the object - but not if it's in a type definition.. I'm guessing this is because it's applied as a plain property in the types and if it's in the object definition it's applied as a hirarchial group of some sort).
======EDIT 2======
Erm, closing a surface gives the message "it is already closed"..
I think surfaces should be neither opened or closed.. But perhaps, if a default should be selected - I'd vote for opened.
define type <surface_01>
surface
add
list <hello?>
end define
define room <one>
look <room!>
define object <obj1>
look <a table>
type <surface_01>
list empty exec <look at obj3>
end define
define object <obj2>
look <a bottle>
end define
define object <obj3>
parent <obj1>
properties <invisible>
end define
end define
When you try to 'put obj2 on obj1' it returns saying it cannot be done.
When you try to 'look on obj1' it returns saying "a table" - and nothing else.
Oh, and the list empty works fine the way it is because while 'obj3' is on 'obj1#'.. It is invisible and the list /would/ be empty.. I like this operation because you can have cool things - like mats etc which /are/ objects and are easy to define as objects - but you wouldn't want to show up in a list etc.
======DISASTER OVERTED=======
Seems that you need to add "container" into the type definition while not for object blocks (it's applied automatically to the object - but not if it's in a type definition.. I'm guessing this is because it's applied as a plain property in the types and if it's in the object definition it's applied as a hirarchial group of some sort).
======EDIT 2======
Erm, closing a surface gives the message "it is already closed"..
I think surfaces should be neither opened or closed.. But perhaps, if a default should be selected - I'd vote for opened.
Elexxorine
01 May 2007, 18:02Make them 'open' and unclosable. Glad you worked it out yourself btw..... *hug*