OpenEnroth 73e68f7
Loading...
Searching...
No Matches
Public Member Functions | Static Public Member Functions | Public Attributes | Private Attributes | List of all members
Party Struct Reference

#include <Party.h>

Public Member Functions

 Party ()
 
void Zero ()
 
void resetCharacterEmotions ()
 
void updateCharactersAndHirelingsEmotions ()
 
void restAndHeal ()
 
unsigned int getPartyFame ()
 
void createDefaultParty (bool bDebugGiveItems=false)
 
void Reset ()
 
void ResetPosMiscAndSpellBuffs ()
 
bool hasItem (ItemId uItemID)
 
void setHoldingItem (ItemGen *pItem)
 
void setActiveToFirstCanAct ()
 
void switchToNextActiveCharacter ()
 
bool checkPartyPerceptionAgainstCurrentMap ()
 
int canActCount () const
 
bool addItemToParty (ItemGen *pItem, bool isSilent=false)
 
void yell ()
 
int CountHirelings ()
 
void GivePartyExp (unsigned int pEXPNum)
 
int GetPartyReputation ()
 
void partyFindsGold (int amount, GoldReceivePolicy policy)
 
void placeHeldItemInInventoryOrDrop ()
 
void dropHeldItem ()
 
int GetGold () const
 
void SetGold (int amount, bool silent=false)
 
void AddGold (int amount)
 
void TakeGold (int amount, bool silent=false)
 
int GetFood () const
 
void SetFood (int amount)
 
void TakeFood (int amount)
 
void GiveFood (int amount)
 
int GetBankGold () const
 
void SetBankGold (int amount)
 
void AddBankGold (int amount)
 
void TakeBankGold (int amount)
 
int GetFine () const
 
void SetFine (int amount)
 
void AddFine (int amount)
 
void TakeFine (int amount)
 
void giveFallDamage (int distance)
 
bool wizardEyeActive () const
 
CharacterSkillMastery wizardEyeSkillLevel () const
 
bool TorchlightActive () const
 
bool FlyActive () const
 
bool WaterWalkActive () const
 
bool ImmolationActive () const
 
CharacterSkillMastery ImmolationSkillLevel () const
 
bool FeatherFallActive () const
 
bool Invisible () const
 
bool GetRedAlert () const
 
void SetRedAlert ()
 
bool GetYellowAlert () const
 
void SetYellowAlert ()
 
bool GetRedOrYellowAlert () const
 
bool isAirborne () const
 
void setAirborne (bool new_state)
 
bool wearsItemAnywhere (ItemId item_id) const
 
int getRandomActiveCharacterId (RandomEngine *rng) const
 
int getCharacterIdInParty (Character *character)
 
TimeGetPlayingTime ()
 
bool isPartyEvil ()
 
bool isPartyGood ()
 
size_t immolationAffectedActors (int *affected, size_t affectedArrSize, size_t effectRange)
 
void setDelayedReaction (CharacterSpeech speech, int id)
 
void updateDelayedReaction ()
 
int activeCharacterIndex () const
 
void setActiveCharacterIndex (int id)
 
bool hasActiveCharacter () const
 
CharacteractiveCharacter ()
 

Static Public Member Functions

static void restOneFrame ()
 

Public Attributes

int height
 
int eyeLevel
 
int radius
 
int _yawGranularity
 
int walkSpeed
 
int _yawRotationSpeed
 
int jump_strength
 
Time playing_time
 
Time last_regenerated
 
PartyTimeStruct PartyTimes
 
Vec3f pos
 
Vec3f velocity
 
int _viewYaw
 
int _viewPitch
 
Vec3f lastPos
 
int _viewPrevYaw
 
int _viewPrevPitch
 
int lastEyeLevel
 
int sPartySavedFlightZ
 
int floor_face_id
 
SoundId currentWalkingSound
 
Time _6FC_water_lava_timer
 
int uFallStartZ
 
unsigned int bFlying
 
int hirelingScrollPosition
 
char cNonHireFollowers
 
unsigned int uCurrentYear
 
unsigned int uCurrentMonth
 
unsigned int uCurrentMonthWeek
 
unsigned int uCurrentDayOfMonth
 
unsigned int uCurrentHour
 
unsigned int uCurrentMinute
 
unsigned int uCurrentTimeSecond
 
unsigned int uNumFoodRations
 
unsigned int uNumGold
 
unsigned int uNumGoldInBank
 
int uNumDeaths
 
int uNumPrisonTerms
 
unsigned int uNumBountiesCollected
 
IndexedArray< MonsterId, HOUSE_FIRST_TOWN_HALL, HOUSE_LAST_TOWN_HALLmonster_id_for_hunting
 
IndexedArray< bool, HOUSE_FIRST_TOWN_HALL, HOUSE_LAST_TOWN_HALLmonster_for_hunting_killed
 
unsigned char days_played_without_rest
 
IndexedBitset< QBIT_FIRST, QBIT_LAST_questBits
 
IndexedArray< bool, HOUSE_FIRST_ARCOMAGE_TAVERN, HOUSE_LAST_ARCOMAGE_TAVERNpArcomageWins
 
ArenaState arenaState = ARENA_STATE_INITIAL
 
ArenaLevel arenaLevel = ARENA_LEVEL_INVALID
 
IndexedArray< uint8_t, ARENA_LEVEL_FIRST_VALID, ARENA_LEVEL_LAST_VALIDuNumArenaWins
 
IndexedArray< bool, ITEM_FIRST_SPAWNABLE_ARTIFACT, ITEM_LAST_SPAWNABLE_ARTIFACTpIsArtifactFound
 
IndexedBitset< 1, 208 > _autonoteBits
 
int uNumArcomageWins
 
int uNumArcomageLoses
 
bool bTurnBasedModeOn
 
PARTY_FLAGS_2 uFlags2
 
PartyAlignment alignment
 
IndexedArray< SpellBuff, PARTY_BUFF_FIRST, PARTY_BUFF_LASTpPartyBuffs
 
std::array< Character, 4 > pCharacters
 
std::array< NPCData, 2 > pHirelings
 
std::array< NPCSacrificeStatus, 2 > pHirelingsSacrifice
 
ItemGen pPickedItem
 
PartyFlags uFlags
 
IndexedArray< std::array< ItemGen, 12 >, HOUSE_FIRST_SHOP, HOUSE_LAST_SHOPstandartItemsInShops
 
IndexedArray< std::array< ItemGen, 12 >, HOUSE_FIRST_SHOP, HOUSE_LAST_SHOPspecialItemsInShops
 
IndexedArray< std::array< ItemGen, 12 >, HOUSE_FIRST_MAGIC_GUILD, HOUSE_LAST_MAGIC_GUILDspellBooksInGuilds
 
std::string pHireling1Name
 
std::string pHireling2Name
 
Duration armageddon_timer
 
int armageddonDamage
 
int armageddonForceCount { 0 }
 
std::array< Duration, 4 > pTurnBasedCharacterRecoveryTimes
 
IndexedArray< int, HOUSE_FIRST_SHOP, HOUSE_LAST_SHOPInTheShopFlags
 
int uFine = 0
 
float TorchLightLastIntensity = 0.0f
 
Duration _roundingDt
 
Duration _delayedReactionTimer
 
CharacterSpeech _delayedReactionSpeech = SPEECH_NONE
 
int _delayedReactionCharacterId = -1
 
std::array< bool, 4 > playerAlreadyPicked = {{}}
 

Private Attributes

int _activeCharacter = 0
 

Constructor & Destructor Documentation

◆ Party()

Party::Party ( )
inline

Member Function Documentation

◆ activeCharacter()

Character & Party::activeCharacter ( )
inline

◆ activeCharacterIndex()

int Party::activeCharacterIndex ( ) const
inline
Returns
1-based index of currently active character. Zero means that there is no active character.

◆ AddBankGold()

void Party::AddBankGold ( int  amount)

◆ AddFine()

void Party::AddFine ( int  amount)

◆ AddGold()

void Party::AddGold ( int  amount)

◆ addItemToParty()

bool Party::addItemToParty ( ItemGen pItem,
bool  isSilent = false 
)
Original binary offset:
0x48C6F6

◆ canActCount()

int Party::canActCount ( ) const
Returns
Total number of characters who can act.

◆ checkPartyPerceptionAgainstCurrentMap()

bool Party::checkPartyPerceptionAgainstCurrentMap ( )
Original binary offset:
0x497FC5

◆ CountHirelings()

int Party::CountHirelings ( )

◆ createDefaultParty()

void Party::createDefaultParty ( bool  bDebugGiveItems = false)
Original binary offset:
0x49137D

◆ dropHeldItem()

void Party::dropHeldItem ( )

◆ FeatherFallActive()

bool Party::FeatherFallActive ( ) const
inline

◆ FlyActive()

bool Party::FlyActive ( ) const
inline

◆ GetBankGold()

int Party::GetBankGold ( ) const

◆ getCharacterIdInParty()

int Party::getCharacterIdInParty ( Character character)
inline

Return id of character that is represented by given pointer.

Parameters
characterCharacter pointer.
Returns
0-based index of the given character in party.

◆ GetFine()

int Party::GetFine ( ) const

◆ GetFood()

int Party::GetFood ( ) const

◆ GetGold()

int Party::GetGold ( ) const

◆ getPartyFame()

unsigned int Party::getPartyFame ( )
Original binary offset:
0x49135E

◆ GetPartyReputation()

int Party::GetPartyReputation ( )

◆ GetPlayingTime()

Time & Party::GetPlayingTime ( )
inline

◆ getRandomActiveCharacterId()

int Party::getRandomActiveCharacterId ( RandomEngine rng) const

Return id of random character that can still act.

Parameters
rngRandom generator used.
Returns
ID of character or -1 if none of the character cat act.

◆ GetRedAlert()

bool Party::GetRedAlert ( ) const
inline

◆ GetRedOrYellowAlert()

bool Party::GetRedOrYellowAlert ( ) const
inline

◆ GetYellowAlert()

bool Party::GetYellowAlert ( ) const
inline

◆ giveFallDamage()

void Party::giveFallDamage ( int  distance)

New function - applies fall damage with modifiers to all party members

Parameters
distanceFall distance

◆ GiveFood()

void Party::GiveFood ( int  amount)

◆ GivePartyExp()

void Party::GivePartyExp ( unsigned int  pEXPNum)

◆ hasActiveCharacter()

bool Party::hasActiveCharacter ( ) const
inline

◆ hasItem()

bool Party::hasItem ( ItemId  uItemID)
Original binary offset:
0x493244

◆ ImmolationActive()

bool Party::ImmolationActive ( ) const
inline

◆ immolationAffectedActors()

size_t Party::immolationAffectedActors ( int *  affected,
size_t  affectedArrSize,
size_t  effectRange 
)
Original binary offset:
0x46A89E

◆ ImmolationSkillLevel()

CharacterSkillMastery Party::ImmolationSkillLevel ( ) const
inline

◆ Invisible()

bool Party::Invisible ( ) const
inline

◆ isAirborne()

bool Party::isAirborne ( ) const
inline

◆ isPartyEvil()

bool Party::isPartyEvil ( )

◆ isPartyGood()

bool Party::isPartyGood ( )

◆ partyFindsGold()

void Party::partyFindsGold ( int  amount,
GoldReceivePolicy  policy 
)
Original binary offset:
0x420C05

◆ placeHeldItemInInventoryOrDrop()

void Party::placeHeldItemInInventoryOrDrop ( )

◆ Reset()

void Party::Reset ( )

◆ resetCharacterEmotions()

void Party::resetCharacterEmotions ( )

◆ ResetPosMiscAndSpellBuffs()

void Party::ResetPosMiscAndSpellBuffs ( )

◆ restAndHeal()

void Party::restAndHeal ( )
Original binary offset:
0x490D02

◆ restOneFrame()

void Party::restOneFrame ( )
static

Perform resting activity within current frame. Used to simulate party resting through time.

Original binary offset:
0x41F5BE

◆ setActiveCharacterIndex()

void Party::setActiveCharacterIndex ( int  id)
inline
Parameters
id1-based index of currently active character. Pass zero to make no one active.

◆ setActiveToFirstCanAct()

void Party::setActiveToFirstCanAct ( )

Sets _activeCharacter to the first character that can act Added to fix some nzi access problems

◆ setAirborne()

void Party::setAirborne ( bool  new_state)
inline

◆ SetBankGold()

void Party::SetBankGold ( int  amount)

◆ setDelayedReaction()

void Party::setDelayedReaction ( CharacterSpeech  speech,
int  id 
)
inline

◆ SetFine()

void Party::SetFine ( int  amount)

◆ SetFood()

void Party::SetFood ( int  amount)

◆ SetGold()

void Party::SetGold ( int  amount,
bool  silent = false 
)

◆ setHoldingItem()

void Party::setHoldingItem ( ItemGen pItem)
Original binary offset:
0x4936E1

◆ SetRedAlert()

void Party::SetRedAlert ( )
inline

◆ SetYellowAlert()

void Party::SetYellowAlert ( )
inline

◆ switchToNextActiveCharacter()

void Party::switchToNextActiveCharacter ( )

Sets _activeCharacter to the first active (recoverd) character

◆ TakeBankGold()

void Party::TakeBankGold ( int  amount)

◆ TakeFine()

void Party::TakeFine ( int  amount)

◆ TakeFood()

void Party::TakeFood ( int  amount)

◆ TakeGold()

void Party::TakeGold ( int  amount,
bool  silent = false 
)

◆ TorchlightActive()

bool Party::TorchlightActive ( ) const
inline

◆ updateCharactersAndHirelingsEmotions()

void Party::updateCharactersAndHirelingsEmotions ( )
Original binary offset:
0x4909F4

◆ updateDelayedReaction()

void Party::updateDelayedReaction ( )
inline

◆ WaterWalkActive()

bool Party::WaterWalkActive ( ) const
inline

◆ wearsItemAnywhere()

bool Party::wearsItemAnywhere ( ItemId  item_id) const
inline
Parameters
item_idItem type to check, e.g. ITEM_ARTIFACT_LADYS_ESCORT.
Returns
Whether the provided item is worn by at least one member of the party.

◆ wizardEyeActive()

bool Party::wizardEyeActive ( ) const
inline

◆ wizardEyeSkillLevel()

CharacterSkillMastery Party::wizardEyeSkillLevel ( ) const
inline

◆ yell()

void Party::yell ( )
Original binary offset:
0x43AD34

◆ Zero()

void Party::Zero ( )

Member Data Documentation

◆ _6FC_water_lava_timer

Time Party::_6FC_water_lava_timer

◆ _activeCharacter

int Party::_activeCharacter = 0
private

◆ _autonoteBits

IndexedBitset<1, 208> Party::_autonoteBits

◆ _delayedReactionCharacterId

int Party::_delayedReactionCharacterId = -1

◆ _delayedReactionSpeech

CharacterSpeech Party::_delayedReactionSpeech = SPEECH_NONE

◆ _delayedReactionTimer

Duration Party::_delayedReactionTimer

◆ _questBits

IndexedBitset<QBIT_FIRST, QBIT_LAST> Party::_questBits

◆ _roundingDt

Duration Party::_roundingDt

◆ _viewPitch

int Party::_viewPitch

◆ _viewPrevPitch

int Party::_viewPrevPitch

◆ _viewPrevYaw

int Party::_viewPrevYaw

◆ _viewYaw

int Party::_viewYaw

◆ _yawGranularity

int Party::_yawGranularity

◆ _yawRotationSpeed

int Party::_yawRotationSpeed

◆ alignment

PartyAlignment Party::alignment

◆ arenaLevel

ArenaLevel Party::arenaLevel = ARENA_LEVEL_INVALID

◆ arenaState

ArenaState Party::arenaState = ARENA_STATE_INITIAL

◆ armageddon_timer

Duration Party::armageddon_timer

◆ armageddonDamage

int Party::armageddonDamage

◆ armageddonForceCount

int Party::armageddonForceCount { 0 }

◆ bFlying

unsigned int Party::bFlying

◆ bTurnBasedModeOn

bool Party::bTurnBasedModeOn

◆ cNonHireFollowers

char Party::cNonHireFollowers

◆ currentWalkingSound

SoundId Party::currentWalkingSound

◆ days_played_without_rest

unsigned char Party::days_played_without_rest

◆ eyeLevel

int Party::eyeLevel

◆ floor_face_id

int Party::floor_face_id

◆ height

int Party::height

◆ hirelingScrollPosition

int Party::hirelingScrollPosition

◆ InTheShopFlags

IndexedArray<int, HOUSE_FIRST_SHOP, HOUSE_LAST_SHOP> Party::InTheShopFlags

◆ jump_strength

int Party::jump_strength

◆ last_regenerated

Time Party::last_regenerated

◆ lastEyeLevel

int Party::lastEyeLevel

◆ lastPos

Vec3f Party::lastPos

◆ monster_for_hunting_killed

IndexedArray<bool, HOUSE_FIRST_TOWN_HALL, HOUSE_LAST_TOWN_HALL> Party::monster_for_hunting_killed

◆ monster_id_for_hunting

◆ pArcomageWins

◆ PartyTimes

PartyTimeStruct Party::PartyTimes

◆ pCharacters

std::array<Character, 4> Party::pCharacters

◆ pHireling1Name

std::string Party::pHireling1Name

◆ pHireling2Name

std::string Party::pHireling2Name

◆ pHirelings

std::array<NPCData, 2> Party::pHirelings

◆ pHirelingsSacrifice

std::array<NPCSacrificeStatus, 2> Party::pHirelingsSacrifice

◆ pIsArtifactFound

◆ playerAlreadyPicked

std::array<bool, 4> Party::playerAlreadyPicked = {{}}

◆ playing_time

Time Party::playing_time

◆ pos

Vec3f Party::pos

◆ pPartyBuffs

◆ pPickedItem

ItemGen Party::pPickedItem

◆ pTurnBasedCharacterRecoveryTimes

std::array<Duration, 4> Party::pTurnBasedCharacterRecoveryTimes

◆ radius

int Party::radius

◆ sPartySavedFlightZ

int Party::sPartySavedFlightZ

◆ specialItemsInShops

IndexedArray<std::array<ItemGen, 12>, HOUSE_FIRST_SHOP, HOUSE_LAST_SHOP> Party::specialItemsInShops

◆ spellBooksInGuilds

IndexedArray<std::array<ItemGen, 12>, HOUSE_FIRST_MAGIC_GUILD, HOUSE_LAST_MAGIC_GUILD> Party::spellBooksInGuilds

◆ standartItemsInShops

IndexedArray<std::array<ItemGen, 12>, HOUSE_FIRST_SHOP, HOUSE_LAST_SHOP> Party::standartItemsInShops

◆ TorchLightLastIntensity

float Party::TorchLightLastIntensity = 0.0f

◆ uCurrentDayOfMonth

unsigned int Party::uCurrentDayOfMonth

◆ uCurrentHour

unsigned int Party::uCurrentHour

◆ uCurrentMinute

unsigned int Party::uCurrentMinute

◆ uCurrentMonth

unsigned int Party::uCurrentMonth

◆ uCurrentMonthWeek

unsigned int Party::uCurrentMonthWeek

◆ uCurrentTimeSecond

unsigned int Party::uCurrentTimeSecond

◆ uCurrentYear

unsigned int Party::uCurrentYear

◆ uFallStartZ

int Party::uFallStartZ

◆ uFine

int Party::uFine = 0

◆ uFlags

PartyFlags Party::uFlags

◆ uFlags2

PARTY_FLAGS_2 Party::uFlags2

◆ uNumArcomageLoses

int Party::uNumArcomageLoses

◆ uNumArcomageWins

int Party::uNumArcomageWins

◆ uNumArenaWins

◆ uNumBountiesCollected

unsigned int Party::uNumBountiesCollected

◆ uNumDeaths

int Party::uNumDeaths

◆ uNumFoodRations

unsigned int Party::uNumFoodRations

◆ uNumGold

unsigned int Party::uNumGold

◆ uNumGoldInBank

unsigned int Party::uNumGoldInBank

◆ uNumPrisonTerms

int Party::uNumPrisonTerms

◆ velocity

Vec3f Party::velocity

◆ walkSpeed

int Party::walkSpeed

The documentation for this struct was generated from the following files: