Nifflas' Support Forum

Level Editing Support => Knytt Stories Level Editing Support => Knytt Stories - Custom Content => Topic started by: Vinterrun on January 14, 2011, 14:25:58

Title: How to create a >moving< CO
Post by: Vinterrun on January 14, 2011, 14:25:58
I tried to figure it out by myseld bt reading the co manual but I don't get it. Sorry ._.

I created a little fellow who's supposed to run from one edge to the other one. How do I manage that?
Title: Re: How to create a >moving< CO
Post by: Firecat on January 14, 2011, 15:39:05
what exactly its your little fellow, a GIF animation, a spritesheet or single images? can i see it?
Title: Re: How to create a >moving< CO
Post by: Vinterrun on January 14, 2011, 15:53:29
It's a Knyttlike thing as spritesheed and I just created one of the images cause I wasn't sure how to continue to let it move. I practised with other stuff but without success.
Title: Re: How to create a >moving< CO
Post by: Miss Paula on January 14, 2011, 17:29:12
you can have critters that move away from one spot (which I suppose you mean).you "simply" have to use their action radius as the frame width and make a whole lot of frames. like, you want something to walk 30 pixels, then each frame has to be that wide, even though your character starts at the left edge. and then it has maybe three frames of animation for each step it takes, and those you repeat until it has reached the other side. it's hard to explain; I think Elder made a proof-of-concept animation of an old man that walks from one side of the screen to the other.
either way, it results in a very big CO-file and takes quite some time to make, I think. and I bet someone else can explain better than me. X)
Title: Re: How to create a >moving< CO
Post by: Vinterrun on January 15, 2011, 00:56:22
Well, you've explained enough to make it unattractive =D
Title: Re: How to create a >moving< CO
Post by: egomassive on January 15, 2011, 03:12:31
Sounds like you're convinced not to do it, but here's an example. This character stands up and runs off screen. I've added grid lines to the sprite sheet to make it easier to understand. This guy only has 2 images for running, but they're repeated over and over as he moves across the frame. Here the frame is 48 pixels wide. To run across the whole screen the frames would need to be 600 pixels wide, and there'd need to be about 12 times as many as I have here.

CO's are really best for mostly stationary objects, like a TV or a Cow.

Code: [Select]
[Custom Object 28]
Image=SkullRun.png
Tile Height=24
Tile Width=48
Init AnimTo=19
Init AnimRepeat=1
Init AnimSpeed=400
Offset X=12
Title: Re: How to create a >moving< CO
Post by: Vinterrun on January 15, 2011, 06:25:13
Do you intend that cows aren't able to move?  :shifty:


Thank you a lot for the explanation. I think I will work with non moving CO's now ;
Title: Re: How to create a >moving< CO
Post by: Miss Paula on January 15, 2011, 15:16:59
not completely on-topic, but that animation is cool and cute, egomassive. C)
Title: Re: How to create a >moving< CO
Post by: Vinterrun on January 15, 2011, 17:14:52
I agree