Re: Data structure for movements?

[ Follow Ups ] [ Post Followup ] [ CS2704 Web Discussion Board ] [ FAQ ]

Posted by Ricky Castles on April 16, 2001 at 22:21:59:

In Reply to: Data structure for movements? posted by Carl Cospel on April 15, 2001 at 23:29:35:

: I don't understand this part of the specifications:

: Data structures are an issue in two places . . . . Most creatures must also store a list of movements and keep track of which movement to perform next. These should not be separate, unorganized data memebers.

: Are the movements supposed to be stored outside of the specific creatures class? Can anybody reword this for me? Thanx

The way I handled the movements was to make an enumerated type for the grendel and the herbivores that had their various movements in the order in which they moved. The specification however seems to lead toward having a stack or a queue of movements and that when you go to move, it would "pop" off the next command and I suppose once the entire sequence had been carried out it would reload the stack/queue with the movements again. I am wondering if my enumerated type declaration is acceptable to be considered an "organized" set of data members. Those are the two ways I interpret the statements in the spec.

Follow Ups:

Post a Followup




Optional Link URL:
Link Title:
Optional Image URL:

[ Follow Ups ] [ Post Followup ] [ CS2704 Web Discussion Board ] [ FAQ ]