2
0
mirror of https://github.com/AxioDL/metaforce.git synced 2025-12-15 07:26:10 +00:00

Various bug fixes

This commit is contained in:
Jack Andersen
2019-01-04 22:34:09 -10:00
parent d60fcc99c9
commit f9b0614327
19 changed files with 187 additions and 104 deletions

View File

@@ -14,11 +14,11 @@ namespace urde::MP1 {
CNewIntroBoss::CNewIntroBoss(TUniqueId uid, std::string_view name, const CEntityInfo& info, const zeus::CTransform& xf,
CModelData&& mData, const CPatternedInfo& pInfo, const CActorParameters& actParms,
float turnRadius, CAssetId projectile, const CDamageInfo& dInfo, CAssetId beamContactFxId,
float minTurnAngle, CAssetId projectile, const CDamageInfo& dInfo, CAssetId beamContactFxId,
CAssetId beamPulseFxId, CAssetId beamTextureId, CAssetId beamGlowTextureId)
: CPatterned(ECharacter::NewIntroBoss, uid, name, EFlavorType::Zero, info, xf, std::move(mData), pInfo,
EMovementType::Flyer, EColliderType::One, EBodyType::Restricted, actParms, EKnockBackVariant::Medium)
, x570_turnRadius(turnRadius)
, x570_minTurnAngle(minTurnAngle)
, x574_boneTracking(*GetModelData()->GetAnimationData(), "Head_1"sv, zeus::degToRad(80.f), zeus::degToRad(180.f), false)
, x5ac_projectileInfo(projectile, dInfo)
, x5f0_beamContactFxId(beamContactFxId)
@@ -328,7 +328,7 @@ bool CNewIntroBoss::ShouldTurn(CStateManager& mgr, float dt) {
zeus::CVector2f diffPos = (x604_predictedPlayerPos - GetTranslation()).toVec2f();
return zeus::CVector2f::getAngleDiff(GetTransform().frontVector().toVec2f(), diffPos) >
zeus::degToRad(x570_turnRadius);
zeus::degToRad(x570_minTurnAngle);
}
bool CNewIntroBoss::ShouldAttack(CStateManager& mgr, float dt) {