Jump to content
  • 0

Question

I'm trying to return the player matak using getunitdata, but it's giving error .. where am I going wrong?

 

.@mymagicatak = getunitdata(getcharid(CHAR_ID_ACCOUNT), UDT_MATKMAX);

 

but I have an error [Error]: buildin_getunitdata: Unknown object!

 

I tried to get gid with CHAR_ID_CHAR but it didn't work either

Share this post


Link to post
Share on other sites

2 answers to this question

Recommended Posts

  • 1
9 hours ago, Tio Akima said:

I'm trying to return the player matak using getunitdata, but it's giving error .. where am I going wrong?

 

.@mymagicatak = getunitdata(getcharid(CHAR_ID_ACCOUNT), UDT_MATKMAX);

 

but I have an error [Error]: buildin_getunitdata: Unknown object!

 

I tried to get gid with CHAR_ID_CHAR but it didn't work either

The actual 'getunitdata' has no support for player units.

This is why you receive this message error.

If you want to get values from player units, you'll need to make a source modification.

I made one, you can test if you want.

 

getunitdata_pc_type.diff

Edited by Cretino

Share this post


Link to post
Share on other sites
  • 0
2 hours ago, Cretino said:

The actual 'getunitdata' has no support for player units.

This is why you receive this message error.

If you want to get values from player units, you'll need to make a source modification.

I made one, you can test if you want.

 

getunitdata_pc_type.diff 4.08 kB · 1 download

oh ok... nice... thanks o/


@EDIT:
 

@Cretino if I'm not mistaken there is no return from the basic attack on the list (batak)

UDT_ATKMIN and UDT_ATKMAX are for weapons
e UDT_MATKMIN and UDT_MATKMAX for magic attack LOL

 

@EDIT2:

I looked at source and added the basic attack manually .. thanks!
Solved


script_pushint(st, sd->battle_status.batk); o/

 

 

Edited by Tio Akima

Share this post


Link to post
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.   Restore formatting

  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.

Loading...

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.