-------------------------------------------------------------------------------- Description: Adds one swarmer to this swarm --------------------------------------------------------------------------------
| 910 | // Adds one swarmer to this swarm |
| 911 | // -------------------------------------------------------------------------------- |
| 912 | void EveSwarm::AddSwarmer() |
| 913 | { |
| 914 | auto componentRegistry = GetComponentRegistry(); |
| 915 | |
| 916 | EveSwarmRenderablePtr renderable; |
| 917 | renderable.CreateInstance(); |
| 918 | renderable->InitializeRenderable( this, m_mesh ); |
| 919 | renderable->InitDecals( m_decals ); |
| 920 | |
| 921 | if( componentRegistry ) |
| 922 | { |
| 923 | renderable->Register( componentRegistry ); |
| 924 | } |
| 925 | |
| 926 | m_renderables.Append( renderable->GetRawRoot() ); |
| 927 | SwarmVehicle v; |
| 928 | v.position = m_worldPosition; |
| 929 | m_vehicles.push_back( v ); |
| 930 | if( m_debugShowForces ) |
| 931 | { |
| 932 | m_debugInfo.push_back( SwarmVehicleDebug() ); |
| 933 | } |
| 934 | m_count++; |
| 935 | |
| 936 | if( m_boosters ) |
| 937 | { |
| 938 | m_boosters->SetCount( m_count ); |
| 939 | } |
| 940 | } |
| 941 | |
| 942 | // -------------------------------------------------------------------------------- |
| 943 | // Description: |
nothing calls this directly
no test coverage detected