Lineage 2 Tower Forum

Full Version: script sumon select party
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
as would be the function to even select party member who is away for long-range this function is only when close I need help




repeat
Target("name");
UseSkill(1403, false, false); -- Summon Friend
Sleep(3000);
ClearTargets();
CancelTarget(false);
Sleep(10*60*1000); -- 10 minutes sleep
until false;
    LUA Programming
distance = 1000
function Cast(id)
if id then
skill = GetSkills():FindById(id)
if skill and skill:CanBeUsed() then
UseSkillRaw(id,false,false)
return true
end
end
return false
end
 
repeat
for member in GetPartyList().list do
if member:GetDistance() > distance then
Target(member);
Sleep{500)
Cast(1403} -- Summon Friend
Sleep(3000);
ClearTargets();
CancelTarget(false);
end
end
Sleep(10*60*1000); -- 10 minutes sleep
until false;

(01-22-2015 20:55 PM)tophersoccer Wrote: [ -> ]
    LUA Programming
distance = 1000
repeat
for member in GetPartyList().list do
if member:GetDistance() > distance then
Target("name");
UseSkill(1403, false, false); -- Summon Friend
Sleep(3000);
ClearTargets();
CancelTarget(false);
end
end
Sleep(10*60*1000); -- 10 minutes sleep
until false;


If the pt menber is far away it shouldn't work, cuz missing target
i changed it to target the target id of the member instead of my name. Would that work?
nothing of these 2 will not work.
what you need is here (last post):
http://forum.l2tower.eu/thread-summon-by-wynn
(01-23-2015 20:13 PM)kerberos464 Wrote: [ -> ]nothing of these 2 will not work.
what you need is here (last post):
http://forum.l2tower.eu/thread-summon-by-wynn

can you use packetbuilder in a script?
sure.
but not packetreader.
(01-23-2015 20:13 PM)kerberos464 Wrote: [ -> ]nothing of these 2 will not work.
what you need is here (last post):
http://forum.l2tower.eu/thread-summon-by-wynn

________________________________________________
This is the post but I want to know how to do on or a guide no longer works me and I could not understand the steps to run someone talves to understand more of the plugin and where edit this function (nick, id)? etc .. .


I hope your support thanks

function TargetPartyMember(objId)
local packet = PacketBuilder();
packet:AppendInt(0x1F, 1);
packet:AppendInt(objId, 4);
packet:AppendInt(GetMe():GetLocation().X, 4);
packet:AppendInt(GetMe():GetLocation().Y, 4);
packet:AppendInt(GetMe():GetLocation().Z, 4);
packet:AppendInt(0, 1);
SendPacket(packet);
end;

function OnChatUserMessage(chatType, nick, msg)
if (chatType == L2ChatType.CHAT_PARTY and msg == "summon") then
local party = GetPartyList();
for player in party.list do
if (player:GetName() == nick) then
SetTargetManagerState(false);
TargetPartyMember(player:GetId());
UseSkillRaw(11265, false, false); -- Summon Team Mate
SetTargetManagerState(true);
return;
end;
end;
end;
end;
(01-23-2015 21:19 PM)erickalisetc Wrote: [ -> ]________________________________________________
This is the post but I want to know how to do on or a guide no longer works me and I could not understand the steps to run someone talves to understand more of the plugin and where edit this function (nick, id)? etc .. .


what? that is not english i can follow. Narrow down what your concern is? If you read the thread where that piece of code came from then you should know how to use it.

Now you need to adapt this code (and maybe some other code) to accomplish what you want to do.
Reference URL's