| 190 | } |
| 191 | |
| 192 | void CEffects::PlayerSpawn(vec2 Pos, float Alpha, float Volume) |
| 193 | { |
| 194 | for(int i = 0; i < 32; i++) |
| 195 | { |
| 196 | CParticle p; |
| 197 | p.SetDefault(); |
| 198 | p.m_Spr = SPRITE_PART_SHELL; |
| 199 | p.m_Pos = Pos; |
| 200 | p.m_Vel = random_direction() * (std::pow(random_float(), 3) * 600.0f); |
| 201 | p.m_LifeSpan = random_float(0.3f, 0.6f); |
| 202 | p.m_StartSize = random_float(64.0f, 96.0f); |
| 203 | p.m_EndSize = 0.0f; |
| 204 | p.m_Rot = random_angle(); |
| 205 | p.m_Rotspeed = random_float(); |
| 206 | p.m_Gravity = random_float(-400.0f); |
| 207 | p.m_Friction = 0.7f; |
| 208 | p.m_Color = ColorRGBA(0xb5 / 255.0f, 0x50 / 255.0f, 0xcb / 255.0f, Alpha); |
| 209 | p.m_StartAlpha = Alpha; |
| 210 | GameClient()->m_Particles.Add(CParticles::GROUP_GENERAL, &p); |
| 211 | } |
| 212 | if(g_Config.m_SndGame) |
| 213 | GameClient()->m_Sounds.PlayAt(CSounds::CHN_WORLD, SOUND_PLAYER_SPAWN, Volume, Pos); |
| 214 | } |
| 215 | |
| 216 | void CEffects::PlayerDeath(vec2 Pos, int ClientId, float Alpha) |
| 217 | { |
no test coverage detected