view NPC.h @ 252:e22e2357c8b3

Merge
author Gloval
date Mon, 18 Feb 2013 08:59:34 +0400
parents 48f21f569328 37dcbe8f3cca
children f1218b9d67f1
line wrap: on
line source

#pragma once


struct NPCTopic
{
  const char *pTopic;
  const char *pText;
};

extern NPCTopic pNPCTopics[789];





/*  136 */
#pragma pack(push, 1)
struct NPCData
{
  inline bool Hired() {return uFlags & 0x80;}

  char *pName;
  unsigned int uPortraitID;
  unsigned int uFlags;         // & 0x80    no greeting on dialogue start; looks like hired
  int fame;
  int rep;
  int house;
  unsigned int uProfession;
  int greet;
  int joins;
  int field_24;
  unsigned int bDrawSomeAnim;
  int _anim_current_time; //evtb
  int _anim_end_time; //evtc
  int evtd;
  int evte;
  int evtf;
  int uSex;
  int bHasUsedTheAbility;
  int news_topic;
};
#pragma pack(pop)


/*  138 */
#pragma pack(push, 1)
struct NPCProfession
{
  unsigned int uHirePrice;
  char *pBenefits;
  char *pActionText;
  char *pJoinText;
  char *pDismissText;
};
#pragma pack(pop)


/*  139 */
#pragma pack(push, 1)
struct NPCStats_stru0
{
  int field_0;  //summ 
  char field_4[60]; //prof position
};
#pragma pack(pop)

/*  140 */
#pragma pack(push, 1)
struct NPCGreeting
{
  char *pGreeting1;
  char *pGreeting2;
};
#pragma pack(pop)



/*  137 */
#pragma pack(push, 1)
struct NPCStats
{
  inline NPCStats():
    pNPCTextTXT_Raw(nullptr), pNPCTopicTXT_Raw(nullptr), pNPCDistTXT_Raw(nullptr)
  {
    uNumNPCNames[0] = uNumNPCNames[1] = 0;
  }

  void Initialize2();
  void Initialize1();
  void Initialize();
  void Release();
  bool InitializeAdditionalNPCs(NPCData *a2, int a3, int a4, int a5);
  void _476C60();

  
  NPCData pNPCData[501];
  NPCData pNewNPCData[501];
  char *pNPCNames[540][2];
  int field_13A58;
  int field_13A5C;
  int field_13A60;
  int field_13A64;
  int field_13A68;
  NPCProfession pProfessions[58];
  NPCData array_13EF4[100];
  char *pCatchPhrases[52];
  char *pNPCNames2[500];
  NPCStats_stru0 array_16544[77]; //16544h proffesion position in area
  int field_17884;
  int field_17888;
  NPCGreeting pNPCGreetings[205];
  unsigned __int16 pGroups[51];
  unsigned __int16 pGroups_copy[51];
  int field_17FC0;
  unsigned int uNumNewNPCs;
  int field_17FC8;
  unsigned int uNumNPCProfessions;
  unsigned int uNumNPCNames[2];
  char *pNPCDataTXT_Raw;
  char *pNPCNamesTXT_Raw;
  char *pNPCProfTXT_Raw;
  char *pNPCNewsTXT_Raw;
  char *pNPCTopicTXT_Raw;
  char *pNPCTextTXT_Raw;
  char *pNPCDistTXT_Raw;
  char *pNPCGreetTXT_Raw;
  char *pNCPGroupTXT_Raw;
};
#pragma pack(pop)

bool __cdecl sub_476387();
bool CheckHiredNPCSpeciality(unsigned int uProfession);