Skip to content
This repository has been archived by the owner on Feb 7, 2020. It is now read-only.

Create object classes #43

Closed
crankycyclops opened this issue Dec 3, 2012 · 1 comment
Closed

Create object classes #43

crankycyclops opened this issue Dec 3, 2012 · 1 comment
Assignees
Milestone

Comments

@crankycyclops
Copy link
Owner

Some examples are "text (book, scroll, etc.)", "key," etc. Each class will probably have certain properties set by default (for example text, by default, will have a readable block of text for the player to see when they issue a "read" command.) Objects should then, in addition to names and synonyms, be identifiable by class.

The hierarchy for recognizing objects by class name should be as follows:

First, recognize objects with name/synonym. If these are found, ignore class. If no objects are found by name/synonym, then see if there's an object of the specified class, and if so, you can interact with it. This will be an enhancement to the static function getObject(), most likely.

Pre-defined object classes might have special tags that can go in the section of game.xml. For example, if it's a text, instead of:

[object name="book"]
...
[/object]

It would be something like:

[text name="book"]
...
[/text]

The text block would automatically imply certain attributes that would otherwise have to be explicitly stated in a generic block.

In the future, I may want to create a mechanism to allow the game developer to specify extra custom classes (probably want to put in another ticket for that! :)

@ghost ghost assigned crankycyclops Dec 3, 2012
@crankycyclops
Copy link
Owner Author

Reopened on Trogdor-pp.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant