void obj_Player::StartPickup()
{
ChangeWeaponByIndex(HANDS_WEAPON_IDX);
uberAnim_->StartPickupAnim();
PKT_C2C_StartPickup_s n;
p2pSendToHost(this, &n, sizeof(n));
// more code is needed -/- random AI dialog sound
// more code is needed -/- cancel the sound when the AI change the playerstate
// more code is needed -/- sync animation with the default idl playerstate
}
[CODE=cpp]uberAnim_->StartPickupAnim(); //start pickup animation here - temporal logic
C++:
// if we picked up weapon with empty hands - switch to it
if(m_SelectedWeapon == HANDS_WEAPON_IDX && (n.SlotTo == wiCharDataFull::CHAR_LOADOUT_WEAPON1 || n.SlotTo == wiCharDataFull::CHAR_LOADOUT_WEAPON2))
{
ChangeWeaponByIndex(n.SlotTo);
}
hudMain->showMessage(gLangMngr.getString("InfoMsg_NewItemAdded"));
C++:
uberAnim_->StartPickupAnim(); //start pickup animation here - temporal logic