[Lua] Player Commands
Twist Gaming :: Gaming and Server Development :: MMORPGs Emulation & Chat :: World of Warcraft :: Emulation :: Releases
Page 1 of 1
[Lua] Player Commands
What you can do with this one, commands:
1. Repair - Will summ Repair Bot for 5 mins.
2. Buffs - You will gain buffs. (Mainly buffs from scrolls)
3. Turbo - Will allow you to use sprint for few sec. (5 mins cd)
4. Food - Will add you food. (With well feed)
5. Battle - Will add few battle elixirs.
6. Guardian - Will add few guardian elixirs.
Script:
No credits to me.I posted this not for +rep but because I see it helpfully for your server.
1. Repair - Will summ Repair Bot for 5 mins.
2. Buffs - You will gain buffs. (Mainly buffs from scrolls)
3. Turbo - Will allow you to use sprint for few sec. (5 mins cd)
4. Food - Will add you food. (With well feed)
5. Battle - Will add few battle elixirs.
6. Guardian - Will add few guardian elixirs.
Script:
function OnChat(event, player, message, type, language)
if (message == Repair_Bot) then
local x = player:GetX()
local y = player:GetY()
local z = player:GetZ()
local o = player:GetO()
player:SpawnCreature(24780, x, y+2, z, o, 35, 300000)
player:SendAreaTriggerMessage("You have spawned Your Repair Bot successfully!")
return 0
end
if (message == Buff_Up) then
if (player:IsInCombat() == true) then
player:SendAreaTriggerMessage("You cannot Buff Up while in Combat!")
else
if (player:IsDead() == true) then
player:SendAreaTriggerMessage("You cannot Buff Up while You are Dead!")
else
player:CastSpellOnTarget(43466, player)
player:CastSpellOnTarget(43464, player)
player:CastSpellOnTarget(37092, player)
player:CastSpellOnTarget(37098, player)
player:CastSpellOnTarget(37094, player)
player:CastSpellOnTarget(43467, player)
player:SendAreaTriggerMessage("You have been buffed with success!")
return 0
end
end
if (message == Turbo_On) then
if (player:IsInCombat() == true) then
player:SendAreaTriggerMessage("You cannot use "Turbo" while in Combat!")
else
if (player:IsDead() == true) then
player:SendAreaTriggerMessage("You cannot use "Turbo" while You are Dead!")
else
player:CastSpellOnTarget(47, player)
player:SendAreaTriggerMessage("System online. Turbo mode activated!")
return 0
end
end
if (message == Food_On) then
Item:AddLoot(34762,20,20,ffa_loot)
Item:AddLoot(34767,20,20,ffa_loot)
player:SendAreaTriggerMessage("Food has been added with success!")
end
if (message == Battle_Elixir) then
Item:AddLoot(44330,20,20,ffa_loot)
Item:AddLoot(44327,20,20,ffa_loot)
Item:AddLoot(44329,20,20,ffa_loot)
Item:AddLoot(44331,20,20,ffa_loot)
player:SendAreaTriggerMessage("Battle Elixir's has been added with success!")
end
if (message == Guardian_Elixir) then
Item:AddLoot(32068,20,20,ffa_loot)
Item:AddLoot(22848,20,20,ffa_loot)
player:SendAreaTriggerMessage("Guardian Elixir's has been added with success!")
end
end
RegisterServerHook(16, "OnChat")
No credits to me.I posted this not for +rep but because I see it helpfully for your server.
Twist Gaming :: Gaming and Server Development :: MMORPGs Emulation & Chat :: World of Warcraft :: Emulation :: Releases
Page 1 of 1
Permissions in this forum:
You cannot reply to topics in this forum