Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- if (parentUnit.Entity.Name == "Spear Thrower")
- {
- projectile.GetComponentInChildren<Compensation>().upwardsRangeCompensation *= 0.8f;
- projectile.GetComponentInChildren<Compensation>().rangePow *= 0.8f;
- projectile.GetComponentInChildren<Compensation>().positionPredictionAmount *= 1f;
- projectile.GetComponentInChildren<Compensation>().velocityPrediction = 0f;
- projectile.GetComponentInChildren<ProjectileHit>().damage *= 1f;
- projectile.GetComponentInChildren<ProjectileHit>().force *= 0.5f;
- projectile.GetComponentInChildren<ProjectileHit>().shakeAmount *= 2f;
- projectile.GetComponentInChildren<ProjectileHit>().blockPoweredNeeded *= 1f;
- projectile.GetComponentInChildren<ProjectileHit>().callEffectsOnArmor = true;
- projectile.GetComponentInChildren<ProjectileHit>().destroyOnHit = false;
- projectile.GetComponentInChildren<ProjectileHit>().ignoreTeamMates = true;
- projectile.transform.localScale += new Vector3(0f, 0f, 0f);
- projectile.transform.localScale -= new Vector3(0f, 0f, 0f);
- Renderer[] componentsInChildren = projectile.GetComponentsInChildren<Renderer>();
- checked
- {
- for (int i = 0; i < componentsInChildren.Length; i++)
- {
- componentsInChildren[i].material.color = new Color(1f, 1f, 1f);
- for (int j = 0; j < componentsInChildren[i].materials.Length; j++)
- {
- Color color;
- switch (j)
- {
- case 0:
- color = new Color(0f, 0f, 0f);
- break;
- case 1:
- color = new Color(0f, 0f, 0f);
- break;
- case 2:
- color = new Color(0f, 0f, 0f);
- break;
- default:
- color = new Color(0f, 0f, 0f);
- break;
- }
- componentsInChildren[i].materials[j].color = color;
- }
- }
- for (int k = 0; k < componentsInChildren.Length; k++)
- {
- switch (k)
- {
- case 0:
- componentsInChildren[k].enabled = true;
- break;
- case 1:
- componentsInChildren[k].enabled = true;
- break;
- case 2:
- componentsInChildren[k].enabled = true;
- break;
- default:
- componentsInChildren[k].enabled = true;
- break;
- }
- }
- }
- }
- checked
- {
- if (parentUnit.Entity.Name == "Midas")
- {
- projectile.GetComponentInChildren<ProjectileHit>().onlyCallHitEventsOnRigsLessThan = 1E+10f;
- projectile.GetComponentInChildren<ProjectileHit>().ignoreTeamMates = true;
- projectile.GetComponentInChildren<ProjectileHit>().callEffectsBeforeDamage = true;
- projectile.GetComponentInChildren<ProjectileHit>().callEffectsOnArmor = true;
- projectile.GetComponentInChildren<Compensation>().positionPredictionAmount = 0f;
- projectile.GetComponentInChildren<Compensation>().velocityPrediction = 0f;
- projectile.transform.localScale *= 0f;
- Renderer[] componentsInChildren2 = projectile.GetComponentsInChildren<Renderer>();
- for (int l = 0; l < componentsInChildren2.Length; l++)
- {
- switch (l)
- {
- case 0:
- componentsInChildren2[l].enabled = false;
- break;
- case 1:
- componentsInChildren2[l].enabled = false;
- break;
- case 2:
- componentsInChildren2[l].enabled = false;
- break;
- default:
- componentsInChildren2[l].enabled = false;
- break;
- }
- }
- }
- if (parentUnit.Entity.Name == "Placeholder")
- {
- MeshRenderer[] componentsInChildren3 = projectile.GetComponentsInChildren<MeshRenderer>();
- for (int m = 0; m < componentsInChildren3.Length; m++)
- {
- componentsInChildren3[m].enabled = false;
- }
- projectile.AddComponent<FernSpawner>().unitsToSpawn = new List<UnitBlueprint>
- {
- UManager.dico["Zombie Slave"]
- }.ToArray();
- projectile.GetComponent<FernSpawner>().u_numOfObjects = 3;
- projectile.GetComponent<FernSpawner>().u_startDelay = 0.1f;
- projectile.GetComponent<FernSpawner>().u_cd = 0f;
- projectile.GetComponent<FernSpawner>().u_triggerType = FernSpawner.TriggerType.Still;
- projectile.GetComponent<FernSpawner>().objectsToSpawn = new List<GameObject>
- {
- database.Weapons[28].GetComponent<RangeWeapon>().objectToSpawn.GetComponentInChildren<ProjectileHit>().objectsToSpawn[0].objectToSpawn
- }.ToArray();
- projectile.GetComponent<FernSpawner>().o_numOfObjects = 1;
- projectile.GetComponent<FernSpawner>().o_startDelay = 0f;
- projectile.GetComponent<FernSpawner>().o_cd = 0f;
- projectile.GetComponent<FernSpawner>().o_triggerType = FernSpawner.TriggerType.Still;
- ObjectToSpawn objectToSpawn = new ObjectToSpawn();
- objectToSpawn.objectToSpawn = database.CombatMoves[10].GetComponent<SpawnObject>().objectToSpawn;
- projectile.GetComponentInChildren<ProjectileHit>().objectsToSpawn = new List<ObjectToSpawn>
- {
- objectToSpawn
- }.ToArray();
- }
- }
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement