Jump to content
  • 0

use skill in target [status.c]


Tio Akima

Question


  • Group:  Members
  • Topic Count:  94
  • Topics Per Day:  0.02
  • Content Count:  191
  • Reputation:   138
  • Joined:  09/24/12
  • Last Seen:  

Hi guys

take this doubt from me
I'm trying to call a skill through status.c
But I do not know which function to use to use a skill on the target.
It may be any skill, but I'm testing the NPC_SELFDESTRUCTION

What function can I use to call a skill on the target?

 

@EDIT I tried:
             unit->skilluse_id(bl, bl, NPC_SELFDESTRUCTION,1 ); 
             but it did not work
 

Edited by Tio Akima
Link to comment
Share on other sites

9 answers to this question

Recommended Posts

  • 0

  • Group:  Members
  • Topic Count:  26
  • Topics Per Day:  0.01
  • Content Count:  350
  • Reputation:   43
  • Joined:  09/07/12
  • Last Seen:  

I don't really remember things clearly, Try removing the unit->

You don't need that, also make sure that bl is the target,

And is that the right function for using skill?

Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  94
  • Topics Per Day:  0.02
  • Content Count:  191
  • Reputation:   138
  • Joined:  09/24/12
  • Last Seen:  

9 minutes ago, benching said:

I don't really remember things clearly, Try removing the unit->

You don't need that, also make sure that bl is the target,

And is that the right function for using skill?

I thought I needed to use unit->
for the path of the function to be correct.

Yes, the target is correct, including, I change the speed of the target without problems.

Yes, it is in the correct function, I made a debug by putting a printf () and issuing a message in the console to know if it was accessing.



@EDIT yes, you must use unit-> for the path to be correct.

Edited by Tio Akima
Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  26
  • Topics Per Day:  0.01
  • Content Count:  350
  • Reputation:   43
  • Joined:  09/07/12
  • Last Seen:  

In which function in status.c are you calling that line?

A small snippet would be good

Edited by benching
Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  94
  • Topics Per Day:  0.02
  • Content Count:  191
  • Reputation:   138
  • Joined:  09/24/12
  • Last Seen:  

4 minutes ago, benching said:

In which function in status.c are you calling that line?

A small snippet would be good

I'm calling inside the case of SC_RUN
in the function status_change_end  (in the status.c file)

when this status in target ends, I want to call a skill (on the same target).
But I do not know the function to use a skill

this is the doubt
It seems very simple, but I do not know hahahaha

Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  26
  • Topics Per Day:  0.01
  • Content Count:  350
  • Reputation:   43
  • Joined:  09/07/12
  • Last Seen:  

14 minutes ago, Tio Akima said:

I'm calling inside the case of SC_RUN
in the function status_change_end  (in the status.c file)

when this status in target ends, I want to call a skill (on the same target).
But I do not know the function to use a skill

this is the doubt
It seems very simple, but I do not know hahahaha

Let me check...

Device too slow for me to check on GitHub,

Edited by benching
Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  26
  • Topics Per Day:  0.01
  • Content Count:  350
  • Reputation:   43
  • Joined:  09/07/12
  • Last Seen:  

Check skill_castend_damage_id and skill_castend_nodamage_id

Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  94
  • Topics Per Day:  0.02
  • Content Count:  191
  • Reputation:   138
  • Joined:  09/24/12
  • Last Seen:  

1 hour ago, benching said:

Check skill_castend_damage_id and skill_castend_nodamage_id

Yes, this is the correct function
nodamage_id

The skill is being called now, but not on the target I want.
She is being called in the player
Must be on target. (mob) But it's already a big evolution.

From what I can see, the first two arguments of the function define the target :D 

Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  26
  • Topics Per Day:  0.01
  • Content Count:  350
  • Reputation:   43
  • Joined:  09/07/12
  • Last Seen:  

10 hours ago, Tio Akima said:

Yes, this is the correct function
nodamage_id

The skill is being called now, but not on the target I want.
She is being called in the player
Must be on target. (mob) But it's already a big evolution.

From what I can see, the first two arguments of the function define the target :D 

The first arg is the second of the skill or the caster,

The 2nd arg is the target,

I'm not sure how to call it on mob that it bump into.

Edited by benching
Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  94
  • Topics Per Day:  0.02
  • Content Count:  191
  • Reputation:   138
  • Joined:  09/24/12
  • Last Seen:  

16 hours ago, benching said:

The first arg is the second of the skill or the caster,

The 2nd arg is the target,

I'm not sure how to call it on mob that it bump into.

I even managed to call, but I'm not hitting the target. :(

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...