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

Post Reply 
 
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
LF Script for using SS when multiple mobs around
Author Message
olaszosan1 Offline
Expired VIP Member
**

Posts: 125
Joined: Jul 2014
Reputation: 23
Version: 1.4.2.132
Post: #1
LF Script for using SS when multiple mobs around

As title says, I'm looking for a script or plugin that activates SS when there are lots of mobs around me, like training or somebody just running down to a dungeon pulling mobs accidentally.

(I already tried search, ty for those answers)

Thanks in advance!
10-29-2014 14:41 PM
Find all posts by this user Quote this message in a reply
tuxevil Offline
VIP Member
***

Posts: 161
Joined: Mar 2012
Reputation: 24
Version: 1.4.3.143
Post: #2
RE: LF Script for using SS when multiple mobs around

i use this for cementery on my feoh

so it activate soulshots when the many small mobs spawn after killing some of them (sorry dont remember the mob's name)

use it as an example

    LUA Programming
bssractive = false;
repeat
	ActivateSoulShot(19442, bssractive);
	if GetTarget():GetNpcId() == 19455 then
		bssractive = true;
	else bssractive = false;
	end;
	Sleep(500);
until false;



i hope it helps you
10-29-2014 15:53 PM
Find all posts by this user Quote this message in a reply
 Reputed by : olaszosan1(+1)
olaszosan1 Offline
Expired VIP Member
**

Posts: 125
Joined: Jul 2014
Reputation: 23
Version: 1.4.2.132
Post: #3
RE: LF Script for using SS when multiple mobs around

(10-29-2014 15:53 PM)Tuxevil Wrote:  i use this for cementery on my feoh

so it activate soulshots when the many small mobs spawn after killing some of them (sorry dont remember the mob's name)

use it as an example

    LUA Programming
bssractive = false;
repeat
	ActivateSoulShot(19442, bssractive);
	if GetTarget():GetNpcId() == 19455 then
 bssractive = true;
	else bssractive = false;
	end;
	Sleep(500);
until false;



i hope it helps you


Yes, its good for a start, but it only activates SS when a specific mob appears. I need a script which activates SS when regular mobs are around but in big numbers.

But thank you for your reply, +1 for you Smile
10-29-2014 16:27 PM
Find all posts by this user Quote this message in a reply
TheQQmaster Offline
Trolling the Trolls
*****

Posts: 1,532
Joined: Jun 2012
Reputation: 642
Version: 1.4.2.133
Post: #4
RE: LF Script for using SS when multiple mobs around

activates all shots
    LUA Programming
ShowToClient("Shots","ON");
 
 
function ActivateShots()
items = GetInventory();
for i in items.list do
	if string.match(i.Name, "Spiritshot") or string.match(i.Name, "Soulshot") then
 ActivateSoulShot(i.displayId,true)
	end;
end;
end;
 
ShotsActivatedPlayer = false;
 
---- MAIN ----
repeat	
me = GetMe();
if (me ~= nil) then
	if not (me:IsAlikeDeath()) then
 if not (ShotsActivatedPlayer) then
 ActivateShots()
 ShotsActivatedPlayer = true;
 end;
	elseif me:IsAlikeDeath() then
 Sleep(5*1000)
 repeat
 Sleep(1000);
 until (me:IsAlikeDeath() == false);
 ShotsActivatedPlayer = false;
	end; 
end;
 
Sleep(3*1000);
until false;




by name
    LUA Programming
--usage
if IsThereMobByName() then
--enable shots
elseif IsThereMobByName() == false then
--disable shots
end;
 
--function
function IsThereMobByName(mobname)
	local monsterlist = GetMonsterList();
	local count = 0;
	for mob in monsterlist.list do
 if (mob:GetName() == 'ur mob name') then -- edit here mob name
 return true;
 end;
	end;
 
	return false;
end;






function to make count u can use it for condition
    LUA Programming
if IsThereMobsAround() == 2 then
-- enable shots
end;
 
--or
if IsThereMobsAround() < 2 then
-- enable shots
end;
 
--or
if IsThereMobsAround() > 2 then
-- enable shots
end;


function to count mobs
    LUA Programming
function IsThereMobsAround()
	local monsterlist = GetMonsterList();
	local count = 0;
	for mob in monsterlist.list do
 if (mob:GetDistance() < 350) then
 count = count +1;
 end;
	end;
	if (count > 1) then
 return count;
	end;
	return 0;
end;




for disabling and enabling
    LUA Programming
ActivateSoulShot(shotid,true) -- enable shots
 ActivateSoulShot(shotid,false) -- disable shots



now u just need to compile all script Wink

PUSH [Image: knUu53] IF HELPED
(This post was last modified: 10-29-2014 19:20 PM by TheQQmaster.)
10-29-2014 17:33 PM
Visit this user's website Find all posts by this user Quote this message in a reply
 Reputed by : olaszosan1(+2) , diegol(+2)
Post Reply 


Possibly Related Threads...
Thread: Author Replies: Views: Last Post
  Bot Dont Attack mobs ;/ AtraX69 10 9,039 12-30-2016 21:35 PM
Last Post: sebi7
  Guillotine fortress mobs drake182 18 10,786 07-12-2015 10:03 AM
Last Post: botsbotsbotsbots
  Clear target after kill mobs astalavista 0 2,965 06-07-2015 18:46 PM
Last Post: astalavista
Exclamation Need help with new mobs pl17kv23 2 2,343 03-23-2015 17:26 PM
Last Post: pl17kv23
  Any way of skipping mobs? Haniack 14 8,551 02-06-2015 03:00 AM
Last Post: Vinter
  mobs, add mobs into l2tower roshpower 0 1,998 01-08-2015 21:27 PM
Last Post: roshpower
  Multiple start points in goddard/shuttgart? Nertiz1 6 5,848 04-28-2014 12:25 PM
Last Post: knutoz
  L2tower dosnt target spesific mobs SH4D0VVKN1GHT 0 2,054 04-20-2014 15:06 PM
Last Post: SH4D0VVKN1GHT
  running multiple tower accounts (1 VIP, other free)... Simiac 2 3,397 04-19-2014 12:25 PM
Last Post: TheBl4ckPhoenix
  Favor about invisible items/mobs james21 0 2,103 03-16-2014 20:27 PM
Last Post: james21



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