Advertisement
totodeux

Penta eluna 2

Jul 12th, 2013
221
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 2.14 KB | None | 0 0
  1. local UNIT_FIELD_FLAGS = 0x0006 + 0x0035 -- Size: 1, Type: INT, Flags: PUBLIC
  2. local UNIT_FLAG_NOT_SELECTABLE = 0x02000000 -- 26    33554432  cannot select the unit
  3. local INVISIBLE_DUMMY = 24417 --invisible man + cannot select the unit
  4.  
  5. local function test5(event, player, msg, lang, typ)
  6.     if(msg == "test5") then
  7.     local BEAM_SPELL = 33535
  8.     local k = 6; -- Scale
  9.     local t = 10000 -- Time in ms
  10.    
  11.     local p = {};
  12.     local pPlayer = {};
  13.    
  14.     pPlayer["X"] = player:GetX();
  15.     pPlayer["Y"] = player:GetY();
  16.     pPlayer["Z"] = player:GetZ();
  17.    
  18.     p[1] = player:SummonGuardian( INVISIBLE_DUMMY, pPlayer["X"], pPlayer["Y"]+k, pPlayer["Z"]-1.5,0, t);
  19.     p[2] = player:SummonGuardian( INVISIBLE_DUMMY, pPlayer["X"]+k*0.95, pPlayer["Y"]+k*0.31, pPlayer["Z"]-1.5,0, t);
  20.     p[3] = player:SummonGuardian( INVISIBLE_DUMMY, pPlayer["X"]+k*0.59, pPlayer["Y"]+k*(-0.81), pPlayer["Z"]-1.5,0, t);
  21.     p[5] = player:SummonGuardian( INVISIBLE_DUMMY, pPlayer["X"]+k*(-0.95), pPlayer["Y"]+k*0.31, pPlayer["Z"]-1.5,0, t);
  22.     p[4] = player:SummonGuardian( INVISIBLE_DUMMY, pPlayer["X"]+k*(-0.59), pPlayer["Y"]+k*(-0.81), pPlayer["Z"]-1.5,0, t);
  23.     p[6] = player:SummonGuardian( INVISIBLE_DUMMY, pPlayer["X"]+k*0.95, pPlayer["Y"]+k*0.31, pPlayer["Z"]-1.5,0, t);
  24.     p[7] = player:SummonGuardian( INVISIBLE_DUMMY, pPlayer["X"]+k*0.95, pPlayer["Y"]+k*0.31, pPlayer["Z"]-1.5,0, t);
  25.     p[8] = player:SummonGuardian( INVISIBLE_DUMMY, pPlayer["X"]+k*0.59, pPlayer["Y"]+k*(-0.81), pPlayer["Z"]-1.5,0, t);
  26.     p[9] = player:SummonGuardian( INVISIBLE_DUMMY, pPlayer["X"]+k*0.59, pPlayer["Y"]+k*(-0.81), pPlayer["Z"]-1.5,0, t);
  27.     p[10] = player:SummonGuardian( INVISIBLE_DUMMY, pPlayer["X"]+k*(-0.59), pPlayer["Y"]+k*(-0.81), pPlayer["Z"]-1.5,0, t);
  28.    
  29.     for i = 1,10 do
  30.     p[i]:SetUInt32Value(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
  31.     p[i]:SetRooted(true);
  32.         if(i <= 5) then
  33.             if(i == 5) then
  34.             p[i]:CastSpell(p[1],BEAM_SPELL)
  35.             else
  36.             p[i]:CastSpell(p[i+1],BEAM_SPELL)
  37.             end
  38.         end
  39.     end
  40.     p[6]:CastSpell(p[5],BEAM_SPELL);
  41.     p[7]:CastSpell(p[4],BEAM_SPELL);
  42.     p[8]:CastSpell(p[1],BEAM_SPELL);
  43.     p[9]:CastSpell(p[5],BEAM_SPELL);
  44.     p[10]:CastSpell(p[1],BEAM_SPELL);
  45.     return false
  46.     end
  47. end
  48.  
  49. RegisterServerHook(18, test5)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement