Jump to content
  • 0

Mob use skill, simply not showing up


Question

Posted

Hello peoples,

I'm stucked on this case for 3h in a row now...I've ran out of ideas, so if anyone got one...I took it!

I'm currently working on a script that pops a monster, and I want this monster to pop a skill. But no matter what, it doesn't work...

Here's the case I've tried:

monster .wbMap$[.@spawnRand],123,150,.wBossName$[.lastRandId],.wBossIds[.lastRandId],1,strnpcinfo(3) + "::OnWorldBossDied",2; 
set .wBossId, $@mobId[0];
debugmes "pop skill " + .wBossId + " " + unitexists(.wBossId);

unitskilluseid .wBossId, WZ_STORMGUST, 5; //or with skill id

getunitdata(.wBossId, .@worldBossData);
areamobuseskill $lastPopMap$, .@worldBossData[UMOB_X], .@worldBossData[UMOB_Y], 50, .wBossIds[.lastRandId], 653, 10, 3000,1,e_gg,3; //or with NPC_EARTHQUAKE

It's a bit modified to make it easiest to post (the global script is 250 lines long), but globaly, that's the try I maked.

According to the debugmes, the maps good, the ids too, the unit exists...But nothing poped out...

Any idea why? Am I missing something?

2 answers to this question

Recommended Posts

  • 0
Posted

Finally, as expected with the last comment, it was a matter of level error, while no error is raised. The mobs just don't pop the skill if it doesn't match the highest level cap.

Problem solved.

 

Well actually I found yesterday evening what's happening with the areamobuseskill ones.

It's due to the lvl I used. Storm Gust is limited to lvl 5, while I wanted it to be buffed, and poped a lvl 10.

While it didn't worked, it didn't poped an error message either...It made me lose a bunch of time, but now it's working well.

  • 0
Posted
On 9/14/2017 at 12:58 PM, Alayne said:

Hello peoples,

I'm stucked on this case for 3h in a row now...I've ran out of ideas, so if anyone got one...I took it!

I'm currently working on a script that pops a monster, and I want this monster to pop a skill. But no matter what, it doesn't work...

Here's the case I've tried:


monster .wbMap$[.@spawnRand],123,150,.wBossName$[.lastRandId],.wBossIds[.lastRandId],1,strnpcinfo(3) + "::OnWorldBossDied",2; 
set .wBossId, $@mobId[0];
debugmes "pop skill " + .wBossId + " " + unitexists(.wBossId);

unitskilluseid .wBossId, WZ_STORMGUST, 5; //or with skill id

getunitdata(.wBossId, .@worldBossData);
areamobuseskill $lastPopMap$, .@worldBossData[UMOB_X], .@worldBossData[UMOB_Y], 50, .wBossIds[.lastRandId], 653, 10, 3000,1,e_gg,3; //or with NPC_EARTHQUAKE

It's a bit modified to make it easiest to post (the global script is 250 lines long), but globaly, that's the try I maked.

According to the debugmes, the maps good, the ids too, the unit exists...But nothing poped out...

Any idea why? Am I missing something?

According to 

https://github.com/rathena/rathena/blob/master/doc/script_commands.txt *unitskilluseid

I think you need to either set a target or coordinates for that particular skill, because that skill is a clickable targetable skill on the ground? ...

 

I could be wrong, but worth a shot? maybe just for testing purposes try to target 

```unitskilluseid .wBossId, WZ_STORMGUST, 5, 125, 155;```

can't hurt?

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.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...