Sprite Questions

Feel free to discuss anything related to the creation of new KotC 2 adventures using the toolset.

Sprite Questions

Postby claiminglight » Sat Jul 04, 2020 7:21 pm

I'd love to start working on some sprites. If anybody has or will mess around with these, I wonder about a few things:

Any plans to have idle animations? Or attack animations?
Are five frame walk animations hard-coded? Or does it just cycle whatever it finds?

These would all be considerations for later, ofc.
Stone Giant (CR 8)
Knights of the Chalice
Posts: 27
Joined: Thu Nov 01, 2012 6:20 am

Sprite Questions


Re: Sprite Questions

Postby Enrahim » Sun Jul 05, 2020 12:30 pm

Qualified guess from only looking in the Graphics/Sprites folder is that it is based on 3 frame animations for each of the 4 directions, where the state is identified by the suffix. I guess you could play with what happens if you try to add more than 3 frames. My guess is that it won't be picked up, and that due to the alignment with moving between squares it would be tricky to add. However I might be wrong. As 2 digits is reserved in the sprite name, I could imagine it might be a better use of that range to use some of it for idle and/or attack animations. I imagine adding that capability wouldn't actually be that hard Pierre?
Code: Select all
 ( idlesprite = !idlesprites[creature] || turn % (idlesprites[creature].length +1) == 0 ? sprites[creature][0][direction] : idlesprites[creature][(turn % (idlesprites[creature].length +1)) -1][direction] )

Something like above for instance? (Permission granted to copy - public domain ;P )
Lizardman (CR 1)
Posts: 4
Joined: Sun Jul 05, 2020 12:02 pm

Re: Sprite Questions

Postby claiminglight » Thu Jul 09, 2020 2:23 am

^ Oops, yeah I meant 3 frame.

Though basic sprite support is a fantastic step forward, I feel that doubling down on this feature is going to be key to making KOTC2 stand the test of time. Animation brings characters to life and characters breath life into games that would otherwise suffer from old age. Further- when this game eventually goes onto Steam, the artwork is what will sell it: a sad but unavoidable reality when dealing with the median gamer.

My basic wishlist would include support for:
• A looping idle combat animation
• A looping idle non-combat animation
• An attack animation
• A spellcasting animation (a catch all, like the character holding their hands up)

And if I really was really going to overask:
• A Wounded flag for near-death characters that would allow a swap of the idle animations.
• A Dodge animation for attacks that miss your character, or successful reflex saves.
• A Resist animation for successful Fort and Will saves.
• Status-based idle animations for things like nausea, blindness and the rest. This feature doubles as UX, providing information to the player without breaking immersion with text and/or infographic boxes.
• Weapon state awareness that would allow interlacing of character sprites with floating equipment sprites-- so your character's completed animations would reflect their held equipment.
• Armor state awareness for the same.
• Weapon Handedness awareness that allows for swapping animations when using two-weapon or two-handed styles, or bows, crossbows or slings.

Though I don't dare to dream that *all* of these would be implemented, it's worth noting that, if they were, creators should be allowed to ignore all or near-all of these features, allowing them to devolve downward in a cascading style. So, if the creator doesn't add an idle combat animation to a sprite pack it might devolve downward to merely walking, or further downward to merely standing. If there is no attack animation, it might just default to the bump style.
Stone Giant (CR 8)
Knights of the Chalice
Posts: 27
Joined: Thu Nov 01, 2012 6:20 am

Re: Sprite Questions

Postby bluehinter » Thu Jul 09, 2020 3:59 am

I'm working on my own tokens (which are just images from movies so they could never be used commercially) and did a quick animation test with a pallet-shifted Mantis for Sprites.

Using the same naming convention I was able to create a green Mantis that had the exact same 3-step L R B T animations, and the game was smart enough to accept them automatically without any alteration to the game's coding on my part.


This means it's comparatively easy to add new player character content to the game, however, adding new types of animation would definitely require support from Pierre, and I believe it would be an all or nothing approach. To add idle or attack animations to one sprite, you'd have to add them to all sprites, which would certainly require a lot of work and backtracking.

If Pierre does implement it, so as not to break other peoples modules developed before the implementation, he'd probably have to tweak it so that if idle or attacking it *looks* for an attack animation frame set, but if it doesn't find it, it defaults to the regular walking animation. I don't actually know if it's possible to do this. My extremely limited experience with XML comes from modding another game, Dungeons of Dreadmor, which had very similar animation routines, but while it was easy to tell the game to go to X file path and play frames 1-4 with X ms delay between them. Missing even one frame of animation (or more annoyingly, capitalization errors, since XML is case sensitive) would cause the game to instantly crash whenever that animation loop was played.
User avatar
Chimera (CR 7)
Posts: 24
Joined: Thu Jul 02, 2020 8:34 pm
Location: Sacramento

Re: Sprite Questions

Postby claiminglight » Thu Jul 09, 2020 2:56 pm

Absolutely it'd be an all or nothing sort of thing! But as they were sort of added last minute during the campaign, I figure now is the time to put those ideas in the ether.

BTW I figured it's accept that stuff from the naming convention. Any chance you've tried adding a Mantis ___04 to any of those? Just to see if it collects all the numbered images and loops them until n? I haven't had a chance to mess with it lately.
Stone Giant (CR 8)
Knights of the Chalice
Posts: 27
Joined: Thu Nov 01, 2012 6:20 am

Return to KotC 2 Forum for Adventure-Module Creation

Who is online

Users browsing this forum: No registered users and 1 guest