/////////////////////////////////////////////////////////////////////
| 1566 | |
| 1567 | ////////////////////////////////////////////////////////////////////////// |
| 1568 | void CEntity::UpdateSounds( SEntityUpdateContext &ctx ) |
| 1569 | { |
| 1570 | if (!m_lstAttachedSounds.empty()) |
| 1571 | { |
| 1572 | ENTITY_PROFILER |
| 1573 | |
| 1574 | SoundsListItor itor = m_lstAttachedSounds.begin(); |
| 1575 | Vec3d vPos= GetSoundPos(); |
| 1576 | while(itor!=m_lstAttachedSounds.end()) |
| 1577 | { |
| 1578 | SAttachedSound &Sound=(*itor); |
| 1579 | #if !defined(LINUX64) |
| 1580 | if((Sound.pSound!=NULL) && (Sound.pSound->IsPlaying() || Sound.pSound->IsPlayingVirtual())) |
| 1581 | #else |
| 1582 | if((Sound.pSound!=0) && (Sound.pSound->IsPlaying() || Sound.pSound->IsPlayingVirtual())) |
| 1583 | #endif |
| 1584 | { |
| 1585 | Sound.pSound->SetPosition(vPos+Sound.Offset); |
| 1586 | ++itor; |
| 1587 | } |
| 1588 | else |
| 1589 | { |
| 1590 | itor=m_lstAttachedSounds.erase(itor); |
| 1591 | } |
| 1592 | } |
| 1593 | } |
| 1594 | m_bUpdateSounds = !m_lstAttachedSounds.empty(); |
| 1595 | } |
| 1596 | |
| 1597 | ////////////////////////////////////////////////////////////////////////// |
| 1598 | void CEntity::UpdatePhysics( SEntityUpdateContext &ctx ) |
nothing calls this directly
no test coverage detected