public SpriterGuiButton( ViewportAdapter viewportAdapter, String buttonName, String spritePartCompleteFilename, CustomSpriterAnimator animator, CustomSpriterAnimator referenceAnimator, string animationName = null, string clickAnimationName = null, string inputDownSoundName = null, string inputUpSoundName = null, bool stopAnimationWhenClicked = false, string timelineName = null) : base(viewportAdapter, buttonName) { SubstituteEntity = new SpriterSubstituteEntity(Path.GetFileName(spritePartCompleteFilename), referenceAnimator, animator, timelineName); _animationName = animationName; _clickAnimationName = clickAnimationName; _inputDownSoundName = inputDownSoundName; _inputUpSoundName = inputUpSoundName; _stopAnimationWhenClicked = stopAnimationWhenClicked; if (_animationName != null) { SubstituteEntity.SubstituteAnimator.Play(_animationName); } Reset(); }
public SpriterGuiButton( ViewportAdapter viewportAdapter, String buttonName, String spritePartCompleteFilename, CustomSpriterAnimator animator, CustomSpriterAnimator referenceAnimator) : base(viewportAdapter, buttonName) { SubstituteEntity = new SpriterSubstituteEntity(Path.GetFileName(spritePartCompleteFilename), referenceAnimator, animator); }