public OutObject AddObject(OutObject oo) { oo.ScaleX = this.Scale; oo.ScaleY = this.Scale; this.objects.Add(oo); return(oo); }
public OutObject AddObject(string spriteId, int s, int t, int w, int h) { OutObject oo = new OutObject(spriteId, new IntRect(s, t, w, h)); oo.ScaleX = this.Scale; oo.ScaleY = this.Scale; this.objects.Add(oo); return(oo); }
public void SetAnimation(OutObject obj) { var sa = new SpriteAnimation(); foreach (var frame in this.frames) { sa.AppendSprite(frame.frame, frame.offset, frame.duration, frame.sfx); } obj.AddAnimator(sa); }
public void DeleteObject(OutObject obj) { obj.ToBeDeleted = true; this.objects.Remove(obj); }