//-----------Prüft, ob das Objekt zerstört(noch nicht gelöscht) wurde und erstellt Explosion------ bool CheckIfDestroyed(LPOBJEKT lpObjekt) { if (lpObjekt->zustand == OZ_DESTROYED) { // Nicht bei jedem Objekt ist die Todesanimation gleich->Selektion switch(lpObjekt->typ) { case UD_PLAYERSHIP: { lpObjekt->zustand = OZ_DEAD; CreateObjekt(lpObjekt->x, lpObjekt->y, 0, 0, UD_EXP64); SetProgControl(PC_SHOWDEATH); return true; } case UD_STONE64: { Score += 100*3; CreateObjekt(lpObjekt->x, lpObjekt->y, 0, 0, UD_EXP64); lpObjekt->zustand = OZ_DEAD; return true; } case UD_MONSTER1A: { Score += 200*3; CreateParticleSystem(lpObjekt->x, lpObjekt->y, 2); CreateObjekt(lpObjekt->x, lpObjekt->y, 0, 0, UD_EXP32); lpObjekt->zustand = OZ_DEAD; return true; } case UD_MONSTER1B: { Score += 300*3; CreateParticleSystem(lpObjekt->x, lpObjekt->y, 2); CreateObjekt(lpObjekt->x, lpObjekt->y, 0, 0, UD_EXP32); lpObjekt->zustand = OZ_DEAD; return true; } case UD_SCHUSS: { CreateObjekt(lpObjekt->x, lpObjekt->y, 0, 0, UD_EXP16); lpObjekt->zustand = OZ_DEAD; return true; } case UD_STDROCKET: { CreateObjekt(lpObjekt->x, lpObjekt->y, 0, 0, UD_EXP16); lpObjekt->zustand = OZ_DEAD; return true; } default: {return false;} } } return false; }
ETHParticleManager::ETHParticleManager( ETHResourceProviderPtr provider, const ETHParticleSystem& partSystem, const Vector2& v2Pos, const Vector3& v3Pos, const float angle, const float entityVolume, const float scale) : m_provider(provider) { CreateParticleSystem(partSystem, v2Pos, v3Pos, angle, entityVolume, scale); }
void CParticleToolPal::ToggleParticleSystem( bool bshow ) { if( m_ParticleVisible && !bshow ) { RemoveParticleSystem(); } else if( !m_ParticleVisible && bshow ) { m_ToolBox->SendMessage(_T("InitParticles"),0,NULL); CreateParticleSystem(); m_PropertiesDlg.UpdateParticleObject(); } }
ETHParticleManager::ETHParticleManager( ETHResourceProviderPtr provider, const str_type::string& file, const Vector2& v2Pos, const Vector3& v3Pos, const float angle, const float entityVolume) : m_provider(provider) { ETHParticleSystem partSystem; if (partSystem.ReadFromFile(file, m_provider->GetFileManager())) { CreateParticleSystem(partSystem, v2Pos, v3Pos, angle, entityVolume, 1.0f); } else { ETH_STREAM_DECL(ss) << GS_L("ETHParticleManager: file not found: ") << file; m_provider->Log(ss.str(), Platform::FileLogger::ERROR); } }