public override void AssignParameters(SpawnerEntityMissionHelper _spawnerMissionHelper) { base.AssignParameters(_spawnerMissionHelper); _spawnerMissionHelper.SpawnedEntity.GetFirstScriptOfType <DestructableComponent>().MaxHitPoint = 15000f; SiegeTower firstScriptOfType = _spawnerMissionHelper.SpawnedEntity.GetFirstScriptOfType <SiegeTower>(); firstScriptOfType.MaxSpeed *= 1f; firstScriptOfType.MinSpeed *= 1f; }
public static void Postfix(SiegeTower __instance) { var lqms = Traverse.Create(__instance).Field("_queueManagers").GetValue <List <LadderQueueManager> >(); foreach (LadderQueueManager lqm in lqms) { int mdfid = (int)Traverse.Create(lqm).Field("ManagedNavigationFaceId").GetValue(); GameEntity cs = (GameEntity)Traverse.Create(__instance).Field("_cleanState").GetValue(); cs.Scene.SetAbilityOfFacesWithId(mdfid, false); lqm.IsDeactivated = false; } }
public override void AssignParameters(SpawnerEntityMissionHelper _spawnerMissionHelper) { SiegeTower firstScriptOfType = _spawnerMissionHelper.SpawnedEntity.GetFirstScriptOfType <SiegeTower>(); firstScriptOfType.AddOnDeployTag = this.AddOnDeployTag; firstScriptOfType.RemoveOnDeployTag = this.RemoveOnDeployTag; firstScriptOfType.MaxSpeed *= this.SpeedModifierFactor; firstScriptOfType.MinSpeed *= this.SpeedModifierFactor; Mat3 identity = Mat3.Identity; identity.RotateAboutSide(this.RampRotationRadian); firstScriptOfType.AssignParametersFromSpawner(this.PathEntityName, this.TargetWallSegmentTag, this.SideTag, this.SoilNavMeshID1, this.SoilNavMeshID2, this.DitchNavMeshID1, this.DitchNavMeshID2, this.GroundToSoilNavMeshID1, this.GroundToSoilNavMeshID2, this.SoilGenericNavMeshID, this.GroundGenericNavMeshID, identity, this.BarrierTagToRemove); }
public static bool Prefix(ref OrderType __result, SiegeTower __instance, BattleSideEnum side) { if (side == BattleSideEnum.Defender) { __result = OrderType.AttackEntity; return(false); } if (__instance.IsDestroyed | __instance.IsDeactivated | __instance.IsDisabled) { __result = OrderType.None; return(false); } __result = OrderType.Use; return(false); }
private void OnCollisionEnter(Collision collision) { if (collision.collider.tag.Equals("Enemy")) { SiegeTower towerScript = collision.gameObject.GetComponent <SiegeTower>(); int num = Random.Range(0, 2); if (num == 0) { this.canMove = false; } else { if (this.canMove == true) { towerScript.canMove = false; } } } }
public SiegeTowerAI(SiegeTower siegeTower) : base((UsableMachine)siegeTower) { }
public SetSiegeTowerHasArrivedAtTarget(SiegeTower siegeTower) => this.SiegeTower = siegeTower;
public SetSiegeTowerGateState(SiegeTower siegeTower, SiegeTower.GateState state) { this.SiegeTower = siegeTower; this.State = state; }