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
Target Delay
Author Message
eustach3 Offline
VIP Member
***

Posts: 324
Joined: Sep 2011
Reputation: 133
Version: 1.4.3.143
Post: #21
RE: Target Delay

    LUA Programming
itemrange = 500;
repeat
if GetTarget() ~= nil then
 if GetTarget():IsAlikeDeath() and GetTarget():IsMonster() and GetZoneType() ~= 12 then
 SetPause(true);
	itemList = GetItemManager();
	for item in itemList.list do
 itemloc = item:GetLocation();
		if not item == nil then
			if GetRangeTo(itemloc) < itemrange then
			repeat
			 Command("/useshortcut 1 1");
			 Sleep(50);
			 Command("/useshortcut 1 2");
			 Sleep(50);
			 Command("/useshortcut 1 1");
			 Sleep(50);
			until GetRangeTo(itemloc) > itemrange
			end;
		end;
 Sleep(100); --- set sleep time
 SetPause(false);
	end;
 end;
end;
 Sleep(200);
until false;

05-03-2014 03:26 AM
Find all posts by this user Quote this message in a reply
nmerritt Offline
Expired VIP Member
**

Posts: 75
Joined: Mar 2013
Reputation: 1
Version: 1.4.2.132
Post: #22
RE: Target Delay

(05-03-2014 03:26 AM)eustach3 Wrote:  
    LUA Programming
itemrange = 500;
repeat
if GetTarget() ~= nil then
 if GetTarget():IsAlikeDeath() and GetTarget():IsMonster() and GetZoneType() ~= 12 then
 SetPause(true);
	itemList = GetItemManager();
	for item in itemList.list do
 itemloc = item:GetLocation();
 if not item == nil then
 if GetRangeTo(itemloc) < itemrange then
 repeat
 Command("/useshortcut 1 1");
 Sleep(50);
 Command("/useshortcut 1 2");
 Sleep(50);
 Command("/useshortcut 1 1");
 Sleep(50);
 until GetRangeTo(itemloc) > itemrange
 end;
 end;
 Sleep(100); --- set sleep time
 SetPause(false);
	end;
 end;
end;
 Sleep(200);
until false;


still getting same error
05-03-2014 13:35 PM
Find all posts by this user Quote this message in a reply
eustach3 Offline
VIP Member
***

Posts: 324
Joined: Sep 2011
Reputation: 133
Version: 1.4.3.143
Post: #23
RE: Target Delay

Try this one
    LUA Programming
itemrange = 500;
repeat
if GetTarget() ~= nil then
 if GetTarget():IsAlikeDeath() and GetTarget():IsMonster() and GetZoneType() ~= 12 then
 SetPause(true);
	itemList = GetItemManager();
	for item in itemList.list do
 itemloc = item:GetLocation();
 if not item == nil then
 if (GetMe():GetRangeTo(itemloc) <  itemrange) then
 repeat
 Command("/useshortcut 1 1");
 Sleep(50);
 Command("/useshortcut 1 2");
 Sleep(50);
 Command("/useshortcut 1 1");
 Sleep(50);
 until (GetMe():GetRangeTo(itemloc) >  itemrange)
 end;
 end;
 Sleep(100); --- set sleep time
 SetPause(false);
	end;
 end;
end;
 Sleep(200);
until false;



----------
If it doesnt work i`ll need to test it tomorrow but till then use this in worst case:
    LUA Programming
itemrange = 500;
repeat
if GetTarget() ~= nil then
 if GetTarget():IsAlikeDeath() and GetTarget():IsMonster() and GetZoneType() ~= 12 then
 SetPause(true);
	itemList = GetItemManager();
	for item in itemList.list do
 itemloc = item:GetLocation();
 if not item == nil then
 if (GetMe():GetRangeTo(itemloc) <  itemrange) then
 repeat
 Command("/useshortcut 1 1");
 Sleep(50);
 Command("/useshortcut 1 2");
 Sleep(50);
 Command("/useshortcut 1 1");
 Sleep(50);
 until (GetMe():GetRangeTo(itemloc) >  itemrange)
 end;
 end;
 Sleep(100); --- set sleep time
 SetPause(false);
	end;
 end;
end;
 Sleep(200);
until false;

05-03-2014 14:00 PM
Find all posts by this user Quote this message in a reply
Post Reply 


Possibly Related Threads...
Thread: Author Replies: Views: Last Post
  GetTarget() don't return monsters target ID Xerovator 3 141 11-16-2024 20:00 PM
Last Post: JennaDeh
  bot will target but not attack. elvis8925 3 3,800 04-09-2018 00:19 AM
Last Post: elvis8925
Star Remove Target canaldextiger 8 4,885 02-10-2018 22:19 PM
Last Post: canaldextiger
Information How to get 'PARTY MEMBER TARGET'? Caaioc 9 6,818 01-24-2016 09:57 AM
Last Post: TheQQmaster
  target for self buff manuel16007 1 3,270 01-22-2016 16:31 PM
Last Post: TheQQmaster
Rainbow Help to cancel target budarox 8 6,017 08-14-2015 06:31 AM
Last Post: budarox
  Nuke delay after i alt+tab. vaskouf 3 4,513 07-10-2015 07:36 AM
Last Post: blackrebel
  Change title to user's target vaskouf 4 4,259 06-28-2015 09:25 AM
Last Post: Vinter
  Clear target after kill mobs astalavista 0 2,978 06-07-2015 18:46 PM
Last Post: astalavista
  Nuke/skill delay lordbauer 6 5,685 04-15-2015 02:44 AM
Last Post: plixplox



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