void ActivateReportTriggers() { UINT32 j; for (j=0;j<iNumReports;j++) { if (strcmp(aReports[j].sOutputFile,"null")==0) { aReports[j].bActive = FALSE; aReports[j].fileOut = 0; } if (aReports[j].bActive) { if (strcmp(aReports[j].sOutputFile,"stdout")==0) { aReports[j].fileOut = stdout; } else if (strcmp(aReports[j].sOutputFile,"stderr")==0) { aReports[j].fileOut = stderr; } else { if (aReports[j].bSpecialFileIO == FALSE) { aReports[j].fileOut = fopen(aReports[j].sOutputFile,"w"); if (aReports[j].fileOut == 0) { printf("Fatal Error: Invalid filename [%s] specified \n",aReports[j].sOutputFile); AbnormalExit(); } } } ActivateTriggers(aReports[j].sTriggers); } } }
void CBloodFlower::PodAttack(CStateManager& mgr, EStateMsg msg, float arg) { if (msg == EStateMsg::Activate) { x450_bodyController->GetCommandMgr().DeliverCmd(CBCMeleeAttackCmd(pas::ESeverity::Zero)); x574_podEffect->SetParticleEmission(true); ActivateTriggers(mgr, true); } else if (msg == EStateMsg::Update) { if (TooClose(mgr, 0.f)) return; mgr.ApplyDamage(GetUniqueId(), mgr.GetPlayer().GetUniqueId(), GetUniqueId(), x5f8_podDamage, CMaterialFilter::MakeIncludeExclude({EMaterialTypes::Solid}, {}), {}); } else if (msg == EStateMsg::Deactivate) { x574_podEffect->SetParticleEmission(false); ActivateTriggers(mgr, false); x450_bodyController->GetCommandMgr().DeliverCmd(CBCKnockBackCmd({}, pas::ESeverity::One)); } }