Ares
| 369 | |
| 370 | // Ares |
| 371 | HouseClass* HouseExt::GetHouseKind(OwnerHouseKind const kind, bool const allowRandom, HouseClass* const pDefault, HouseClass* const pInvoker, HouseClass* const pVictim) |
| 372 | { |
| 373 | switch (kind) |
| 374 | { |
| 375 | case OwnerHouseKind::Invoker: |
| 376 | case OwnerHouseKind::Killer: |
| 377 | return pInvoker ? pInvoker : pDefault; |
| 378 | case OwnerHouseKind::Victim: |
| 379 | return pVictim ? pVictim : pDefault; |
| 380 | case OwnerHouseKind::Civilian: |
| 381 | return HouseClass::FindCivilianSide(); |
| 382 | case OwnerHouseKind::Special: |
| 383 | return HouseClass::FindSpecial(); |
| 384 | case OwnerHouseKind::Neutral: |
| 385 | return HouseClass::FindNeutral(); |
| 386 | case OwnerHouseKind::Random: |
| 387 | if (allowRandom) |
| 388 | { |
| 389 | auto& Random = ScenarioClass::Instance->Random; |
| 390 | return HouseClass::Array.GetItem( |
| 391 | Random.RandomRanged(0, HouseClass::Array.Count - 1)); |
| 392 | } |
| 393 | else |
| 394 | { |
| 395 | return pDefault; |
| 396 | } |
| 397 | case OwnerHouseKind::Default: |
| 398 | default: |
| 399 | return pDefault; |
| 400 | } |
| 401 | } |
| 402 | |
| 403 | void HouseExt::ExtData::AddToLimboTracking(TechnoTypeClass* pTechnoType) |
| 404 | { |
nothing calls this directly
no outgoing calls
no test coverage detected