Welcome to the MMOtop - Arcemu, Mangos, Trinity.
+ Reply to Thread
Results 1 to 8 of 8
  1. #1
    Status : killerwow is offline
    Join Date : Jun 2010
    Location : Sweden
    Posts : 19
    Thanks: 2
    Thanked 2 Times in 2 Posts
    Rep Power : 2
    Reputation:30killerwow is on a distinguished road

    Default [Arcemu] List of LUA Commands

    Hey everyone I didn't make this credits goes to Brantx


    .:GOSSIP STUFF:.

    :GossipCreateMenu -- I have
    :GossipMenuAddItem -- no clue
    :GossipSendMenu --on how to work
    :GossipComplete --with
    :GossipSendPOI -- gossip.

    .:GET STUFF:.

    :GetMainTank() --Returns main tank.
    :GetAddTank() --Returns offtank.
    :GetX() --Gets unit's X cordinate.
    :GetY() --Gets unit's Y cordinate.
    :GetZ() --Gets unit's Z cordinate.
    :GetO() --Gets unit's O cordinate.
    :GetTauntedBy() --Gets the target the unit was taunted by.
    :GetSoulLinkedWith() --Gets the unit that it is soullinked with.
    :GetItemCount(xxxx) -- Get the amount of "xxxx" items in the player's inventory. Replace the XXXX with the itemid.
    :GetName() --Gets the name of the unit.
    :GetHealthPct() --Gets the health percent of the unit.
    :GetManaPct() --Gets the mana percent of the unit.
    :GetInstanceID() --Gets the instance id of the unit(if in an instance)
    :GetClosestPlayer() --Gets the closest player.
    :GetSpellId(spellid) -- This returns the spell as unit(planned for spell editing).
    :GetRandomPlayer(flag)
    RANDOM_ANY = 0,

    RANDOM_IN_SHORTRANGE = 1,

    RANDOM_IN_MIDRANGE = 2,

    RANDOM_IN_LONGRANGE = 3,

    RANDOM_WITH_MANA = 4,

    RANDOM_WITH_RAGE = 5,

    RANDOM_WITH_ENERGY = 6,

    RANDOM_NOT_MAINTANK= 7
    :GetRandomFriend() --Gets a random friend(friendly to the unit)
    :GetUnitBySqlId(sqlid) -- use this to return a unit BY SQL ID. .go info or .npc info can provide u w/ sql id
    :GetUnitByGUID(guid) -- This returns a unit that has that guid.
    :GetPlayerClass() --Gets the player's class, will return in number form.
    :GetHealth() --Gets the unit's health, returns the exact health
    :GetMaxHealth() --Gets the unit's max health.
    :GetCreatureNearestCoords() -- similar to getgameobjectnearestcoords but for creatures.
    :GetCreatureGuid() -- absolete
    :GetGameObjectGuid() -- absolete
    :GetPlayerCountInRadius() -- this will lagg the client when called, don't use it, use GetInRangePlayerCount() instead.
    :GetGameObjectNearestCoords(x,y,z,gameobjectid) -- This returns the GO as a unit if it is found.
    Usage:
    local door = Unit:GetGameObjectNearestCoords(x,y,z,doorid)
    if door ~= nil then
    door:SetUInt32Value(GAMEOBJECT_STATE,1) -- close the door
    end
    :GetDistance(target) -- use this to check the distance from this unit to the target specified, it does not scale to yards.
    :GetGUID() -- returns a uint64 guid number that is unique to every player/creature/go/(item?).
    :GetZoneId() -- returns the zone id that the unit is currently in.
    :GetMaxMana() -- This returns the maximum mana the unit CAN have.
    :GetMana() -- This returns the exact mana the unit has. Use this w/ getpowertype to check if the unit as mana to begin with.
    :GetCurrentSpellId() -- if a unit is casting a spell, this will return the spellid of the spell that is unit is casting.
    :GetInstanceID() -- returns the instance id number if the unit/player/go is in an instance.
    :GetSpawnX() -- returns the x spawn point coord.
    :GetSpawnY() -- " " y " ".
    :GetSpawnZ() -- " " z " ".
    :GetSpawnO() -- " " o " ".
    :GetInRangePlayersCount() -- if the unit has inrangeplayers, this will return how many of those players are there.
    :GetAIState() -- returns the ai state that the unit is in, in number form.
    :GetAITargets() -- this will return a table containing a list of targets that the unit has(threat table);
    :GetInRangeObjects() -- returns a table containing a list of inrange gameobjects.
    :GetInRangeObjectCount() -- returns the number of gameobjects near the unit/go/player.
    :GetAITargetsCount() -- self explainatory.
    :GetPowerType() -- this returns the power type IN STRING FORM,"Health", "Mana", "Rage", etc.
    :GetInRangeFriends() -- Use this to return units that are friendly to the unit. It returns in a table.
    :GetPlayerLevel() -- Don't have to explain this one.
    :GetStealthLevel() -- This returns the stealth points the unit has if any.
    :GetFaction() -- returns the faction number.
    :GetNextTarget() -- returns current target?
    :GetUInt32Value(field) -- check core to see how they are used.
    :GetUInt64Value(field) -- check core to see how they are used.
    :GetMapId() -- returns mapid.

    .:BOOLS(Is? commands):.

    :IsPlayer() -- same as IsCreature but for players instead, use to check if the current unit is a player.
    :IsCreature() -- if the current unit it is called on is a creature, it returns true/false if its not.
    :IsInCombat() returns true/false if the unit is in combat/not in combat.
    :IsCasting() -- if unit is casting a spell it returns true/false if the unit is not.(Maybe be not functional)
    :IsAlive() -- reverse of isdead(), returns true if the unit is alive/false if the unit is dead.
    :IsDead() -- is dead check. If the unit is dead, it will return true/false if its not.
    :IsInWorld() -- kind of a safe check to see if the current unit exists in the world, returns true/false
    :IsPlayerMoving() -- this is for players, returns true/false if the player is moving/not moving
    :IsCreatureMoving() -- same but for creatures, returns true/false if creature is moving/notmoving
    :IsInFront(target) -- it returns true/false if the current unit is in front of the target specified.
    :IsInBack(target) -- explainatory.
    :IsPacified() -- if unit is pacified true/false if not.
    :IsInWater() -- for players only, checks if the player is in water.
    :NoRespawn() -- set to 1 to disable respawn, 0 to allow respawning, for creatures only.
    :IsStealthed() -- If unit is stealthed, true/false if not.
    :IsPlayerAttacking() -- true/false if player is attacking, player only command.

    .:OTHERS:.

    :SendChatMessage(type,language,message) -- Type is the chat type e.g. Say,Yell,RaidWarning, chat.h has a list of them; language is pretty obvious.
    Usage:
    function SayThis(Unit,event)
    local plr = Unit:GetMainTank()
    if plr ~= nil then
    Unit:SendChatMessage(14(yell),0(Universal lang),plr:GetName()..", you cannot resist me!")
    end
    end
    :MoveTo(x,y,z,o) -- pretty self explainatory. Use .gps while ingame to retrieve coords, O is just orientation.
    Usage:
    function MoveTo(Unit,event)
    Unit:MoveTo(Unit:GetSpawnX(),Unit:GetSpawnY(),Unit :GetSpawnZ(),Unit:GetSpawnO()) -- makes the unit move to its spawn points.
    end
    :CastSpell(spellid) -- Just fill in the spell id which you want to the current unit to cast. This will cast the spell on caller of this function and ignore cast time.
    Usage:
    function CastSpell(Unit,event)
    Unit:CastSpell(5) -- death touch xd
    end
    :CastSpellOnTarget(spellid,target) -- first blank is spellid just like above, 2nd is target, there is a bug w/ this function that it causes it not to cast on the target.
    Use FullCastSpellOnTarget(spellid,target) if you want to cast on a target.
    :FullCastSpell(spellid) -- This does the same as castspell except with casttime.
    :FullCastSpellOnTarget -- Fully casts the spell with cast time but on a target(if target is the unit, just use castspell or fullcastspell)
    :SpawnGameObject(entry_id,x,y,z,duration)-- spawns a gameobject from the entry id given at the location vector given
    Usage:
    Unit:SpawnGameObject(166434(random no.),Unit:GetX(),Unit:GetY(),Unit:GetZ(),0(0 duration to make the go not despawn. Add duration in milisecs to make it despawn after x seconds))
    :SpawnCreature(entryid,x,y,z,faction,duration) -- Unlike spawngameobject, creatures use factions. This decides whether they are friendly/hated towards the player and other stuff like if you kill it what rep u get.
    Usage:
    Unit:SpawnCreature(randomnumberhere,Unit:GetX(),Un it:GetY(),Unit:GetZ(),14,5000(despawn after 5 secs))
    :RegisterEvent(string,delay,repeats) -- registers a function to call on the unit, note that only creatures can use this, not gameobjects.
    Usage:
    Unit:RegisterEvent("KillYou",5000, 1)
    whereas
    function KillYou(Unit,event)
    Unit:FullCastSpellOnTarget(5,Unit:GetRandomPlayer( 0))
    end
    :RemoveEvents() -- this has no arguments and removes all registered functions.
    Usage:
    function OnCreatureDied(Unit,event)
    Unit:RemoveEvents()-- when the creature is dead, remove all functions so it doesn't do anything.
    end
    :SendBroadcastMessage(string) -- this is a player only command. The player who called it, displays a message that you typed in there
    Usage:
    function Error(Unit,event)
    local tank = Unit:GetMainTank()
    tank:SendBroadCastMessage("You are now tanking "..Unit:GetName())
    end
    :SendAreaTriggerMessage(stringfunc) I have never used this and don't know its effects.
    :KnockBack() -- neither this.
    :MarkQuestObjectiveAsComplete(questid,objective) -- Never used this.
    :LearnSpell(spellid) -- This is a player only command, it teaches the player unit that it is called on the spellid
    Usage:
    local plr = Unit:GetClosestPlayer()
    plr:LearnSpell(5) -- learn death touch xd
    :UnlearnSpell(spellid) -- This just removes a spell already known from the player.
    Usage
    local plr = Unit:GetClosestPlayer()
    plr:UnlearnSpell(5) -- noooes gief death touch!!
    :HasFinishedQuest(questid)-- this is a boolean like others to come. It checks whether the player has finished the quest provided w/ the id, if not, it pushes false.
    Usage:
    local plr = Unit:GetClosestPlayer()
    if plr:HasFinishedQuest(questid) == true then
    do this if the player has completed the quest
    end
    :ClearThreatList() -- this maybe confused to wipethreatlist. What it does is set all threat levels to 1, This means the creature will still aggro, but aggro can be easily taken away.
    :ChangeTarget(target) -- This causes the Unit to change the target, it is basically SetNextTarget(target).
    :Emote(emoteid) -- Use this to get the unit to do a certain emote.
    espawn(delay,respawn)-- Note this is a creature only one, if you filled the first blank, it will delay the alloted time filled before despawning, if you filled second, it will respawn the unit after the alloted time.
    :PlaySoundToSet(soundid) -- Look in soundentries.dbc for various sounds to play. .playall(soundid) can come in handy to differenciate.
    :RemoveAura(spellid) -- If a spell has an aura, this will remove that aura.
    Usage:
    Unit:RemoveAura(41431) -- noes, gief bubble plis
    :StopMovement(delaytime) -- This will make the unit stop moving for the time specified. A creature only command.
    :AddItem(itemid) -- This is a player only command, use it to add an item to a players inventory.
    :RemoveItem(itemid) -- Use to take a way and item from a players invent.
    :CreateCustomWaypointMap() -- This creates a custom waypoint map, whether u call this or not, createwaypoint will create one automatically.
    :CreateWaypoint(x,y,z,waittime,moveflags,displayid ) -- x,y,z are the coords, waittime is the delay for it to not move,moveflags are either 0 for walk, 256 for run, or 768 for fly, displayid is how you want the waypoints to look like(Like mini models).
    estroyCustomWaypointMap() -- use it to destroy all waypoints that the unit has. Only works for creatures.
    :MoveToWaypoint(waypointid) -- When you create ur first waypoint, they are numberd in order start from 1. 0 and 1 do the same thing. Use it to make a unit move to various waypoints.
    :TeleportUnit(mapid,x,y,z) -- This teleport's a PLAYER only unit to the location specified.
    :ClearHateList() -- this is a duplicate of ClearThreatList(). They do the same thing.
    :WipeHateList() -- This removes ALL Threat off the mob, this will cause the mob to leavecombat and return to spawn.
    :WipeTargetList() -- This just does the same as WipeHateList(), causes the mob to reset.
    :WipeCurrentTarget() -- This will cause the unit to disengaged the current player and target a new.
    :CastSpellAoF(x,y,z,spellid) -- This is for aoe spell types. Currently bugged since the spell does no dmg.
    :RemoveAllAuras() -- removes ALL auras, positive or negative on the current unit.
    :StopChannel() -- If the unit is channeling a spell, it stops it.
    :ChannelSpell(guid,spellid) -- Use this to make a unit channel, guid is the target's guid u wish and spellid is the spell u want to channel.
    Usage:
    local plr = Unit:GetRandomPlayer()
    if plr ~= nil then
    Unit:ChannelSpell(plr:GetGUID(),spellid) -- channel a certain spell on the player.
    end
    :ReturnToSpawnPoint() -- makes a unit go back to its spawn point.
    :HasAura(auraid) -- this is a boolean, returns true if the unit has the auraid given, or false if not.
    :Land() -- Use this to land units that are already flying.
    :CancelSpell() -- This cancels the units current spell?
    :AdvanceSkill(skillid,amounttoincrement) -- use it the same way u use gm command.
    :AddSkill(skillid) -- use to add a skill to player if the player doesn't already have it.
    :RemoveSkill(skillid) -- explainatory.
    :PlaySpellVisual(guid,spellid) -- doesn't seem to work.
    :RemoveThreatByPtr(target) -- Removes all threat if any, on the current target specified
    :EventCastSpell(target,sp,delay,repeats) -- this casts a spell over and over on the target specified, delay is amount to wait before recasting, repeats is how many times.
    :AttackReaction(target,dmg,spell) -- This creates fake threat towards the unit specified
    Usage:
    local plr = Unit:GetRandomPlayer(0)
    Unit:AttackReaction(plr, 1, 0) -- If the unit doesn't have any aggro, it will now aggro this player.
    :Root() -- this unlike stopmovement(), disables all movement.
    :Unroot() -- allows movement again.
    :Heal(target,spellid,amount) -- The current unit heals the target specified for the amount and spell id.
    :Energize(target,spellid,amount,type) -- Restore mana/rage/focus/hp?
    :Strike(target,dmg,sp,adddmg,exclusivedmg,pct_dmg_ mod) -- I dono xD
    :Kill(target) -- this pretty much calls a dealdamage that deals damage equivalent to the Units hp.
    ealDamage(target,damage,spellid) -- Use this to deal modified dmg to the target specified.
    :RessurectPlayer() -- player only command, rez the player!
    :RemoveFromWorld() -- use this for both creatures/gos to remove that unit from the world.
    :ModThreat(target, amount) -- modifies threat of the target, if any, to the amount specified.
    :AddAssitTarget(target) -- Use this in conjunction w/ onassisttarget died event to call stuff.
    :RemoveAurasByMechanic(mechanicid,hostileonly) -- This removes all auras depending on what mechanic,(sleep,fear,etc), hostileonly is a bool, put 1 to remove only hostile auras, 0 for all pos and nega auras
    :RemoveStealth() -- if the unit is in stealth, it removes it from stealth.
    :RegisterAIUpdateEvent(miliseconds) -- This creates an ai update event to use w/ ONAIUPDATEVENT.
    :ModifyAIUpdateEvent(newtime) -- changes the prev time to the one provided.
    :RemoveAIUpdateEvent() -- similar to RemoveEvents() but only removes aiupdate event.
    eleteWaypoint(wpid) -- if the unit has that wpid, it deletes it.

    .:SET STUFF:.

    :SetMana(newmana) -- Sets the units current mana to this.
    :SetMaxMana(maxmana) -- sets the maximum mana the unit can have, to this.
    :SetHealth(newhp) -- explainatory.
    :SetMaxHealth(newmaxhp) -- explainator.
    :SetFieldFlags() -- absolete, use SetUInt32/64Value(field,value)
    :SetFlying() -- if the unit can hover, it sets to hover.
    :SetCombatCapable(1/0) -- 1 disables combat, 0 re-enables combat.
    :SetCombatMeleeCapable(1/0) - 1 disables melee ability, 0 enables it.
    :SetCombatRangedCapable(1/0) -- and so on.
    :SetCombatSpellCapable(1/0) -- and so on.
    :SetCombatTargetingCapable(1/0) -- Disables targeting, only disables new targeting, if the unit already has targgeted u, it will continue to do so.
    :SetNPCFlags() -- absolete
    :SetModel(newid) -- changes the display of the unit.
    :SetScale(newscale) -- changes the size of the unit, doesn't scale compared to scalespells.
    :SetFaction(newfaction) -- changes the faction of the unit, doesn't take effect until u rezone.
    :SetStandState(newstandstate) -- Need more info.
    :SetTauntedBy(target) -- set to be taunted by the target provided
    :SetSoulLinkedWith(target) -- set soul linked, I think this means that only that target can attack this unit.
    :SetInFront(target) -- I guess it sets the current unit to be infront of the target provided.
    :SetOutOfCombatRange(combatrange) -- this sets outofcombatrange.
    :SetMovementType(0 - walk, 256 - run, 768 - fly) - yep.
    :SetHealthPct() -- sets the PERCENT of the hp.
    :ModifyRunSpeed(float) -- changes
    :ModifyWalkSpeed(float) -- the units
    :ModifyFlySpeed(float) -- speed.
    :SetOrientation(newo) -- new direction to face.
    :SetFacing(newo) -- new direction to face, only if unit is idle.
    :SetNextTarget(target) -- make the unit target the one provided.
    :SetStealth(stealthpoints) -- makes the unit go into stealth mode, is detected depending on how many stealth points
    :SetPowerType(string) -- this uses strings to set the power type ("health,mana,rage,focus,energy")
    :SetDeathState(newdeathstate) -- sets death state
    :SetPlayerStanding(faction,value) -- sets the rep of the player related to the faction.
    :SetPlayerLevel(level) -- explainatory.

    If you need any better defination post here and I will try to help you.
    Last edited by killerwow; 06-18-2010 at 09:55 PM.

  2. The Following User Says Thank You to killerwow For This Useful Post:

    Jerry (06-18-2010)

  3. #2
    Jerry's Avatar
    Status : Jerry is offline
    Join Date : Mar 2009
    Location : Serbia
    Posts : 2,321
    Thanks: 223
    Thanked 501 Times in 286 Posts
    Rep Power : 10
    Reputation:2077Jerry has a reputation beyond repute Jerry has a reputation beyond repute Jerry has a reputation beyond repute Jerry has a reputation beyond repute Jerry has a reputation beyond repute Jerry has a reputation beyond repute Jerry has a reputation beyond repute Jerry has a reputation beyond repute Jerry has a reputation beyond repute Jerry has a reputation beyond repute Jerry has a reputation beyond repute

    Default

    Thanks for sharing

  4. #3
    Truster's Avatar
    Status : Truster is offline
    Join Date : Apr 2010
    Location : Norway
    Posts : 3,341
    Thanks: 46
    Thanked 87 Times in 83 Posts
    Rep Power : 10
    Reputation:2014Truster has a reputation beyond repute Truster has a reputation beyond repute Truster has a reputation beyond repute Truster has a reputation beyond repute Truster has a reputation beyond repute Truster has a reputation beyond repute Truster has a reputation beyond repute Truster has a reputation beyond repute Truster has a reputation beyond repute Truster has a reputation beyond repute Truster has a reputation beyond repute

    Default

    nice share :)

  5. #4
    Status : killerwow is offline
    Join Date : Jun 2010
    Location : Sweden
    Posts : 19
    Thanks: 2
    Thanked 2 Times in 2 Posts
    Rep Power : 2
    Reputation:30killerwow is on a distinguished road

    Default

    hehe np

  6. #5
    ~Sidefx™'s Avatar
    Status : ~Sidefx™ is offline
    Join Date : Jun 2010
    Location : Louisville
    Posts : 968
    Thanks: 15
    Thanked 46 Times in 26 Posts
    Rep Power : 3
    Reputation:140~Sidefx™ will become famous soon enough ~Sidefx™ will become famous soon enough

    Default

    Didn't someone just post a very similar LUA list like a week ago?

  7. #6
    AnTo's Avatar
    Status : AnTo is offline
    Join Date : Oct 2009
    Location : not saying
    Posts : 701
    Thanks: 21
    Thanked 63 Times in 23 Posts
    Rep Power : 3
    Reputation:97AnTo will become famous soon enough

    Default

    i dont remember..

  8. #7
    Truster's Avatar
    Status : Truster is offline
    Join Date : Apr 2010
    Location : Norway
    Posts : 3,341
    Thanks: 46
    Thanked 87 Times in 83 Posts
    Rep Power : 10
    Reputation:2014Truster has a reputation beyond repute Truster has a reputation beyond repute Truster has a reputation beyond repute Truster has a reputation beyond repute Truster has a reputation beyond repute Truster has a reputation beyond repute Truster has a reputation beyond repute Truster has a reputation beyond repute Truster has a reputation beyond repute Truster has a reputation beyond repute Truster has a reputation beyond repute

    Default

    Quote Originally Posted by -Sidefx View Post
    Didn't someone just post a very similar LUA list like a week ago?
    think so

  9. #8
    ~Sidefx™'s Avatar
    Status : ~Sidefx™ is offline
    Join Date : Jun 2010
    Location : Louisville
    Posts : 968
    Thanks: 15
    Thanked 46 Times in 26 Posts
    Rep Power : 3
    Reputation:140~Sidefx™ will become famous soon enough ~Sidefx™ will become famous soon enough

    Default

    Lol.


 

Visitors found this page by searching for:

arcemu lua commands

wow arcemu lua commands

All arcemu lua script commands

arcemu lua commands 2012

arcemu instance scripts

Arcemu how to use LUA commads

arcemu event start lua scriptarcemu door luaarcemu default lua commandsarcemu how to use waypointsarcemu scripts CastSpellAoFLUA Commands Arcemuarcemu script get player name from unitarcemu lua Unit:CastSpell() max times cast spellarcemu zone id listarcemu zone idsarcemu evets startencommands script arcemuwow chattype arcemuarcemu lua script doorarcemu quest scriptsArcEmu Default Lua Command List.arcemu SetMaxMana ArcEmu Default Lua Command List.all arcemu lua commands
SEO Blog

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts