本文整理汇总了C#中EffectLayer类的典型用法代码示例。如果您正苦于以下问题:C# EffectLayer类的具体用法?C# EffectLayer怎么用?C# EffectLayer使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
EffectLayer类属于命名空间,在下文中一共展示了EffectLayer类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: EffectController
public EffectController()
: base(0x1B72)
{
Movable = false;
Visible = false;
m_TriggerType = EffectTriggerType.Sequenced;
m_EffectLayer = (EffectLayer)255;
}
示例2: BlessEffect
public BlessEffect( StatType stat, int sound, int eid, int speed, int duraction, int eff, EffectLayer layer )
{
m_Stat = stat;
m_Snd = sound;
m_EffIID = eid;
m_EffSpd = speed;
m_Dur = duraction;
m_Eff = eff;
m_ELayer = layer;
}
示例3: EffectNode
public EffectNode(int index, Transform clienttrans, bool sync, EffectLayer owner)
{
Index = index;
ClientTrans = clienttrans;
SyncClient = sync;
Owner = owner;
LowerLeftUV = Vector2.zero;
UVDimensions = Vector2.one;
Scale = Vector2.one;
RotateAngle = 0;
Color = Color.white;
}
示例4: SendTargetParticles
public static void SendTargetParticles( IEntity target, int itemID, int speed, int duration, int hue, int renderMode, int effect, EffectLayer layer, int unknown )
{
if ( target is Mobile )
((Mobile)target).ProcessDelta();
Map map = target.Map;
if ( map != null )
{
Packet particles = null, regular = null;
IPooledEnumerable eable = map.GetClientsInRange( target.Location );
foreach ( NetState state in eable )
{
state.Mobile.ProcessDelta();
if ( SendParticlesTo( state ) )
{
if ( particles == null )
particles = Packet.Acquire( new TargetParticleEffect( target, itemID, speed, duration, hue, renderMode, effect, (int)layer, unknown ) );
state.Send( particles );
}
else if ( itemID != 0 )
{
if ( regular == null )
regular = Packet.Acquire( new TargetEffect( target, itemID, speed, duration, hue, renderMode ) );
state.Send( regular );
}
}
Packet.Release( particles );
Packet.Release( regular );
eable.Free();
}
//SendPacket( target.Location, target.Map, new TargetParticleEffect( target, itemID, speed, duration, hue, renderMode, effect, (int)layer, unknown ) );
}
示例5: SendMovingParticles
public static void SendMovingParticles( IEntity from, IEntity to, int itemID, int speed, int duration, bool fixedDirection, bool explodes, int hue, int renderMode, int effect, int explodeEffect, int explodeSound, EffectLayer layer, int unknown )
{
if ( from is Mobile )
((Mobile)from).ProcessDelta();
if ( to is Mobile )
((Mobile)to).ProcessDelta();
Map map = from.Map;
if ( map != null )
{
Packet particles = null, regular = null;
IPooledEnumerable eable = map.GetClientsInRange( from.Location );
foreach ( NetState state in eable )
{
state.Mobile.ProcessDelta();
if ( SendParticlesTo( state ) )
{
if ( particles == null )
particles = Packet.Acquire( new MovingParticleEffect( from, to, itemID, speed, duration, fixedDirection, explodes, hue, renderMode, effect, explodeEffect, explodeSound, layer, unknown ) );
state.Send( particles );
}
else if ( itemID > 1 )
{
if ( regular == null )
regular = Packet.Acquire( new MovingEffect( from, to, itemID, speed, duration, fixedDirection, explodes, hue, renderMode ) );
state.Send( regular );
}
}
Packet.Release( particles );
Packet.Release( regular );
eable.Free();
}
//SendPacket( from.Location, from.Map, new MovingParticleEffect( from, to, itemID, speed, duration, fixedDirection, explodes, hue, renderMode, effect, explodeEffect, explodeSound, unknown ) );
}
示例6: Emitter
public Emitter(EffectLayer owner)
{
Layer = owner;
EmitLoop = Layer.EmitLoop;
LastClientPos = Layer.ClientTransform.position;
}
示例7: MovingParticles
public void MovingParticles( IEntity to, int itemID, int speed, int duration, bool fixedDirection, bool explodes, int hue, int renderMode, int effect, int explodeEffect, int explodeSound, EffectLayer layer, int unknown )
{
Effects.SendMovingParticles( this, to, itemID, speed, duration, fixedDirection, explodes, hue, renderMode, effect, explodeEffect, explodeSound, layer, unknown );
}
示例8: FixedParticles
public void FixedParticles( int itemID, int speed, int duration, int effect, int hue, int renderMode, EffectLayer layer )
{
Effects.SendTargetParticles( this, itemID, speed, duration, hue, renderMode, effect, layer, 0 );
}
示例9: UVConfig
protected void UVConfig(EffectLayer ctarget)
{
DisplayUVConfig = EditorGUILayout.Foldout(DisplayUVConfig, "UV Configuration");
if (DisplayUVConfig)
{
EditorGUILayout.BeginVertical();
ctarget.UVType = EditorGUILayout.Popup(ctarget.UVType, UVTypes);
if (ctarget.UVType == 0)
{
ctarget.OriLowerLeftUV = EditorGUILayout.Vector2Field("original lower left uv:", ctarget.OriLowerLeftUV);
ctarget.OriUVDimensions = EditorGUILayout.Vector2Field("original uv dimensions:", ctarget.OriUVDimensions);
ctarget.UVAffectorEnable = false;
}
else if (ctarget.UVType == 1)
{
ctarget.Cols = EditorGUILayout.IntField("x tile:", ctarget.Cols);
ctarget.Rows = EditorGUILayout.IntField("y tile:", ctarget.Rows);
ctarget.UVTime = EditorGUILayout.FloatField("time(-1 means node life):", ctarget.UVTime);
ctarget.LoopCircles = EditorGUILayout.IntField("loop(-1 means infinite):", ctarget.LoopCircles);
ctarget.UVAffectorEnable = true;
}
else
{// support in the future.
ctarget.EanPath = EditorGUILayout.TextField("file name:", ctarget.EanPath);
ctarget.EanIndex = EditorGUILayout.IntField("animation index", ctarget.EanIndex);
ctarget.UVTime = EditorGUILayout.FloatField("animation time:", ctarget.UVTime);
ctarget.LoopCircles = EditorGUILayout.IntField("loop(-1 means infinite):", ctarget.LoopCircles);
ctarget.UVAffectorEnable = true;
}
EditorGUILayout.EndVertical();
}
}
示例10: AttractionAffectorConfig
protected void AttractionAffectorConfig(EffectLayer ctarget)
{
DisplayAttractionAffectorConfig = EditorGUILayout.Foldout(DisplayAttractionAffectorConfig, "Attraction Affector Configuration");
if (DisplayAttractionAffectorConfig)
{
EditorGUILayout.BeginVertical();
ctarget.UseAttractCurve = EditorGUILayout.Toggle("use curve?", ctarget.UseAttractCurve);
if (ctarget.UseAttractCurve)
{
ctarget.AttractionCurve = EditorGUILayout.CurveField("curve:", ctarget.AttractionCurve);
ctarget.AttractionPosition = EditorGUILayout.Vector3Field("attraction position:", ctarget.AttractionPosition);
}
else
{
ctarget.AttractMag = EditorGUILayout.FloatField("magnitude:", ctarget.AttractMag);
ctarget.AttractionPosition = EditorGUILayout.Vector3Field("attraction position:", ctarget.AttractionPosition);
}
EditorGUILayout.EndVertical();
}
}
示例11: AffectorConfig
protected void AffectorConfig(EffectLayer ctarget)
{
DisplayAffectorConfig = EditorGUILayout.Foldout(DisplayAffectorConfig, "Affector Configuration");
DisplayLinearForceAffectorConfig = ctarget.LinearForceAffectorEnable;
DisplayJetAffectorConfig = ctarget.JetAffectorEnable;
DisplayVortexAffectorConfig = ctarget.VortexAffectorEnable;
DisplayAttractionAffectorConfig = ctarget.AttractionAffectorEnable;
if (DisplayAffectorConfig)
{
EditorGUILayout.BeginVertical();
EditorGUILayout.PrefixLabel("affector types:");
AffectorIndex = EditorGUILayout.Popup(AffectorIndex, AffectorTypes);
EditorGUILayout.BeginHorizontal();
if (GUILayout.Button("Add Affector"))
{
if (AffectorIndex == 0)
DisplayLinearForceAffectorConfig = true;
else if (AffectorIndex == 1)
DisplayJetAffectorConfig = true;
else if (AffectorIndex == 2)
DisplayVortexAffectorConfig = true;
else if (AffectorIndex == 3)
DisplayAttractionAffectorConfig = true;
}
if (GUILayout.Button("Delete Affector"))
{
if (AffectorIndex == 0)
DisplayLinearForceAffectorConfig = false;
else if (AffectorIndex == 1)
DisplayJetAffectorConfig = false;
else if (AffectorIndex == 2)
DisplayVortexAffectorConfig = false;
else if (AffectorIndex == 3)
DisplayAttractionAffectorConfig = false;
}
EditorGUILayout.EndHorizontal();
if (DisplayLinearForceAffectorConfig)
LinearForceAffectorConfig(ctarget);
if (DisplayJetAffectorConfig)
JetAffectorConfig(ctarget);
if (DisplayVortexAffectorConfig)
VortexAffectorConfig(ctarget);
if (DisplayAttractionAffectorConfig)
AttractionAffectorConfig(ctarget);
ctarget.LinearForceAffectorEnable = DisplayLinearForceAffectorConfig;
ctarget.JetAffectorEnable = DisplayJetAffectorConfig;
ctarget.VortexAffectorEnable = DisplayVortexAffectorConfig;
ctarget.AttractionAffectorEnable = DisplayAttractionAffectorConfig;
EditorGUILayout.EndVertical();
}
}
示例12: DoPatch440
void DoPatch440(EffectLayer layer)
{
if (layer.IsRandomStartColor)
{
XEditorTool.PatchColorGradient(layer.RandomColorParam, layer.RandomColorGradient);
}
if (layer.ColorChangeType == COLOR_CHANGE_TYPE.Gradient)
{
XEditorTool.PatchColorGradient(layer.ColorParam, layer.ColorGradient);
}
}
示例13: DoPatch415
void DoPatch415(EffectLayer layer)
{
if (layer.EmitLoop < 0)
{
layer.EmitDuration = -1f;
}
layer.EmitLoop = 1;
}
示例14: DoPatch
public static void DoPatch(EffectLayer layer)
{
Debug.Log("patching for effect layer:" + GetPath(layer.transform));
if (layer.IsRandomStartColor)
{
XEditorTool.PatchColorGradient(layer.RandomColorParam, layer.RandomColorGradient);
}
if (layer.ColorChangeType == COLOR_CHANGE_TYPE.Gradient)
{
XEditorTool.PatchColorGradient(layer.ColorParam, layer.ColorGradient);
}
}
示例15: DoPatch
public static void DoPatch(EffectLayer layer)
{
Debug.Log("patching for effect layer:" + GetPath(layer.transform));
if (layer.ColorChangeType != COLOR_CHANGE_TYPE.Constant)
{
layer.Color1 = Color.white;
}
if (layer.EmitType == 4 && layer.LineStartObj == null)
{
layer.LineStartObj = layer.transform;
}
if (!layer.UseSameScaleCurve)
{
layer.MaxScaleValueY = layer.MaxScaleCalue;
}
if (layer.RenderType == 2 || layer.RenderType == 3)
{
float y = layer.OriTopLeftUV.y - layer.OriUVDimensions.y;
if (y >= 0f)
layer.OriTopLeftUV.y = layer.OriTopLeftUV.y - layer.OriUVDimensions.y;
}
}