本文整理汇总了C#中Effect.GetEffectType方法的典型用法代码示例。如果您正苦于以下问题:C# Effect.GetEffectType方法的具体用法?C# Effect.GetEffectType怎么用?C# Effect.GetEffectType使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Effect
的用法示例。
在下文中一共展示了Effect.GetEffectType方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: Zone
public Zone(Effect eff, Vector2 pos, int w, int l, bool t, bool rz)
{
width = w;
length = l;
effect = eff;
pastState = t;
position = pos;
reverseZone = rz;
GameObject zonePrefab = PrefabFactory.GetZonePrefab();
GameManager.InstantiateModel(zonePrefab, new Vector3(pos.x, 0, pos.y));
zoneObj = GameObject.Find("ZonePrefab(Clone)");
zoneObj.name = "Zone of Effect";
if (reverseZone){
zoneObj.transform.Rotate(0,180,0);
}
if (eff.GetEffectType() == Effect.EffectType.Fire){
// Change lighting to Red
GameObject effectLight = zoneObj.transform.Find("EffectLight").gameObject;
effectLight.light.color = ColorFactory.GetLightRed();
// Remove Snow Particle Effect
GameObject snowEffect = zoneObj.transform.Find("SnowEffect").gameObject;
GameManager.DestroyObject(snowEffect);
}
bar1 = zoneObj.transform.Find("CircleBar1").gameObject;
bar2 = zoneObj.transform.Find("CircleBar2").gameObject;
bar3 = zoneObj.transform.Find("CircleBar3").gameObject;
circle = zoneObj.transform.Find("CircleOut").gameObject;
}