You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
65 lines
2.7 KiB
C#
65 lines
2.7 KiB
C#
//------------------------------------------------------------------------------
|
|
// <auto-generated>
|
|
// This code was generated by Entitas.CodeGeneration.Plugins.ComponentEntityApiGenerator.
|
|
//
|
|
// Changes to this file may cause incorrect behavior and will be lost if
|
|
// the code is regenerated.
|
|
// </auto-generated>
|
|
//------------------------------------------------------------------------------
|
|
public partial class GameEntity {
|
|
|
|
public TimelineComponent timeline { get { return (TimelineComponent)GetComponent(GameComponentsLookup.Timeline); } }
|
|
public bool hasTimeline { get { return HasComponent(GameComponentsLookup.Timeline); } }
|
|
|
|
public void AddTimeline(Game.TimelineObject newTimeline, bool newIsRunning, float newTimePast, double newTimeMax, bool newIsPause) {
|
|
var index = GameComponentsLookup.Timeline;
|
|
var component = (TimelineComponent)CreateComponent(index, typeof(TimelineComponent));
|
|
component.Timeline = newTimeline;
|
|
component.IsRunning = newIsRunning;
|
|
component.TimePast = newTimePast;
|
|
component.TimeMax = newTimeMax;
|
|
component.IsPause = newIsPause;
|
|
AddComponent(index, component);
|
|
}
|
|
|
|
public void ReplaceTimeline(Game.TimelineObject newTimeline, bool newIsRunning, float newTimePast, double newTimeMax, bool newIsPause) {
|
|
var index = GameComponentsLookup.Timeline;
|
|
var component = (TimelineComponent)CreateComponent(index, typeof(TimelineComponent));
|
|
component.Timeline = newTimeline;
|
|
component.IsRunning = newIsRunning;
|
|
component.TimePast = newTimePast;
|
|
component.TimeMax = newTimeMax;
|
|
component.IsPause = newIsPause;
|
|
ReplaceComponent(index, component);
|
|
}
|
|
|
|
public void RemoveTimeline() {
|
|
RemoveComponent(GameComponentsLookup.Timeline);
|
|
}
|
|
}
|
|
|
|
//------------------------------------------------------------------------------
|
|
// <auto-generated>
|
|
// This code was generated by Entitas.CodeGeneration.Plugins.ComponentMatcherApiGenerator.
|
|
//
|
|
// Changes to this file may cause incorrect behavior and will be lost if
|
|
// the code is regenerated.
|
|
// </auto-generated>
|
|
//------------------------------------------------------------------------------
|
|
public sealed partial class GameMatcher {
|
|
|
|
static Entitas.IMatcher<GameEntity> _matcherTimeline;
|
|
|
|
public static Entitas.IMatcher<GameEntity> Timeline {
|
|
get {
|
|
if (_matcherTimeline == null) {
|
|
var matcher = (Entitas.Matcher<GameEntity>)Entitas.Matcher<GameEntity>.AllOf(GameComponentsLookup.Timeline);
|
|
matcher.componentNames = GameComponentsLookup.componentNames;
|
|
_matcherTimeline = matcher;
|
|
}
|
|
|
|
return _matcherTimeline;
|
|
}
|
|
}
|
|
}
|