[Help]Need help...again menu

User Tag List

Results 1 to 5 of 5
  1. #1
    Muruk's Avatar Member
    Reputation
    1
    Join Date
    Mar 2008
    Posts
    45
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    [Help]Need help...again

    Ok, well I have been wondering about combat between 2 NPC characters... I script one of them but as it turns out the guy i scripted just applies the spell to himself...

    I have the CastSpellOnTarget(SpellID, pUnit:GetMainTank())... that whole deal, im not sure if thats the one im supposed to use or if there is a special command so it will attack npcs, as well as players.

    any tips?

    [Help]Need help...again
  2. #2
    Nilrac's Avatar Banned
    Reputation
    360
    Join Date
    Nov 2007
    Posts
    762
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    From what i have heard and tried, the fuction CastSpellOnTarget isn't working properly for some servers.

    Not to sure why.

    Also post your lua so I can look at it

  3. #3
    Muruk's Avatar Member
    Reputation
    1
    Join Date
    Mar 2008
    Posts
    45
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Code:
    function Rend_Atk(pUnit)
     pUnit:CastSpellOnTarget(37662, pUnit:GetMainTank())
    end
    function SRGuard_OnCombat(pUnit, Event)
     pUnit:RegisterEvent("Rend_Atk",10000, 0)
    end
    function SRGuard_OnLeave(pUnit, Event)
     pUnit:RemoveEvents();
    end
    RegisterUnitEvent(76000, 1, "SRGuard_OnCombat")
    RegisterUnitEvent(76000, 2, "SRGuard_OnLeave")
    thats the lua code im using for the mob
    -----------------------------------
    Oh also, an occurance the CastSpellOnTarget works on my server, but the spells are only working on players...mainly my character when around enemy npcs ive scripted their spells instead of targeting the other npcs hit me instead

    i have the .invisible command up too so they arnt attacking me just casting spells on me.

    Wierd:confused:
    Last edited by Muruk; 06-18-2008 at 04:07 PM. Reason: Automerged Doublepost

  4. #4
    Nilrac's Avatar Banned
    Reputation
    360
    Join Date
    Nov 2007
    Posts
    762
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Okay, well instead of pUnit:CastSpellOnTarget, use player:CastSpell(id)

  5. #5
    BrantX's Avatar Contributor
    Reputation
    205
    Join Date
    Jul 2007
    Posts
    899
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Code:
    pUnit:CastSpellOnTarget(37662, pUnit:GetMainTank())
    should look like

    Code:
     pUnit:FullCastSpellOnTarget(37662, pUnit:GetMainTank())
    Atleast i think.



Similar Threads

  1. [Need] Help again
    By aznboy in forum World of Warcraft General
    Replies: 2
    Last Post: 04-09-2008, 12:12 PM
  2. Website Problem, Need Help again
    By Lilltimmy in forum World of Warcraft Emulator Servers
    Replies: 12
    Last Post: 03-17-2008, 02:57 PM
  3. Sry but i need help again
    By aznboy in forum World of Warcraft Emulator Servers
    Replies: 4
    Last Post: 11-11-2007, 05:43 AM
  4. Paper help again lol
    By richardsonc in forum Community Chat
    Replies: 3
    Last Post: 04-04-2007, 04:03 PM
All times are GMT -5. The time now is 11:54 AM. Powered by vBulletin® Version 4.2.3
Copyright © 2025 vBulletin Solutions, Inc. All rights reserved. User Alert System provided by Advanced User Tagging (Pro) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
Google Authenticator verification provided by Two-Factor Authentication (Free) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
Digital Point modules: Sphinx-based search