Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
C# Animation Error
#1
I'm testing out Tilengine with the CS binding and when making a simple character with an animation I keep getting an Invalid SequencePack error. I will admit that I'm using a 3 year old video as a tutorial of sorts so it's possible something changed since then and I just don't know it. I'll post my code below:

Code:
static int Main(string[] args) {
engine = Engine.Init(512, 288, 11, 30, 30);
engine.SetBackgroundColor(new Color(0x00, 0xCC, 0xCC));
engine.LoadPath = "assets/Sprites/Terri";

Spriteset ss = Spriteset.FromFile("TerriIdle.png");
SequencePack sp = SequencePack.FromFile("TerriIdle.sqx");
Sequence idle = sp.Find("idle");

Sprite sprite = new Sprite();
sprite.Setup(ss, TileFlags.None);

sprite.SetPosition(160, 120);

Animation anim = new Animation();
anim.SetSpriteAnimation(0, idle, 0);

int frame = 0;
Window window = Window.Create(null, WindowFlags.Vsync);
while (window.Process()) {
window.DrawFrame(frame);
frame += 1;
}
return 0;
}
Reply


Messages In This Thread
C# Animation Error - by Midnight Syntax - 03-23-2021, 02:55 PM
RE: C# Animation Error - by megamarc - 03-24-2021, 12:28 AM
RE: C# Animation Error - by Midnight Syntax - 03-24-2021, 03:54 AM
RE: C# Animation Error - by Midnight Syntax - 03-24-2021, 03:55 AM
RE: C# Animation Error - by megamarc - 03-24-2021, 08:18 PM
RE: C# Animation Error - by Midnight Syntax - 03-25-2021, 03:29 AM
RE: C# Animation Error - by megamarc - 03-25-2021, 06:27 AM
RE: C# Animation Error - by Midnight Syntax - 03-25-2021, 07:06 AM
RE: C# Animation Error - by megamarc - 03-25-2021, 08:16 AM
RE: C# Animation Error - by Midnight Syntax - 03-25-2021, 09:07 AM
RE: C# Animation Error - by megamarc - 03-25-2021, 09:35 AM

Forum Jump:


Users browsing this thread: 1 Guest(s)