Structures for player data and variables within

From: Minturn.Del.PRC.Oceana (Del@PRCOceana.Corona.Navy.Mil)
Date: 03/20/00

The recent question on the understanding of (ch)->player.level
was directed to me personally. However I was not 100 percent sure
of my answer. (mostly terminology)

The basic question was why (ch)->player.level was just that, instead of

I had never researched it before, and myself being inexperienced with
structures, I followed the code through for this type of answer.

Can the more experienced put the right labels on my answer or better
explanation? or atleast let me know if my understanding is correct.


struct char_player_data {
   byte level;         /* PC / NPC's level                     */

struct char_data {
   struct char_player_data player;       /* Normal data                   */

NOTE: the variable name player.

It was hiding in there and if I read it right..

ch = char_data structure (in this scenerio)
player = char_player_data structure
level = the finial variable in the structure mess!

     | Ensure that you have read the CircleMUD Mailing List FAQ:  |
     |  |

This archive was generated by hypermail 2b30 : 04/10/01 PDT