Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

NPC Death Animation


DarkDino
 Share

Recommended Posts

I don't think there is a feature for that. But it would be fairly simple.

Make a scroll bar and label in NPC for the death animation.

Add a death animation variable with type as long

In the sub PlayerAttackNPc there should be a check that checkes whether the damge done is greater than or equal to the npcs current vital (this means death is initiated for the npc)

In the true part of the check call SendAnimation with the following parameters the mapnum, the animation number, and the x and y coords to render the animation.

If you need further help don't refrain from posting. Also try doing this yourself rather than asking for the code.
Link to comment
Share on other sites

> I understand, but cant use SendAnimation? Call SendAnimation to position of NPC?

You didn't read the entire topic did you? A SendAnimation is done. Which animation you send and how you do it is up to you. (You can use a common anim or you can make it unique by doing it how I explained.)
Link to comment
Share on other sites

Abhis version = The NPC get the animation in his spritesheet like on my game

Your version = create an normal animation and play it on death

So i would recommend do Abhis version its way better and looks better else just add the sendanimation string at the point where the npc get removed from the map with the same location
Link to comment
Share on other sites

> What EO client are you using?

**[](http://www.touchofdeathforums.com/community/index.php?/topic/113011-dont-know-the-answer-dont-reply/)[Don't know the answer? Don't reply!](http://www.touchofdeathforums.com/community/index.php?/topic/113011-dont-know-the-answer-dont-reply/)**

> So i would recommend do Abhis version its way better and looks better else just add the sendanimation string at the point where the npc get removed from the map with the same location

![-_-](http://www.touchofdeathforums.com/community/public/style_emoticons/<#EMO_DIR#>/sleep.png) Thats basically what I did.
Link to comment
Share on other sites

Abh, I asked what EO system he was using so I could download it and see If I could help him for his exact client, this way there would be no code erros, because as we both know that clients and servers from other versions differ in code… I have seen that link do my a favor, ask next time before telling someone they do not know what they are talking about. ![;)](http://www.touchofdeathforums.com/community/public/style_emoticons/<#EMO_DIR#>/wink.png) Thanks mate.

(FYI: This is not meant as sarcasm so I do hope you do not take it that way.)
Link to comment
Share on other sites

> Abh, I asked what EO system he was using so I could download it and see If I could help him for his exact client, this way there would be no code erros, because as we both know that clients and servers from other versions differ in code… I have seen that link do my a favor, ask next time before telling someone they do not know what they are talking about. ![;)](http://www.touchofdeathforums.com/community/public/style_emoticons/<#EMO_DIR#>/wink.png) Thanks mate.
>
> (FYI: This is not meant as sarcasm so I do hope you do not take it that way.)

First of my name is Abhi. And secondly you asked the question twice. Even after he answered.
Link to comment
Share on other sites

Dark dino, open up your server vbp, then open modplayer.bas Find your OnDeath Sub and right after

Call SetPlayerVital(index, Vitals.HP, 0)

Add

Call SendAnimation(Player(index).Map, 1, Player(index).x, Player(index).y)

Change the number "1" to the animation of the dead body. That is how simple sending an animation after death is.

Don't get so upset, next time, ask me to say that instead of correcting me. If you do not like that then I will gladly call you Abhi. Second, yes I did, I did not realize I did,
Link to comment
Share on other sites

Psl i understand but, this is for Players D:!. I like to NPC Death, when you kill NPC a Animation Appear.

No matter the same animation in all NPC.

I make this

SendAnimation GetPlayerMap(attacker), MapNpc(mapnum).NPC(mapNpcNum).x, MapNpc(mapnum).NPC(mapNpcNum).y

above this ' send death to the map

but error, please D: help in this!.
Link to comment
Share on other sites

My error is when attack a NPC: "The argument is not optional"

"Call SendAnimation"

D: also where would the number of animation in this code?

Call SendAnimation(Player(attacker).Map, MapNpc(mapNum).Npc(mapNpcNum).x, MapNpc(mapNum).Npc(mapNpcNum).y) ¿?
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...