L2Tower Discord Let's keep the community alive with discord. Discussions about plugins and scripts L2Tower Discord

Post Reply 
 
Thread Rating:
  • 1 Vote(s) - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Interlude spoil
Author Message
roru Offline
Ratman Chieftain
*

Posts: 22
Joined: Jun 2012
Reputation: 0
Version: 1.4.3.143
Post: #1
Interlude spoil

Нужен скрипт на споил , на форуме искал один не работает , второй работает , но криво ... если у кого есть поделитесь , заранее благодарен.
09-28-2013 09:36 AM
Find all posts by this user Quote this message in a reply
freemanpro Offline
VIP Member
***

Posts: 103
Joined: Apr 2012
Reputation: 13
Version: 1.4.3.143
Post: #2
RE: Interlude spoil

Проврено на Interlud сервере все работает . Даже все со скриптом на кормление на ферме !

-- type /spoil to start spoil

spoilMsg1 = "The Spoil condition has been activated.";
spoilMsg2 = " <<< SPOIL SUCCESSFUL!!! >>>";
spoilMsg3 = "It has already been spoiled.";
cantSpoilMsg1 = "There are no priority rights on a sweeper.";
cantSpoilMsg2 = "Sweeper failed, target not spoiled.";
cantSpoilMsg3 = "cannot be used due to unsuitable terms.";

SpoilMsg = {"The Spoil condition has been activated." ,"It has already been spoiled." , " <<< SPOIL SUCCESSFUL!!! >>>"};
cantSpoilMsg = {"There are no priority rights on a sweeper.", "Sweeper failed, target not spoiled.","cannot be used due to unsuitable terms."};

SpoilSkillCommand = "/useskill Spoil";
--------------------------------------------------------------------------------
SpoilStatus = false;
Spoiled = false;
tempId = 0;
--------------------------------------------------------------------------------
function OnCreate()
this:RegisterCommand("spoil", CommandChatType.CHAT_ALLY, CommandAccessLevel.ACCESS_ME);
end;
--------------------------------------------------------------------------------
function OnCommand_spoil(vCommandChatType, vNick, vCommandParam)
if (SpoilStatus == false) then
SpoilStatus = true;
ShowToClient("Plugin","Automatic Spoil Mode ACTIVATED.");
else
SpoilStatus = false;
ShowToClient("Plugin","Automatic Spoil Mode DEACTIVATED.");
end;
end;
--------------------------------------------------------------------------------
function CheckIfInsideList(Smsg,Rmsglist)
for x,y in pairs(Rmsglist) do
if (y == Smsg) then
return true;
end;
end;
return false;
end;
--------------------------------------------------------------------------------
function OnChatSystemMessage(id, msg)
if (((msg == spoilMsg1) or (msg == spoilMsg2)or (msg == spoilMsg3)) and (SpoilStatus == true)) then
Spoiled = true;
if (GetTarget() ~= nil)then
tempId = GetTarget():GetId();
end;
end;
if (((msg == cantSpoilMsg1) or (msg == cantSpoilMsg2)or (msg == cantSpoilMsg3)) and (SpoilStatus == true)) then
ClearTargets();
CancelTarget(false);
CancelTarget(false);
CancelTarget(false);
end;
end;
--------------------------------------------------------------------------------
function IfDeadAndSpoiledInRange(range)
local l = GetMonsterList();
for monst in l.list do
if ((monst:IsAlikeDeath() == true) and (monst:IsSpoiled() == true) and (monst:GetRangeTo(GetMe()) < range)) then
return monst:GetId();
end;
end;
return nil;
end;
--------------------------------------------------------------------------------
function OnLTick1s()
if(SpoilStatus) and (IsPaused() == false)then

local Me = GetMe();
if (Me:IsAlikeDeath() == false) and (Me ~= nil) then
----------------------------------- spoil
if (GetTarget() ~= nil)then
if(GetTarget():IsMonster())
and (Me:GetRangeTo(GetTarget()) < 100)
and (Spoiled == false) and (Me:GetMpPercent() > 10 )
and (GetTarget():GetId() ~= tempId)then
Command(SpoilSkillCommand);
else
Spoiled = false;
end;
end;
----------------------------------- Seeper
TempIdOfSpoiledMob = IfDeadAndSpoiledInRange(300);
if(TempIdOfSpoiledMob ~= nil)then
TargetRaw(TempIdOfSpoiledMob); --target mob witch is spoiled
Command("/useskill Sweeper"); --Sweeper
end;
end;
end;
end;
(This post was last modified: 09-28-2013 13:34 PM by freemanpro.)
09-28-2013 13:33 PM
Find all posts by this user Quote this message in a reply
Post Reply 


Possibly Related Threads...
Thread: Author Replies: Views: Last Post
  Проблема со спойлом. Interlude LightSnake 3 6,092 07-09-2015 15:57 PM
Last Post: Shanathas
  shock-world interlude roru 2 2,338 03-09-2015 00:34 AM
Last Post: roru
  Interlude.ru YaT 0 1,762 05-07-2014 17:39 PM
Last Post: YaT
  Lineage.ru Nanna x75 Interlude Sergon55 8 5,371 07-11-2013 00:23 AM
Last Post: Qzikpro
  Interlude huli 1 3,955 02-16-2013 11:35 AM
Last Post: natherlog



User(s) browsing this thread: 1 Guest(s)