Jump to content
  • 0

SpawnMob method Z Coord not see


kaJaMrSimple

Question

I specify the z coordinate as 2, it reacts as if the coordinate is random.

my code;

 

    CHARACTER_MANAGER::instance().SpawnMob(20387, GetMapIndex(), 135 * 100 + 32000, 104  * 100 + 0, 2, false, -1, true);

 

I want to set the direction of mob.

 

What should I do?

Link to post

5 answers to this question

Recommended Posts

  • 0
Posted (edited)
7 minutes ago, ondry said:

çalışmaz .. Yayınlanan ymir dosyalarında Z koordinatı dikkate alınmaz ..

is there a different way?

Edited by kaJaMrSimple
Link to post
  • 0
  • Developer
Posted (edited)
1 hour ago, kaJaMrSimple said:

I specify the z coordinate as 2, it reacts as if the coordinate is random.

 

I want to set the direction of mob.

 

What should I do?

Z coordinate is not the direction the mob is facing..

 

either use

d.spawn_mob_ac_dir

(vnum, x, y, dir [0..359])

(if you input -1 instead of a number between 0 and 359, it will choose a random dir between 0 and 359)

or

d.spawn_mob_dir

(vnum, x, y, dir [1..8] {(direction - 1) * 45})

(if you input 0 instead of a number between 1 and 9, it will choose a random dir between 1 and 8 )

Edited by Syreldar

👑 Premium International Lua Developer 👑

 My service topic: https://bit.ly/2UPly54

 

Ignorant people have the obligation to compensate their ignorance by paying whoever helps them.

Syreldar

Link to post
  • 0
4 minutes ago, Syreldar said:

Z coordinate is not the direction the mob is facing..

 

either use

d.spawn_mob_ac_dir

(vnum, x, y, dir [0..359])

or

d.spawn_mob_dir

(vnum, x, y, dir [0..9] {(direction - 1) * 45})

The system I made is completely source-based. I don't want to use quest.

Link to post
  • 0
  • Developer
Just now, kaJaMrSimple said:

The system I made is completely source-based. I don't want to use quest.

Use your brain based on what I told you, then. duh. Said functions are inside the sources, look them up.

👑 Premium International Lua Developer 👑

 My service topic: https://bit.ly/2UPly54

 

Ignorant people have the obligation to compensate their ignorance by paying whoever helps them.

Syreldar

Link to post

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

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.



×
×
  • Create New...

Important Information

Terms of Use / Privacy Policy / Guidelines / We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.