My first animated knife

(I also think this is my first animated weapon in general)

I got the mesh from some guy who wanted me to make this knife.
Creating animations was quite fun, went better than I expected.
(although I had to do some hax with replacing Weld with Motor6D)
Scripting to play the right one, enable doing damage on time, … more fun.

It uses damage values from the first table on this page:
Knife (as sent to by Karambit for stats, like damage)
With “Back” being Torso when you’re standing behind your target.

Transitioning between swinging/stabbing once/several times sounds complex, but went very well.
I just preload all animations as a track and connect all KeyframeReached to a function.
When it reaches a keyframe “Done” it’ll set AttackType to 0, making the knife harmless.
The animations with a “Done” keyframe still have some time to finish.
(Retreating for Slash and holding the knife in Stab position for Stab)
By holding the knife in position after stabbing, you can stab several times smoothly.
TL;DR: Animations have a “Done” keyframe that says “from here, you may strike again”.
(Just explaining this because this caused me the most trouble, might be nice to know)

PRE-EDIT: deeeerp @#(&$#
Before pressing “Create Topic”, my customer replied…
Apparently I’m holding the Karambit the wrong way (gg)
(RIP my over extensive proudness, just regular proudness remains)

Seems really similar to the system I’m using for my dark souls game. It seems like your stabbing with the dull end of a karambit tho

I love how you show the user where they’re landing a hit on the humanoid, and the damage values.

FYI, the .Stopped() event of an AnimationTrack isn’t deprecated, and never was, even though the wiki marked it as such.

Yep I definitly have it holding the knife the wrong way, already fixed it.
Got a bayonet now too: https://www.youtube.com/watch?v=sIoSsYzzZMM
(2 knives down, one to go)

Eh that’s the Practice dummy I created, the knife just damages the Humanoid as it should.
The dummy colors its limbs on Touched and displays the damage on HealthChanged.

I actually use .Stopped:wait() in the Karambit’s code.
The KeyframeReached was because I had a keyframe “Done” at 0.3s while the animation is 0.5s long etc.
*(Also, the wiki doesn’t say it’s deprecated. I used the wiki’s API Dump anyway, wouldn’t have noticed much)

It used to, and there were several threads about it and a lot of confusion

Yeah that is not deprecated! Please use it :slight_smile:

I believe it was marked as deprecated incorrectly.