Help with DoMovingEffect

Need help with your JScripts? Got questions concerning the DFNs? Come forward, step inside :)
Post Reply
Galbuu
UOX3 Neophyte
Posts: 45
Joined: Mon Jul 05, 2004 9:20 am
Location: Orlando, FL
Has thanked: 0
Been thanked: 0
Contact:

Help with DoMovingEffect

Post by Galbuu »

Have a look at this code.

Code: Select all

function onUse(pUser, iUsed)
{
pUser.CustomTarget(0, "Who do you want to throw this rock at?");
}

function onCallback0(pUser, myTarget)
{
pUser.DoMovingEffect(pUser, myTarget, 0x1ea7, 0x07, 0x00, false);
myTarget.health -= 1;
}
I am trying to make an item that when you use it and target a creature a rock (0x1ea7) will fly from your character and hit your target and also deal 1 damage. The damage part works but there is never an effect. I have tried using different IDs.

(I didn't put in any animations or anything yet, trying to get this to work first)
Maarc
Developer
Posts: 576
Joined: Sat Mar 27, 2004 6:22 am
Location: Fleet, UK
Has thanked: 0
Been thanked: 0
Contact:

Post by Maarc »

Alter the call to DoMovingEffect, it should look more like

DoMovingEffect( pUser, myTarget, effect, speed, loop, explode );

Try something like:

Code: Select all

DoMovingEffect( pUser, myTarget, 0x36E4, 05, 00, true );
That's the values for one of the spells (don't remember which).
Galbuu
UOX3 Neophyte
Posts: 45
Joined: Mon Jul 05, 2004 9:20 am
Location: Orlando, FL
Has thanked: 0
Been thanked: 0
Contact:

Post by Galbuu »

No go. Actually, I even tried using the example you gave me and that didn't work. I must have set up the whole thing wrong but I'm too inexperienced to figure it out.
Eolirin
Has thanked: 0
Been thanked: 0

Post by Eolirin »

The last time I tried using DoMovingEffect it was kinda buggy. It didn't always trigger properly.
mrboris
UOX3 Neophyte
Posts: 28
Joined: Wed Jun 30, 2004 4:00 am
Has thanked: 0
Been thanked: 0
Contact:

Post by mrboris »

DoMovingEffect( Bong, myChar, 0x3735, 3, 50, false);

that takes smoke from my bong to my character.
Post Reply